pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/games games/powder-toy: Add version 74.1



details:   https://anonhg.NetBSD.org/pkgsrc/rev/823c6ee4a01e
branches:  trunk
changeset: 322245:823c6ee4a01e
user:      nia <nia%pkgsrc.org@localhost>
date:      Sat Apr 13 12:08:04 2019 +0000

description:
games/powder-toy: Add version 74.1

The Powder Toy is a free physics sandbox game, which simulates air
pressure and velocity, heat, gravity and a countless number of
interactions between different substances! The game provides you
with various building materials, liquids, gases and electronic
components.

diffstat:

 games/Makefile                                              |   3 +-
 games/powder-toy/DESCR                                      |   5 +
 games/powder-toy/Makefile                                   |  63 ++++++++++
 games/powder-toy/PLIST                                      |  12 ++
 games/powder-toy/distinfo                                   |  10 +
 games/powder-toy/options.mk                                 |  42 +++++++
 games/powder-toy/patches/patch-SConscript                   |  78 +++++++++++++
 games/powder-toy/patches/patch-resources_powder.appdata.xml |  14 ++
 games/powder-toy/patches/patch-resources_powder.desktop     |  16 ++
 games/powder-toy/patches/patch-src_Config.h                 |  15 ++
 10 files changed, 257 insertions(+), 1 deletions(-)

diffs (truncated from 308 to 300 lines):

diff -r 10802068e17a -r 823c6ee4a01e games/Makefile
--- a/games/Makefile    Sat Apr 13 08:48:22 2019 +0000
+++ b/games/Makefile    Sat Apr 13 12:08:04 2019 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.424 2019/04/11 20:56:34 nia Exp $
+# $NetBSD: Makefile,v 1.425 2019/04/13 12:08:04 nia Exp $
 #
 
 COMMENT=       Games
@@ -283,6 +283,7 @@
 SUBDIR+=       pmars
 SUBDIR+=       polyglot
 SUBDIR+=       powder
+SUBDIR+=       powder-toy
 SUBDIR+=       powermanga
 SUBDIR+=       powwow
 SUBDIR+=       prboom
