aboutsummaryrefslogtreecommitdiffstats
path: root/games/widelands
diff options
context:
space:
mode:
authoramdmi3 <amdmi3@FreeBSD.org>2008-11-10 20:58:56 +0800
committeramdmi3 <amdmi3@FreeBSD.org>2008-11-10 20:58:56 +0800
commit20c80478d1b3cb0a8d98f31d6bb09facbb09d936 (patch)
tree28df861c22b1e6ee120790e82d0426a93231068d /games/widelands
parent74cd5ad17c79b185cf5edc7fccc214c0d3e3d858 (diff)
downloadfreebsd-ports-gnome-20c80478d1b3cb0a8d98f31d6bb09facbb09d936.tar.gz
freebsd-ports-gnome-20c80478d1b3cb0a8d98f31d6bb09facbb09d936.tar.zst
freebsd-ports-gnome-20c80478d1b3cb0a8d98f31d6bb09facbb09d936.zip
- Update to build13rc
- Take maintainership - Use SF macro - Improve plist generation PR: 128743 Submitted by: myself Approved by: Bartosz Fabianowski <freebsd at chillt dot de> (maintainer)
Diffstat (limited to 'games/widelands')
-rw-r--r--games/widelands/Makefile68
-rw-r--r--games/widelands/distinfo6
-rw-r--r--games/widelands/files/patch-SConstruct26
-rw-r--r--games/widelands/files/patch-build-scons-tools-scons_configure.py29
-rw-r--r--games/widelands/files/patch-src_SConscript19
5 files changed, 71 insertions, 77 deletions
diff --git a/games/widelands/Makefile b/games/widelands/Makefile
index af560601f955..09b3a39db790 100644
--- a/games/widelands/Makefile
+++ b/games/widelands/Makefile
@@ -6,60 +6,56 @@
#
PORTNAME= widelands
-DISTVERSION= build10
-PORTREVISION= 2
+DISTVERSION= build13rc
CATEGORIES= games
-MASTER_SITES= ${MASTER_SITE_SOURCEFORGE_EXTENDED}
-MASTER_SITE_SUBDIR= ${PORTNAME}
-DISTNAME= ${PORTNAME}-${DISTVERSION}-source
+MASTER_SITES= SFE
+DISTNAME= ${PORTNAME}-${DISTVERSION:C/^b/B/}-src
-MAINTAINER= freebsd@chillt.de
+MAINTAINER= amdmi3@FreeBSD.org
COMMENT= Realtime strategy game inspired by Settlers II
-LIB_DEPENDS= png.5:${PORTSDIR}/graphics/png
+LIB_DEPENDS= png.5:${PORTSDIR}/graphics/png \
+ boost_thread.4:${PORTSDIR}/devel/boost
-WRKSRC= ${WRKDIR}/widelands
-PLIST= ${WRKDIR}/pkg-plist
USE_BZIP2= yes
USE_PYTHON_BUILD= 2.4+
USE_GETTEXT= yes
-USE_SDL= mixer image net ttf
+USE_SDL= sdl mixer image net ttf gfx
+USE_GCC= 4.2+
+
+PLIST_FILES= bin/widelands
+
+WRKSRC= ${WRKDIR}/widelands
SCONS_ARGS= CXXFLAGS="${CXXFLAGS}" LINKFLAGS="${LDFLAGS}" \
CPPPATH=${LOCALBASE}/include LIBPATH=${LOCALBASE}/lib \
CC="${CC}" CXX="${CXX}" \
- install_prefix=${PREFIX} bindir=bin datadir=share/widelands
+ install_prefix=${PREFIX} bindir=bin datadir=share/widelands \
+ localedir=share/widelands/locale build=release
+
+post-extract:
+ @cd ${WRKSRC}/utils && ${TAR} xf scons-local-1.0.1.tar.gz
post-patch:
- @${REINPLACE_CMD} -e 's|, True||' ${WRKSRC}/worlds/SConscript
- @${RM} -f ${WRKSRC}/worlds/SConscript.bak
+ @${REINPLACE_CMD} -e '/prefer_localdata/ s|True|False|' \
+ ${WRKSRC}/worlds/SConscript
+ @${REINPLACE_CMD} -e '/ifndef/ s|__APPLE__|__FreeBSD__|' \
+ ${WRKSRC}/src/backtrace.cc
+ @${REINPLACE_CMD} -e 's|/usr/bin/python|${PYTHON_CMD}|' \
+ ${WRKSRC}/utils/buildlocale.py
+ @${REINPLACE_CMD} -e 's|revstring=.*|return "${DISTVERSION}-FreeBSD"|' \
+ ${WRKSRC}/build/scons-tools/detect_revision.py
do-build:
- @cd ${WRKSRC} && \
- (cd utils && ${TAR} xf scons-local-0.96.1.tar.gz) && \
- ${PYTHON_CMD} utils/scons.py ${SCONS_ARGS}
-
-pre-install:
- @${RM} -f ${PLIST}
- @${ECHO_CMD} bin/widelands > ${PLIST}
- @for f in COPYING CREDITS ChangeLog README developers editor_readme ; do \
- ${ECHO_CMD} %%DATADIR%%/doc/$$f >> ${PLIST} ; \
- done
- @cd ${WRKSRC} && for d in campaigns maps ; do \
- ${LS} -1d $$d/*.wmf | ${SORT} | ${SED} -e 's|^|%%DATADIR%%/|' >> ${PLIST} ; \
- done
- @cd ${WRKSRC} && for d in fonts game_server music pics sound tribes worlds ; do \
- ${FIND} $$d -type f \! -name SConscript | ${SORT} | ${SED} -e 's|^|%%DATADIR%%/|' >> ${PLIST} ; \
- done
- @for d in doc campaigns maps ; do \
- ${ECHO_CMD} "@dirrm %%DATADIR%%/$$d" >> ${PLIST} ; \
- done
- @cd ${WRKSRC} && for d in fonts game_server music pics sound tribes worlds ; do \
- ${FIND} $$d -type d | ${SORT} -r | ${SED} -e 's|^|@dirrm %%DATADIR%%/|' >> ${PLIST} ; \
- done
- @${ECHO_CMD} "@dirrm %%DATADIR%%" >> ${PLIST}
+ @cd ${WRKSRC} && ${PYTHON_CMD} utils/scons.py ${SCONS_ARGS}
do-install:
@cd ${WRKSRC} && ${PYTHON_CMD} utils/scons.py ${SCONS_ARGS} install
+post-install:
+ @${FIND} ${DATADIR} -type f | \
+ ${SED} -e 's|^${PREFIX}/||' >> ${TMPPLIST}
+ @${FIND} ${DATADIR} -type d | ${SORT} -r | \
+ ${SED} -e 's|^${PREFIX}/|@dirrm |' >> ${TMPPLIST}
+
.include <bsd.port.mk>
diff --git a/games/widelands/distinfo b/games/widelands/distinfo
index 13d387f66106..f62e67dbda8b 100644
--- a/games/widelands/distinfo
+++ b/games/widelands/distinfo
@@ -1,3 +1,3 @@
-MD5 (widelands-build10-source.tar.bz2) = 9e452baf7b8f22a27b4e371e2150e017
-SHA256 (widelands-build10-source.tar.bz2) = f67508066db1739839945f8c814a71a0e4a43904ff4a7f4e7cd3c269bcda18af
-SIZE (widelands-build10-source.tar.bz2) = 28526726
+MD5 (widelands-Build13rc-src.tar.bz2) = 8639ce8e357346daa5b60a7ac905f1d9
+SHA256 (widelands-Build13rc-src.tar.bz2) = 50a3a2eefd3f2b19bd5a6e643d1ef0091780b037af0df4d54cafd352153a3bc1
+SIZE (widelands-Build13rc-src.tar.bz2) = 45349994
diff --git a/games/widelands/files/patch-SConstruct b/games/widelands/files/patch-SConstruct
index 8d6d9c45949f..b7660a2ae47b 100644
--- a/games/widelands/files/patch-SConstruct
+++ b/games/widelands/files/patch-SConstruct
@@ -1,23 +1,11 @@
---- SConstruct.orig Mon Mar 12 21:39:30 2007
-+++ SConstruct Sat Jun 2 03:49:26 2007
-@@ -122,9 +122,11 @@
- #
- # Create configuration objects
+--- SConstruct.orig 2008-10-06 21:43:03.000000000 +0400
++++ SConstruct 2008-11-09 18:44:06.000000000 +0300
+@@ -101,7 +101,7 @@
-+SConsignFile('build/scons-signatures')
-+
opts=cli_options()
-env=Environment(options=opts)
-+env=Environment(options=opts, **dict((k, v.split()) for k, v in ARGUMENTS.iteritems()))
- env.Help(opts.GenerateHelpText(env))
-
- conf=env.Configure(conf_dir='#/build/sconf_temp',log_file='#build/config.log',
-@@ -287,7 +289,6 @@
-
- ################################################################### Build things
-
--SConsignFile('build/scons-signatures')
- BUILDDIR='build/'+TARGET+'-'+env['build']
- Export('env', 'Glob', 'BUILDDIR', 'PhonyTarget')
-
++env=Environment(options=opts, ENV=os.environ, **dict((k, v.split()) for k, v in ARGUMENTS.iteritems()))
+ env.Tool("ctags", toolpath=['build/scons-tools'])
+ env.Tool("PNGShrink", toolpath=['build/scons-tools'])
+ env.Tool("astyle", toolpath=['build/scons-tools'])
diff --git a/games/widelands/files/patch-build-scons-tools-scons_configure.py b/games/widelands/files/patch-build-scons-tools-scons_configure.py
new file mode 100644
index 000000000000..181ec2f82641
--- /dev/null
+++ b/games/widelands/files/patch-build-scons-tools-scons_configure.py
@@ -0,0 +1,29 @@
+--- build/scons-tools/scons_configure.py.orig 2008-10-05 18:59:26.000000000 +0400
++++ build/scons-tools/scons_configure.py 2008-11-10 01:24:38.000000000 +0300
+@@ -439,16 +439,16 @@
+ conf.CheckCompilerFlag('-fbounds-check', env)
+ conf.CheckCompilerFlag('-pipe', env)
+
+- if env.optimize:
+- # !!!! -fomit-frame-pointer breaks execeptions !!!!
+- conf.CheckCompilerFlag('-fexpensive-optimizations', env)
+- conf.CheckCompilerFlag('-finline-functions', env)
+- conf.CheckCompilerFlag('-ffast-math', env)
+- conf.CheckCompilerFlag('-funroll-loops', env)
+- conf.CheckCompilerFlag('-O3', env)
+- else:
+- conf.CheckCompilerFlag('-O0', env)
+- conf.CheckCompilerFlag('-funit-at-a-time', env)
++# if env.optimize:
++# # !!!! -fomit-frame-pointer breaks execeptions !!!!
++# conf.CheckCompilerFlag('-fexpensive-optimizations', env)
++# conf.CheckCompilerFlag('-finline-functions', env)
++# conf.CheckCompilerFlag('-ffast-math', env)
++# conf.CheckCompilerFlag('-funroll-loops', env)
++# conf.CheckCompilerFlag('-O3', env)
++# else:
++# conf.CheckCompilerFlag('-O0', env)
++# conf.CheckCompilerFlag('-funit-at-a-time', env)
+
+ if env.profile:
+ conf.CheckCompilerFlag('-pg', env)
diff --git a/games/widelands/files/patch-src_SConscript b/games/widelands/files/patch-src_SConscript
deleted file mode 100644
index 498d10c10c79..000000000000
--- a/games/widelands/files/patch-src_SConscript
+++ /dev/null
@@ -1,19 +0,0 @@
---- src/SConscript.orig Mon Feb 19 19:33:47 2007
-+++ src/SConscript Sat Jun 2 02:47:39 2007
-@@ -5,7 +5,7 @@
-
- SRC=Glob('*.cc')
-
--srcenv=env.Copy()
-+srcenv=env.Copy(CPPPATH=[], LIBPATH=[])
-
- srcenv.Append(CPPPATH=[
- '#/src',
-@@ -22,6 +22,7 @@
- srcenv.Append(LIBS='editor', LIBPATH='editor')
- srcenv.Append(LIBS='editoruimenus', LIBPATH='editor/ui_menus')
- srcenv.Append(LIBS='editortools', LIBPATH='editor/tools')
-+srcenv.Append(CPPPATH=env['CPPPATH'], LIBPATH=env['LIBPATH'])
-
- SConscript('editor/SConscript')
- SConscript('ui/ui_basic/SConscript')