diff --git a/games/xmoto/Makefile b/games/xmoto/Makefile index bb0c2ca913f2..d2c774521fee 100644 --- a/games/xmoto/Makefile +++ b/games/xmoto/Makefile @@ -1,58 +1,56 @@ PORTNAME= xmoto -PORTVERSION= 0.6.1 -PORTREVISION= 3 +DISTVERSIONPREFIX= v +DISTVERSION= 0.6.2 CATEGORIES= games MAINTAINER= amdmi3@FreeBSD.org COMMENT= Challenging 2D motocross platform game WWW= https://xmoto.tuxfamily.org/ LICENSE= GPLv2+ LICENSE_FILE= ${WRKSRC}/COPYING -LIB_DEPENDS= libode.so:devel/ode \ - libpng.so:graphics/png \ +LIB_DEPENDS= libpng.so:graphics/png \ libcurl.so:ftp/curl \ libxdg-basedir.so:x11/libxdg-basedir USES= compiler:c++11-lang cmake gl gnome jpeg lua:52 pkgconfig sdl sqlite USE_GITHUB= yes USE_GNOME= libxml2 -USE_SDL= sdl mixer ttf net +USE_SDL= sdl2 mixer2 ttf2 net2 USE_GL= gl glu -CMAKE_ARGS= -DOpenGL_GL_PREFERENCE="GLVND" PORTDOCS= README.md ChangeLog PORTDATA= * ASIAN_FONT_PATH=${LOCALBASE}/share/fonts/TrueType/bkai00mp.ttf OPTIONS_DEFINE= ASIAN_TTF DOCS NLS OPTIONS_SUB= yes ASIAN_TTF_DESC= Use asian TTF font ASIAN_TTF_RUN_DEPENDS= ${ASIAN_FONT_PATH}:chinese/arphicttf NLS_USES= gettext NLS_CMAKE_BOOL= USE_GETTEXT # ensure bundled depends are not used post-extract: -.for d in bzip2 lua ode xdgbasedir - @${RM} -r ${WRKSRC}/src/${d} +.for d in bzip2 lua xdgbasedir + @${RM} -r ${WRKSRC}/vendor/${d} .endfor post-patch: @${REINPLACE_CMD} \ -e "s|find_package(Lua|& ${LUA_VER} REQUIRED EXACT|" \ -e "s|/usr/share/fonts/truetype/arphic/bkai00mp.ttf|${ASIAN_FONT_PATH}|" \ -e "s|DEFAULT_ASIAN_TTF_FILE|ASIAN_TTF_FILE|" \ ${WRKSRC}/src/CMakeLists.txt post-install-DOCS-on: @${MKDIR} ${STAGEDIR}${DOCSDIR} .for f in ${PORTDOCS} ${INSTALL_DATA} ${WRKSRC}/${f} ${STAGEDIR}${DOCSDIR}/ .endfor .include diff --git a/games/xmoto/distinfo b/games/xmoto/distinfo index a6e8c0a69834..7b5b7a4dcac4 100644 --- a/games/xmoto/distinfo +++ b/games/xmoto/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1647452639 -SHA256 (xmoto-xmoto-0.6.1_GH0.tar.gz) = 209c8c38b1742d0620d40f90365c7a56f67c86da826c80a76d37fa46ee9c9b66 -SIZE (xmoto-xmoto-0.6.1_GH0.tar.gz) = 41623870 +TIMESTAMP = 1678130089 +SHA256 (xmoto-xmoto-v0.6.2_GH0.tar.gz) = 1ba54baaa1511f45497c1aadd6c8fda4917fd4e403466cdc92b5755b05c90de4 +SIZE (xmoto-xmoto-v0.6.2_GH0.tar.gz) = 42115597 diff --git a/games/xmoto/files/patch-src_CMakeLists.txt b/games/xmoto/files/patch-src_CMakeLists.txt index bb012ae49335..9db368ed7de7 100644 --- a/games/xmoto/files/patch-src_CMakeLists.txt +++ b/games/xmoto/files/patch-src_CMakeLists.txt @@ -1,57 +1,56 @@ ---- src/CMakeLists.txt.orig 2020-06-21 19:18:16 UTC +--- src/CMakeLists.txt.orig 2023-03-05 10:10:34 UTC +++ src/CMakeLists.txt -@@ -41,7 +41,7 @@ endif() - find_package(PNG REQUIRED) - - find_package(Lua) --set(USE_SYSTEM_Lua $,$,$>>) -+set(USE_SYSTEM_Lua $,$,$>>) - if (NOT LUA_VERSION_STRING VERSION_LESS 5.2 AND LUA_VERSION_STRING VERSION_LESS 5.3) - add_definitions("-DLUA_COMPAT_ALL") - elseif (LUA_VERSION_STRING VERSION_GREATER_EQUAL "5.3") -@@ -398,14 +398,30 @@ elseif(APPLE AND BUILD_MACOS_BUNDLE) - endif() - - target_include_directories(xmoto -- PRIVATE +@@ -52,15 +52,7 @@ endif() + # Can't disable yet + if(ON OR USE_SDLGFX) + # This is a workaround required on some systems that ship a broken sdl2-config.cmake +- find_library(SDL2_LIBRARIES NAMES SDL2 SDL2main) +- if(NOT SDL2_LIBRARIES) +- find_package(SDL2 REQUIRED) - -- "${PROJECT_SOURCE_DIR}/src" -+ PRIVATE SYSTEM -+ "${Intl_INCLUDE_DIR}" -+ "${JPEG_INCLUDE_DIR}" -+ "${LIBLZMA_INCLUDE_DIR}" - "${LIBXML2_INCLUDE_DIR}" -+ "${OPENGL_INCLUDE_DIR}" -+ "${PNG_PNG_INCLUDE_DIR}" -+ "${SDL_INCLUDE_DIR}" -+ "${SDL_MIXER_INCLUDE_DIR}" -+ "${SDL_NET_INCLUDE_DIR}" -+ "${SQLITE3_INCLUDE_DIRS}" -+ "${ZLIB_INCLUDE_DIR}" -+ "$<${USE_SYSTEM_BZip2}:${BZIP2_INCLUDE_DIR}>" - "$<${USE_SYSTEM_Lua}:${LUA_INCLUDE_DIR}>" -- "$<$:${PROJECT_SOURCE_DIR}/vendor/lua/lua>" -+ "$<${USE_SYSTEM_ODE}:${ODE_INCLUDE_DIR}>" -+ "$<${USE_SYSTEM_XDG}:${XDG_INCLUDE_DIR}>" +- if("${SDL2_LIBRARIES}" STREQUAL "") +- set(SDL2_LIBRARIES SDL2::SDL2) +- endif() +- endif() +- ++ find_package(SDL2 REQUIRED) + find_package(SDL2_mixer REQUIRED) + find_package(SDL2_net REQUIRED) + find_package(SDL2_ttf REQUIRED) +@@ -85,13 +77,10 @@ check_prototype_definition(mkdir + MS_MKDIR ) -+target_include_directories(xmoto -+ PRIVATE -+ "${PROJECT_SOURCE_DIR}/src" -+# "$<$:${PROJECT_SOURCE_DIR}/vendor/lua/lua>" +-add_subdirectory("${PROJECT_SOURCE_DIR}/vendor/bzip2" bzip2) + add_subdirectory("${PROJECT_SOURCE_DIR}/vendor/libccd" libccd) + add_subdirectory("${PROJECT_SOURCE_DIR}/vendor/chipmunk" chipmunk) +-add_subdirectory("${PROJECT_SOURCE_DIR}/vendor/lua" lua) + add_subdirectory("${PROJECT_SOURCE_DIR}/vendor/md5sum" md5sum) + add_subdirectory("${PROJECT_SOURCE_DIR}/vendor/ode" ode) +-add_subdirectory("${PROJECT_SOURCE_DIR}/vendor/xdgbasedir" xdgbasedir) + add_subdirectory("${PROJECT_SOURCE_DIR}/vendor/glad" glad) + + configure_file(common/XMBuildConfig.h.in common/XMBuildConfig.h) +@@ -447,7 +436,11 @@ target_include_directories(xmoto + PRIVATE + + "${PROJECT_SOURCE_DIR}/src" +) -+ - target_link_libraries(xmoto PUBLIC - $<$:userenv> -@@ -463,7 +479,9 @@ target_compile_definitions(xmoto PUBLIC MS_MKDIR=$) target_compile_definitions(xmoto PUBLIC USE_SDLGFX=$) -target_compile_definitions(xmoto PUBLIC USE_GETTEXT=$) +if (USE_GETTEXT) + target_compile_definitions(xmoto PUBLIC USE_GETTEXT=1) +endif() target_compile_definitions(xmoto PUBLIC ALLOW_DEV=$) target_compile_definitions(xmoto PUBLIC BUILD_MACOS_BUNDLE=$) diff --git a/games/xmoto/files/patch-src_common_Locales.cpp b/games/xmoto/files/patch-src_common_Locales.cpp deleted file mode 100644 index 92f912cdde8f..000000000000 --- a/games/xmoto/files/patch-src_common_Locales.cpp +++ /dev/null @@ -1,25 +0,0 @@ ---- src/common/Locales.cpp.orig 2020-06-21 19:18:16 UTC -+++ src/common/Locales.cpp -@@ -25,7 +25,9 @@ Foundation, Inc., 59 Temple Place, Suite 330, Boston, - #include "helpers/Log.h" - #include "helpers/VExcept.h" - #include -+#if USE_GETTEXT - #include -+#endif - - #define PACKAGE_LANG "xmoto" - -@@ -68,10 +70,12 @@ std::pair Locales::changeLoc - #endif - - /* Make change known. */ -+#if USE_GETTEXT - { - extern int _nl_msg_cat_cntr; - ++_nl_msg_cat_cntr; - } -+#endif - - std::pair locale_str( - locale.first == NULL ? std::string("") : std::string(locale.first), diff --git a/games/xmoto/pkg-plist b/games/xmoto/pkg-plist index 78f9801d980d..b71f2be5af49 100644 --- a/games/xmoto/pkg-plist +++ b/games/xmoto/pkg-plist @@ -1,27 +1,27 @@ bin/xmoto share/applications/xmoto.desktop %%NLS%%share/locale/ca_ES/LC_MESSAGES/xmoto.mo %%NLS%%share/locale/cs_CZ/LC_MESSAGES/xmoto.mo %%NLS%%share/locale/da_DK/LC_MESSAGES/xmoto.mo %%NLS%%share/locale/de/LC_MESSAGES/xmoto.mo %%NLS%%share/locale/es/LC_MESSAGES/xmoto.mo %%NLS%%share/locale/fi/LC_MESSAGES/xmoto.mo %%NLS%%share/locale/fr/LC_MESSAGES/xmoto.mo %%NLS%%share/locale/gl_ES/LC_MESSAGES/xmoto.mo %%NLS%%share/locale/hu/LC_MESSAGES/xmoto.mo %%NLS%%share/locale/it/LC_MESSAGES/xmoto.mo %%NLS%%share/locale/lt/LC_MESSAGES/xmoto.mo %%NLS%%share/locale/lv/LC_MESSAGES/xmoto.mo %%NLS%%share/locale/nb_NO/LC_MESSAGES/xmoto.mo %%NLS%%share/locale/nl/LC_MESSAGES/xmoto.mo %%NLS%%share/locale/nn_NO/LC_MESSAGES/xmoto.mo %%NLS%%share/locale/pl/LC_MESSAGES/xmoto.mo %%NLS%%share/locale/pt/LC_MESSAGES/xmoto.mo %%NLS%%share/locale/pt_BR/LC_MESSAGES/xmoto.mo %%NLS%%share/locale/ru/LC_MESSAGES/xmoto.mo %%NLS%%share/locale/sk/LC_MESSAGES/xmoto.mo %%NLS%%share/locale/sv_SE/LC_MESSAGES/xmoto.mo %%NLS%%share/locale/tr/LC_MESSAGES/xmoto.mo %%NLS%%share/locale/zh_TW/LC_MESSAGES/xmoto.mo share/man/man6/xmoto.6.gz -share/pixmaps/xmoto.xpm +share/pixmaps/xmoto.png