diff -r 10802068e17a -r 823c6ee4a01e games/powder-toy/DESCR
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/games/powder-toy/DESCR    Sat Apr 13 12:08:04 2019 +0000
@@ -0,0 +1,5 @@
+The Powder Toy is a free physics sandbox game, which simulates air
+pressure and velocity, heat, gravity and a countless number of
+interactions between different substances! The game provides you
+with various building materials, liquids, gases and electronic
+components.
diff -r 10802068e17a -r 823c6ee4a01e games/powder-toy/Makefile
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/games/powder-toy/Makefile Sat Apr 13 12:08:04 2019 +0000
@@ -0,0 +1,63 @@
+# $NetBSD: Makefile,v 1.1 2019/04/13 12:08:04 nia Exp $
+
+DISTNAME=      powder-toy-94.1
+CATEGORIES=    games
+MASTER_SITES=  ${MASTER_SITE_GITHUB:=ThePowderToy/}
+GITHUB_PROJECT=        The-Powder-Toy
+GITHUB_TAG=    v${PKGVERSION_NOREV}
+
+MAINTAINER=    nia%NetBSD.org@localhost
+HOMEPAGE=      https://powdertoy.co.uk/
+COMMENT=       Desktop version of the 'falling sand' physics sandbox
+LICENSE=       gnu-gpl-v3
+
+USE_TOOLS+=    pkg-config
+USE_LANGUAGES= c c++11
+
+SCONS_ARGS+=   ${_MAKE_JOBS}
+SCONS_ARGS+=   --output=powder-toy
+
+CXXFLAGS+=     -DNO_INSTALL_CHECK
+
+INSTALLATION_DIRS+=    bin
+INSTALLATION_DIRS+=    libexec
+INSTALLATION_DIRS+=    share/appdata
+INSTALLATION_DIRS+=    share/applications
+INSTALLATION_DIRS+=    share/doc/powder-toy
+.for size in 16 24 32 48 128 256
+INSTALLATION_DIRS+=    share/icons/hicolor/${size}x${size}/apps
+.endfor
+
+.include "options.mk"
+
+do-build:
+       cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} ${SCONSBIN} ${SCONS_ARGS} \
+           CC=${CC:Q} CXX=${CXX:Q} CFLAGS=${CFLAGS:Q} CXXFLAGS=${CXXFLAGS:Q} \
+           LINKFLAGS=${LDFLAGS:Q} CPPPATH=${INCL_PATH:Q}
+       ${SED} -e 's,@PREFIX@,${PREFIX},g' < ${FILESDIR}/powder-toy.sh.in > \
+           ${WRKDIR}/powder-toy.sh
+
+do-install:
+       ${INSTALL_DATA} ${WRKSRC}/README.md \
+           ${DESTDIR}${PREFIX}/share/doc/powder-toy
+       ${INSTALL_DATA} ${WRKSRC}/resources/powder.desktop \
+           ${DESTDIR}${PREFIX}/share/applications/powder-toy.desktop
+       ${INSTALL_DATA} ${WRKSRC}/resources/powder.appdata.xml \
+           ${DESTDIR}${PREFIX}/share/appdata/powder-toy.appdata.xml
+       ${INSTALL_SCRIPT} ${WRKDIR}/powder-toy.sh \
+           ${DESTDIR}${PREFIX}/bin/powder-toy
+       ${INSTALL_PROGRAM} ${WRKSRC}/build/powder-toy \
+           ${DESTDIR}${PREFIX}/libexec
+.for size in 16 24 32 48 128 256
+       ${INSTALL_DATA} ${WRKSRC}/resources/icon/powder-${size}.png \
+           ${DESTDIR}${PREFIX}/share/icons/hicolor/${size}x${size}/apps/powder-toy.png
+.endfor
+
+.include "../../archivers/bzip2/buildlink3.mk"
+.include "../../devel/SDL2/buildlink3.mk"
+.include "../../devel/scons/buildlink3.mk"
+.include "../../devel/zlib/buildlink3.mk"
+.include "../../graphics/hicolor-icon-theme/buildlink3.mk"
+.include "../../x11/libX11/buildlink3.mk"
+.include "../../mk/pthread.buildlink3.mk"
+.include "../../mk/bsd.pkg.mk"
diff -r 10802068e17a -r 823c6ee4a01e games/powder-toy/PLIST
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/games/powder-toy/PLIST    Sat Apr 13 12:08:04 2019 +0000
@@ -0,0 +1,12 @@
+@comment $NetBSD: PLIST,v 1.1 2019/04/13 12:08:04 nia Exp $
+bin/powder-toy
+libexec/powder-toy
+share/appdata/powder-toy.appdata.xml
+share/applications/powder-toy.desktop
+share/doc/powder-toy/README.md
+share/icons/hicolor/128x128/apps/powder-toy.png
+share/icons/hicolor/16x16/apps/powder-toy.png
+share/icons/hicolor/24x24/apps/powder-toy.png
+share/icons/hicolor/256x256/apps/powder-toy.png
+share/icons/hicolor/32x32/apps/powder-toy.png
+share/icons/hicolor/48x48/apps/powder-toy.png
diff -r 10802068e17a -r 823c6ee4a01e games/powder-toy/distinfo
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/games/powder-toy/distinfo Sat Apr 13 12:08:04 2019 +0000
@@ -0,0 +1,10 @@
+$NetBSD: distinfo,v 1.1 2019/04/13 12:08:04 nia Exp $
+
+SHA1 (powder-toy-94.1.tar.gz) = 14249c100e38971444bb96fd31ff26fd24cc2190
+RMD160 (powder-toy-94.1.tar.gz) = 88671b2007f2f1a2ecc3a079cc961d3475742f56
+SHA512 (powder-toy-94.1.tar.gz) = ecda20d206298ff605a3a361255a0766caceece4d268355e4dbf1d56ef78bd7c43e54560d1ad71f29a8c3572d66eca875d5539e1006b260e029561ab91bf34d4
+Size (powder-toy-94.1.tar.gz) = 1254309 bytes
+SHA1 (patch-SConscript) = e1b11abaf9100b2a509cefbfa713baf3c11a2c5a
+SHA1 (patch-resources_powder.appdata.xml) = e687b33b50c286ec2858bdf2024e201df4b8be8e
+SHA1 (patch-resources_powder.desktop) = 9c77feb557afbd2e5ad4fb0b5f15be1809214555
+SHA1 (patch-src_Config.h) = 01d9cced7a87b6f33b1974bf51dd9d93949d41a2
diff -r 10802068e17a -r 823c6ee4a01e games/powder-toy/options.mk
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/games/powder-toy/options.mk       Sat Apr 13 12:08:04 2019 +0000
@@ -0,0 +1,42 @@
+# $NetBSD: options.mk,v 1.1 2019/04/13 12:08:04 nia Exp $
+
+PKG_OPTIONS_VAR=       PKG_OPTIONS.powder-toy
+PKG_SUPPORTED_OPTIONS= debug fftw lua
+PKG_SUGGESTED_OPTIONS= fftw lua
+
+.include "../../mk/bsd.fast.prefs.mk"
+
+.if ${MACHINE_ARCH} == "i386" || ${MACHINE_ARCH} == "x86_64"
+PKG_SUPPORTED_OPTIONS+=        simd
+.endif
+
+.if ${MACHINE_ARCH} == "x86_64"
+PKG_SUGGESTED_OPTIONS+=        simd
+.endif
+
+.include "../../mk/bsd.options.mk"
+
+.if !empty(PKG_OPTIONS:Mdebug)
+SCONS_ARGS+=   --debugging
+.else
+SCONS_ARGS+=   --release
+.endif
+
+.if !empty(PKG_OPTIONS:Mfftw)
+.include "../../math/fftwf/buildlink3.mk"
+.else
+SCONS_ARGS+=   --nofft
+.endif
+
+.if !empty(PKG_OPTIONS:Mlua)
+.include "../../lang/lua51/buildlink3.mk"
+.else
+SCONS_ARGS+=   --nolua
+.endif
+
+.if !empty(PKG_OPTIONS:Msimd)
+SCONS_ARGS+=   --sse
+SCONS_ARGS+=   --sse2
+.else
+SCONS_ARGS+=   --no-sse
+.endif
diff -r 10802068e17a -r 823c6ee4a01e games/powder-toy/patches/patch-SConscript
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/games/powder-toy/patches/patch-SConscript Sat Apr 13 12:08:04 2019 +0000
@@ -0,0 +1,78 @@
+$NetBSD: patch-SConscript,v 1.1 2019/04/13 12:08:04 nia Exp $
+
+Support NetBSD.
+
+--- SConscript.orig    2019-02-21 05:23:45.000000000 +0000
++++ SConscript
+@@ -88,7 +88,7 @@ elif GetOption('lin'):
+       platform = "Linux"
+ elif GetOption('mac'):
+       platform = "Darwin"
+-elif compilePlatform not in ["Linux", "Windows", "Darwin", "FreeBSD"]:
++elif compilePlatform not in ["Linux", "Windows", "Darwin", "FreeBSD", "NetBSD"]:
+       FatalError("Unknown platform: {0}".format(platform))
+ 
+ msvc = GetOption('msvc')
+@@ -243,11 +243,11 @@ def findLibs(env, conf):
+                       FatalError("libSDL2main not found or not installed")
+ 
+       #Look for SDL
+-      runSdlConfig = platform == "Linux" or compilePlatform == "Linux" or platform == "FreeBSD"
++      runSdlConfig = platform == "Linux" or compilePlatform == "Linux" or platform == "FreeBSD" or platform == "NetBSD"
+       #if platform == "Darwin" and conf.CheckFramework("SDL"):
+       #       runSdlConfig = False
+-      if not conf.CheckLib("SDL2"):
+-              FatalError("SDL2 development library not found or not installed")
++      #if not conf.CheckLib("SDL2"):
++      #       FatalError("SDL2 development library not found or not installed")
+ 
+       if runSdlConfig:
+               try:
+@@ -267,10 +267,7 @@ def findLibs(env, conf):
+ 
+       if not GetOption('nolua') and not GetOption('renderer') and not GetOption('font'):
+               #Look for Lua
+-              if platform == "FreeBSD":
+-                      luaver = "lua-5.1"
+-              else:
+-                      luaver = "lua5.1"
++              luaver = "lua-5.1"
+               if GetOption('luajit'):
+                       if not conf.CheckLib(['luajit-5.1', 'luajit5.1', 'luajit2.0', 'luajit', 'libluajit']):
+                               FatalError("luajit development library not found or not installed")
+@@ -289,7 +286,7 @@ def findLibs(env, conf):
+                               if platform != "Darwin" or not conf.CheckFramework("Lua"):
+                                       FatalError("lua5.1 development library not found or not installed")
+               foundpkg = False
+-              if platform == "Linux" or platform == "FreeBSD":
++              if platform == "Linux" or platform == "FreeBSD" or platform == "NetBSD":
+                       try:
+                               env.ParseConfig("pkg-config --cflags {0}".format(luaver))
+                               env.ParseConfig("pkg-config --libs {0}".format(luaver))
+@@ -346,7 +343,7 @@ def findLibs(env, conf):
+ 
+       #Look for OpenGL libraries
+       if GetOption('opengl'):
+-              if platform == "Linux" or platform == "FreeBSD":
++              if platform == "Linux" or platform == "FreeBSD" or platform == "NetBSD":
+                       if not conf.CheckLib('GL'):
+                               FatalError("libGL not found or not installed")
+                       try:
+@@ -363,7 +360,7 @@ def findLibs(env, conf):
+                       if not conf.CheckFramework("OpenGL"):
+                               FatalError("OpenGL framework not found or not installed")
+ 
+-      if platform == "Linux" or platform == "FreeBSD":
++      if platform == "Linux" or platform == "FreeBSD" or platform == "NetBSD":
+               if not conf.CheckLib('X11'):
+                       FatalError("X11 development library not found or not installed")
+ 
+@@ -418,7 +415,7 @@ if platform == "Windows":
+                       env.Append(LINKFLAGS=['/NODEFAULTLIB:msvcrtd.lib'])
+       else:
+               env.Append(LINKFLAGS=['-mwindows'])
+-elif platform == "Linux" or platform == "FreeBSD":
++elif platform == "Linux" or platform == "FreeBSD" or platform == "NetBSD":
+       env.Append(CPPDEFINES=['LIN'])
+ elif platform == "Darwin":
+       env.Append(CPPDEFINES=['MACOSX'])
diff -r 10802068e17a -r 823c6ee4a01e games/powder-toy/patches/patch-resources_powder.appdata.xml
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/games/powder-toy/patches/patch-resources_powder.appdata.xml       Sat Apr 13 12:08:04 2019 +0000
@@ -0,0 +1,14 @@
+$NetBSD: patch-resources_powder.appdata.xml,v 1.1 2019/04/13 12:08:04 nia Exp $
+
+Rename application to powder-toy.
+
+--- resources/powder.appdata.xml.orig  2019-02-21 05:23:45.000000000 +0000
++++ resources/powder.appdata.xml
+@@ -1,6 +1,6 @@
+ <?xml version="1.0" encoding="UTF-8"?>
+ <component type="desktop">
+-  <id>powder.desktop</id>
++  <id>powder-toy.desktop</id>
+   <metadata_license>CC0-1.0</metadata_license>
+   <project_license>GPL-3.0</project_license>
+   <name>Powder Toy</name>
diff -r 10802068e17a -r 823c6ee4a01e games/powder-toy/patches/patch-resources_powder.desktop
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/games/powder-toy/patches/patch-resources_powder.desktop   Sat Apr 13 12:08:04 2019 +0000
@@ -0,0 +1,16 @@
+$NetBSD: patch-resources_powder.desktop,v 1.1 2019/04/13 12:08:04 nia Exp $
+
+Rename application to powder-toy.
+
+--- resources/powder.desktop.orig      2019-02-21 05:23:45.000000000 +0000
++++ resources/powder.desktop
+@@ -3,7 +3,7 @@ Version=1.0
+ Encoding=UTF-8
+ Name=Powder Toy
+ Comment=Physics sandbox game
+-Exec=powder
+-Icon=powder
++Exec=powder-toy
++Icon=powder-toy
+ Type=Application
+ Categories=Game;Simulation;
diff -r 10802068e17a -r 823c6ee4a01e games/powder-toy/patches/patch-src_Config.h
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/games/powder-toy/patches/patch-src_Config.h       Sat Apr 13 12:08:04 2019 +0000
@@ -0,0 +1,15 @@
+$NetBSD: patch-src_Config.h,v 1.1 2019/04/13 12:08:04 nia Exp $
+
+Disable auto-updater.
+
+--- src/Config.h.orig  2019-02-21 05:23:45.000000000 +0000
++++ src/Config.h
+@@ -40,7 +40,7 @@



Home | Main Index | Thread Index | Old Index