From 740d6d61f554d86cb22f4ad0ee9c8524ebd1ecde Mon Sep 17 00:00:00 2001 From: Guido Falsi Date: Mon, 31 Jul 2017 14:50:40 +0000 Subject: - Update games/0ad to Alpha 22 Venustas (0.0.22) - Add missing dependencies reported by stage-qa - Regenerate some patches - The patch for embedded psutils mostly taken from sysutils/py-psutil121 port --- games/0ad/Makefile | 10 +++-- games/0ad/distinfo | 10 ++--- games/0ad/files/patch-build__premake__premake4.lua | 4 +- ...ada__src__FCollada__FUtils__FUStringBuilder.hpp | 4 +- ...atch-libraries__source__fcollada__src__Makefile | 4 +- ...patch-libraries__source__spidermonkey__build.sh | 17 +++++--- .../patch-source_lib_allocators_page__aligned.cpp | 6 +-- .../files/patch-source_lib_sysdep_os_unix_uvm.cpp | 4 +- games/0ad/files/patch-source_lobby_XmppClient.cpp | 11 +++++ games/0ad/files/psutil.diff | 50 ++++++++++++++++++++++ 10 files changed, 95 insertions(+), 25 deletions(-) create mode 100644 games/0ad/files/patch-source_lobby_XmppClient.cpp create mode 100644 games/0ad/files/psutil.diff (limited to 'games') diff --git a/games/0ad/Makefile b/games/0ad/Makefile index d0563c2a14b1..1652f4c7f34c 100644 --- a/games/0ad/Makefile +++ b/games/0ad/Makefile @@ -1,8 +1,7 @@ # $FreeBSD$ PORTNAME= 0ad -PORTVERSION= 0.0.21 -PORTREVISION= 8 +PORTVERSION= 0.0.22 CATEGORIES= games MASTER_SITES= http://releases.wildfiregames.com/ \ SF/zero-ad/releases @@ -24,16 +23,18 @@ LIB_DEPENDS= libboost_thread.so:devel/boost-libs \ libgloox.so:net-im/gloox \ libminiupnpc.so:net/miniupnpc \ libnspr4.so:devel/nspr \ - libenet.so:net/enet + libenet.so:net/enet \ + libtiff.so:graphics/tiff WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVERSION}-alpha BUILD_WRKSRC= ${WRKSRC}/build/workspaces/gcc MAKE_ARGS= config=release -USES= compiler:c++11-lib dos2unix execinfo gmake iconv openal:al \ +USES= compiler:c++11-lib dos2unix execinfo gmake iconv jpeg openal:al \ pkgconfig tar:xz USE_GNOME= libxml2 gtk20 USE_GL= gl USE_SDL= sdl2 +USE_XORG= x11 xcursor BUNDLE_LIBS= yes DOS2UNIX_REGEX= .*\.([ch]p{0,2}|make) @@ -62,6 +63,7 @@ post-patch: ${WRKSRC}/build/resources/0ad.desktop @${REINPLACE_CMD} 's|%%PREFIX%%|${PREFIX}|' \ ${WRKSRC}/build/resources/0ad.sh + @${CP} ${FILESDIR}/psutil.diff ${WRKSRC}/libraries/source/spidermonkey/ pre-build: (cd ${WRKSRC}/build/workspaces && ${SETENV} ${MAKE_ENV} ./update-workspaces.sh ${0ADSDLARG} --bindir=${PREFIX}/bin --datadir=${DATADIR} --libdir=${PREFIX}/lib/${PORTNAME}) diff --git a/games/0ad/distinfo b/games/0ad/distinfo index 876a4b0039cf..b3a8f8340f67 100644 --- a/games/0ad/distinfo +++ b/games/0ad/distinfo @@ -1,5 +1,5 @@ -TIMESTAMP = 1478641325 -SHA256 (0ad-0.0.21-alpha-unix-build.tar.xz) = 96be23e4284a3931ef9536f988f2517040bde1f8700ee048bff18c932d8683cf -SIZE (0ad-0.0.21-alpha-unix-build.tar.xz) = 29196476 -SHA256 (0ad-0.0.21-alpha-unix-data.tar.xz) = f3ab3c58ffd3bd647a9baba93ea009d5945d2b5bc7db7053a547e07db36faa97 -SIZE (0ad-0.0.21-alpha-unix-data.tar.xz) = 587025496 +TIMESTAMP = 1501175300 +SHA256 (0ad-0.0.22-alpha-unix-build.tar.xz) = fddd36df4fd32b5b31fd8871bc5ed3ec71a921de79517fb6199ba7571ec9f5b1 +SIZE (0ad-0.0.22-alpha-unix-build.tar.xz) = 29199308 +SHA256 (0ad-0.0.22-alpha-unix-data.tar.xz) = 4c32cd0a346815cd260357d55d5a61430f670c78a2fa7a321957c0e4559a766e +SIZE (0ad-0.0.22-alpha-unix-data.tar.xz) = 632555792 diff --git a/games/0ad/files/patch-build__premake__premake4.lua b/games/0ad/files/patch-build__premake__premake4.lua index 5ab3bdd4964f..316c4bdf9501 100644 --- a/games/0ad/files/patch-build__premake__premake4.lua +++ b/games/0ad/files/patch-build__premake__premake4.lua @@ -1,6 +1,6 @@ ---- build/premake/premake4.lua.orig 2014-09-24 10:05:09 UTC +--- build/premake/premake4.lua.orig 2017-07-06 17:29:49 UTC +++ build/premake/premake4.lua -@@ -416,11 +416,11 @@ +@@ -388,11 +388,11 @@ function project_add_x11_dirs() includedirs { "/usr/X11R6/include/X11", "/usr/X11R6/include", diff --git a/games/0ad/files/patch-libraries__source__fcollada__src__FCollada__FUtils__FUStringBuilder.hpp b/games/0ad/files/patch-libraries__source__fcollada__src__FCollada__FUtils__FUStringBuilder.hpp index 602b6410648c..1e7b881a41fb 100644 --- a/games/0ad/files/patch-libraries__source__fcollada__src__FCollada__FUtils__FUStringBuilder.hpp +++ b/games/0ad/files/patch-libraries__source__fcollada__src__FCollada__FUtils__FUStringBuilder.hpp @@ -1,4 +1,4 @@ ---- libraries/source/fcollada/src/FCollada/FUtils/FUStringBuilder.hpp.orig 2014-09-24 10:30:15 UTC +--- libraries/source/fcollada/src/FCollada/FUtils/FUStringBuilder.hpp.orig 2017-07-28 19:57:27 UTC +++ libraries/source/fcollada/src/FCollada/FUtils/FUStringBuilder.hpp @@ -26,63 +26,6 @@ #define SAFE_DELETE_ARRAY(ptr) if (ptr != NULL) { delete [] ptr; ptr = NULL; } @@ -64,7 +64,7 @@ template FUStringBuilderT::FUStringBuilderT(const String& sz) { -@@ -234,53 +177,50 @@ +@@ -234,53 +177,50 @@ void FUStringBuilderT::append(const FUStringBuil template void FUStringBuilderT::append(float f) { diff --git a/games/0ad/files/patch-libraries__source__fcollada__src__Makefile b/games/0ad/files/patch-libraries__source__fcollada__src__Makefile index 9fd151bb3e0b..ed6bd804207e 100644 --- a/games/0ad/files/patch-libraries__source__fcollada__src__Makefile +++ b/games/0ad/files/patch-libraries__source__fcollada__src__Makefile @@ -1,6 +1,6 @@ ---- libraries/source/fcollada/src/Makefile.orig 2014-09-27 14:41:22 UTC +--- libraries/source/fcollada/src/Makefile.orig 2014-09-24 14:39:28 UTC +++ libraries/source/fcollada/src/Makefile -@@ -227,7 +227,7 @@ +@@ -227,7 +227,7 @@ OBJECTS_ALL = $(OBJECTS_DEBUG) $(OBJECTS_RELEASE) $(OB all: output/libFColladaSD.a output/libFColladaSR.a install output_dirs: diff --git a/games/0ad/files/patch-libraries__source__spidermonkey__build.sh b/games/0ad/files/patch-libraries__source__spidermonkey__build.sh index fc0133e4ba0d..cb4a6555583d 100644 --- a/games/0ad/files/patch-libraries__source__spidermonkey__build.sh +++ b/games/0ad/files/patch-libraries__source__spidermonkey__build.sh @@ -1,9 +1,17 @@ ---- libraries/source/spidermonkey/build.sh.orig 2015-01-24 14:46:52 UTC +--- libraries/source/spidermonkey/build.sh.orig 2016-10-04 15:01:34 UTC +++ libraries/source/spidermonkey/build.sh -@@ -95,6 +95,14 @@ cd mozjs31/js/src +@@ -90,11 +90,21 @@ cd $FOLDER + # Apply patches + . ../patch.sh + ++patch <../psutil.diff ++ + cd js/src + + # Clean up data generated by previous builds that could cause problems rm -rf build-debug rm -rf build-release - ++ +cp jsnativestack.cpp jsnativestack.cpp.orig +sed 's/# include /#pragma GCC visibility push(default)\ +#include \ @@ -11,7 +19,6 @@ + +cp configure configure.orig +sed -e 's/"$ac_cv_have_visibility_class_bug" = "no"; then/"$ac_cv_have_visibility_class_bug" = "no" -a "$OS_ARCH" != "FreeBSD" ; then/' -e 's/-Werror=conversion-null//' configure.orig >configure -+ + # We want separate debug/release versions of the library, so we have to change # the LIBRARY_NAME for each build. - # (We use perl instead of sed so that it works with MozillaBuild on Windows, diff --git a/games/0ad/files/patch-source_lib_allocators_page__aligned.cpp b/games/0ad/files/patch-source_lib_allocators_page__aligned.cpp index 7a0f148e064f..87d3081a43e7 100644 --- a/games/0ad/files/patch-source_lib_allocators_page__aligned.cpp +++ b/games/0ad/files/patch-source_lib_allocators_page__aligned.cpp @@ -1,6 +1,6 @@ ---- source/lib/allocators/page_aligned.cpp.orig 2011-05-03 12:38:42 UTC +--- source/lib/allocators/page_aligned.cpp.orig 2017-07-28 19:57:26 UTC +++ source/lib/allocators/page_aligned.cpp -@@ -49,7 +49,7 @@ static const int mmap_flags = MAP_PRIVAT +@@ -49,7 +49,7 @@ static const int mmap_flags = MAP_PRIVATE|MAP_ANONYMOU Status mem_Reserve(size_t size, u8** pp) { errno = 0; @@ -9,7 +9,7 @@ *pp = (u8*)ret; return StatusFromMap(ret); } -@@ -76,7 +76,7 @@ Status mem_Commit(u8* p, size_t size, in +@@ -76,7 +76,7 @@ Status mem_Commit(u8* p, size_t size, int prot) Status mem_Decommit(u8* p, size_t size) { errno = 0; diff --git a/games/0ad/files/patch-source_lib_sysdep_os_unix_uvm.cpp b/games/0ad/files/patch-source_lib_sysdep_os_unix_uvm.cpp index eb4e0ea33739..09152b8501de 100644 --- a/games/0ad/files/patch-source_lib_sysdep_os_unix_uvm.cpp +++ b/games/0ad/files/patch-source_lib_sysdep_os_unix_uvm.cpp @@ -1,4 +1,4 @@ ---- source/lib/sysdep/os/unix/uvm.cpp.orig 2013-12-06 00:42:50 UTC +--- source/lib/sysdep/os/unix/uvm.cpp.orig 2017-07-28 19:57:26 UTC +++ source/lib/sysdep/os/unix/uvm.cpp @@ -40,7 +40,7 @@ namespace vm { void* ReserveAddressSpace(size_t size, size_t UNUSED(commitSize), PageType UNUSED(pageType), int UNUSED(prot)) @@ -9,7 +9,7 @@ if(p == MAP_FAILED) return 0; return p; -@@ -77,7 +77,7 @@ bool Commit(uintptr_t address, size_t si +@@ -77,7 +77,7 @@ bool Commit(uintptr_t address, size_t size, PageType U bool Decommit(uintptr_t address, size_t size) { errno = 0; diff --git a/games/0ad/files/patch-source_lobby_XmppClient.cpp b/games/0ad/files/patch-source_lobby_XmppClient.cpp new file mode 100644 index 000000000000..a3d74e0b0573 --- /dev/null +++ b/games/0ad/files/patch-source_lobby_XmppClient.cpp @@ -0,0 +1,11 @@ +--- source/lobby/XmppClient.cpp.orig 2017-07-28 19:57:26 UTC ++++ source/lobby/XmppClient.cpp +@@ -955,7 +955,7 @@ std::time_t XmppClient::ComputeTimestamp(const glooxwr + if (!strptime(timestampStr.c_str(), "%Y-%m-%dT%H:%M:%SZ", ×tamp)) + LOGERROR("Received delayed message with corrupted timestamp %s", timestampStr.to_string()); + +- return std::mktime(×tamp) - timezone; ++ return std::mktime(×tamp); + } + + /** diff --git a/games/0ad/files/psutil.diff b/games/0ad/files/psutil.diff new file mode 100644 index 000000000000..256ec324dfde --- /dev/null +++ b/games/0ad/files/psutil.diff @@ -0,0 +1,50 @@ +--- python/psutil/psutil/_psutil_bsd.c.orig 2015-09-17 20:12:23 UTC ++++ python/psutil/psutil/_psutil_bsd.c +@@ -957,11 +957,19 @@ psutil_sockaddr_matches(int family, int port, void *pc + psutil_sockaddr_addrlen(family)) == 0); + } + ++#if __FreeBSD_version >= 1200026 ++static struct xtcpcb * ++psutil_search_tcplist(char *buf, struct kinfo_file *kif) ++{ ++ struct xtcpcb *tp; ++ struct xinpcb *inp; ++#else + static struct tcpcb * + psutil_search_tcplist(char *buf, struct kinfo_file *kif) + { + struct tcpcb *tp; + struct inpcb *inp; ++#endif + struct xinpgen *xig, *oxig; + struct xsocket *so; + +@@ -969,9 +977,15 @@ psutil_search_tcplist(char *buf, struct kinfo_file *ki + for (xig = (struct xinpgen *)((char *)xig + xig->xig_len); + xig->xig_len > sizeof(struct xinpgen); + xig = (struct xinpgen *)((char *)xig + xig->xig_len)) { ++#if __FreeBSD_version >= 1200026 ++ tp = (struct xtcpcb *)xig; ++ inp = &tp->xt_inp; ++ so = &inp->xi_socket; ++#else + tp = &((struct xtcpcb *)xig)->xt_tp; + inp = &((struct xtcpcb *)xig)->xt_inp; + so = &((struct xtcpcb *)xig)->xt_socket; ++#endif + + if (so->so_type != kif->kf_sock_type || + so->xso_family != kif->kf_sock_domain || +@@ -1019,7 +1033,11 @@ psutil_proc_connections(PyObject *self, PyObject *args + struct kinfo_file *freep = NULL; + struct kinfo_file *kif; + char *tcplist = NULL; ++#if __FreeBSD_version >= 1200026 ++ struct xtcpcb *tcp; ++#else + struct tcpcb *tcp; ++#endif + + PyObject *retList = PyList_New(0); + PyObject *tuple = NULL; -- cgit v1.2.3