aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDmitry Marakasov <amdmi3@FreeBSD.org>2023-03-27 21:39:10 +0000
committerDmitry Marakasov <amdmi3@FreeBSD.org>2023-03-28 16:51:00 +0000
commit87815f0c5a175f3b6be9dc49a6ef31d2cb5d2881 (patch)
treef40089723b76bab4069c6883019d248cf8e96de3
parent9d3d4d11ad654419fbe901f0a3a80cd1138d1718 (diff)
games/xmoto: update 0.6.1 → 0.6.2
-rw-r--r--games/xmoto/Makefile14
-rw-r--r--games/xmoto/distinfo6
-rw-r--r--games/xmoto/files/patch-src_CMakeLists.txt81
-rw-r--r--games/xmoto/files/patch-src_common_Locales.cpp25
-rw-r--r--games/xmoto/pkg-plist2
5 files changed, 50 insertions, 78 deletions
diff --git a/games/xmoto/Makefile b/games/xmoto/Makefile
index bb0c2ca913f2..d2c774521fee 100644
--- a/games/xmoto/Makefile
+++ b/games/xmoto/Makefile
@@ -1,6 +1,6 @@
PORTNAME= xmoto
-PORTVERSION= 0.6.1
-PORTREVISION= 3
+DISTVERSIONPREFIX= v
+DISTVERSION= 0.6.2
CATEGORIES= games
MAINTAINER= amdmi3@FreeBSD.org
@@ -10,17 +10,15 @@ 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= *
@@ -38,8 +36,8 @@ 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:
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,50 +1,49 @@
---- 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 $<AND:$<BOOL:${PREFER_SYSTEM_Lua}>,$<BOOL:${LUA51_FOUND}>,$<NOT:$<BOOL:${WIN32}>>>)
-+set(USE_SYSTEM_Lua $<AND:$<BOOL:${PREFER_SYSTEM_Lua}>,$<BOOL:${LUA_FOUND}>,$<NOT:$<BOOL:${WIN32}>>>)
- 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}>"
-- "$<$<NOT:${USE_SYSTEM_Lua}>:${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"
-+# "$<$<NOT:${USE_SYSTEM_Lua}>:${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
- $<$<PLATFORM_ID:Windows>:userenv>
-@@ -463,7 +479,9 @@ target_compile_definitions(xmoto PUBLIC MS_MKDIR=$<BOO
++target_include_directories(xmoto
++ SYSTEM PRIVATE
++
+ "${CURL_INCLUDE_DIR}"
+ "${LIBXML2_INCLUDE_DIR}"
+ "${Intl_INCLUDE_DIRS}"
+@@ -524,7 +517,9 @@ endif()
target_compile_definitions(xmoto PUBLIC USE_OPENGL=$<BOOL:${USE_OPENGL}>)
target_compile_definitions(xmoto PUBLIC USE_SDLGFX=$<BOOL:${USE_SDLGFX}>)
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 <iostream>
-+#if USE_GETTEXT
- #include <libintl.h>
-+#endif
-
- #define PACKAGE_LANG "xmoto"
-
-@@ -68,10 +70,12 @@ std::pair<std::string, std::string> Locales::changeLoc
- #endif
-
- /* Make change known. */
-+#if USE_GETTEXT
- {
- extern int _nl_msg_cat_cntr;
- ++_nl_msg_cat_cntr;
- }
-+#endif
-
- std::pair<std::string, std::string> 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
@@ -24,4 +24,4 @@ share/applications/xmoto.desktop
%%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