pkgsrc-Changes-HG archive

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

[pkgsrc/trunk]: pkgsrc/games Add games/fallingtime. Based on work by Charlott...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/015931e3b5f1
branches:  trunk
changeset: 340099:015931e3b5f1
user:      nia <nia%pkgsrc.org@localhost>
date:      Sun Sep 22 12:10:45 2019 +0000

description:
Add games/fallingtime. Based on work by Charlotte Koch in wip.

Like the Fall Down games, you are a ball and you must fall into the holes to
avoid being crushed by the top of the screen!

diffstat:

 games/Makefile                                                       |   3 +-
 games/fallingtime/DESCR                                              |   2 +
 games/fallingtime/Makefile                                           |  43 ++++++++
 games/fallingtime/PLIST                                              |  44 ++++++++
 games/fallingtime/distinfo                                           |  10 +
 games/fallingtime/files/fallingtime                                  |   6 +
 games/fallingtime/files/fallingtime.template                         |   6 +
 games/fallingtime/patches/patch-CMakeLists.txt                       |  33 ++++++
 games/fallingtime/patches/patch-cfgpath.h                            |  51 ++++++++++
 games/fallingtime/patches/patch-chipmunk_include_chipmunk_chipmunk.h |  16 +++
 games/fallingtime/patches/patch-pkg_default.gcw0.desktop             |  21 ++++
 11 files changed, 234 insertions(+), 1 deletions(-)

diffs (289 lines):

diff -r edf9b98432ce -r 015931e3b5f1 games/Makefile
--- a/games/Makefile    Sun Sep 22 10:05:30 2019 +0000
+++ b/games/Makefile    Sun Sep 22 12:10:45 2019 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.457 2019/09/21 15:19:17 nia Exp $
+# $NetBSD: Makefile,v 1.458 2019/09/22 12:10:45 nia Exp $
 #
 
 COMMENT=       Games
@@ -113,6 +113,7 @@
 SUBDIR+=       exult
 SUBDIR+=       exult-audio
 SUBDIR+=       falcons-eye
+SUBDIR+=       fallingtime
 SUBDIR+=       fillets-ng
 SUBDIR+=       fillets-ng-data
 SUBDIR+=       finalbattle
diff -r edf9b98432ce -r 015931e3b5f1 games/fallingtime/DESCR
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/games/fallingtime/DESCR   Sun Sep 22 12:10:45 2019 +0000
@@ -0,0 +1,2 @@
+Like the Fall Down games, you are a ball and you must fall into the holes to
+avoid being crushed by the top of the screen!
diff -r edf9b98432ce -r 015931e3b5f1 games/fallingtime/Makefile
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/games/fallingtime/Makefile        Sun Sep 22 12:10:45 2019 +0000
@@ -0,0 +1,43 @@
+# $NetBSD: Makefile,v 1.1 2019/09/22 12:10:45 nia Exp $
+
+DISTNAME=      fallingtime-1.0.1
+CATEGORIES=    games
+MASTER_SITES=  ${MASTER_SITE_GITHUB:=cxong/}
+GITHUB_PROJECT=        FallingTime
+GITHUB_TAG=    1.0.1
+
+MAINTAINER=    cfkoch%edgebsd.org@localhost
+HOMEPAGE=      https://github.com/cxong/FallingTime
+COMMENT=       Arcade game inspired by Fall Down
+LICENSE=       gnu-gpl-v2
+
+EXTRACT_USING= bsdtar
+WRKSRC=                ${WRKDIR}/${GITHUB_PROJECT}-${GITHUB_TAG}
+USE_CMAKE=     yes
+USE_TOOLS+=    pkg-config
+USE_LANGUAGES= c c++
+
+CMAKE_ARGS+=   -DINSTALL_PREFIX=${PREFIX}/libexec
+CMAKE_ARGS+=   -DINSTALL_DATA_PREFIX=${PREFIX}/share/fallingtime
+
+INSTALLATION_DIRS+=    bin
+INSTALLATION_DIRS+=    share/applications
+INSTALLATION_DIRS+=    share/pixmaps
+
+pre-configure:
+       ${SED} -e 's,@@PREFIX@@,${PREFIX},g' \
+           ${FILESDIR}/fallingtime.template > ${WRKDIR}/fallingtime
+
+post-install:
+       ${INSTALL_SCRIPT} ${WRKDIR}/fallingtime \
+           ${DESTDIR}${PREFIX}/bin/fallingtime
+       ${INSTALL_DATA} ${WRKSRC}/pkg/default.gcw0.desktop \
+           ${DESTDIR}${PREFIX}/share/applications/fallingtime.desktop
+       ${INSTALL_DATA} ${WRKSRC}/data/graphics/icon.png \
+           ${DESTDIR}${PREFIX}/share/pixmaps/fallingtime.png
+
+.include "../../devel/SDL2/buildlink3.mk"
+.include "../../audio/SDL2_mixer/buildlink3.mk"
+.include "../../fonts/SDL2_ttf/buildlink3.mk"
+.include "../../graphics/SDL2_image/buildlink3.mk"
+.include "../../mk/bsd.pkg.mk"
diff -r edf9b98432ce -r 015931e3b5f1 games/fallingtime/PLIST
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/games/fallingtime/PLIST   Sun Sep 22 12:10:45 2019 +0000
@@ -0,0 +1,44 @@
+@comment $NetBSD: PLIST,v 1.1 2019/09/22 12:10:45 nia Exp $
+bin/fallingtime
+libexec/falling_time
+share/applications/fallingtime.desktop
+share/fallingtime/data/LondrinaSolid-Regular.otf
+share/fallingtime/data/graphics/360.png
+share/fallingtime/data/graphics/anim.png
+share/fallingtime/data/graphics/eggplant.png
+share/fallingtime/data/graphics/flare.png
+share/fallingtime/data/graphics/floor0.png
+share/fallingtime/data/graphics/floor1.png
+share/fallingtime/data/graphics/floor2.png
+share/fallingtime/data/graphics/floor3.png
+share/fallingtime/data/graphics/floor4.png
+share/fallingtime/data/graphics/floor5.png
+share/fallingtime/data/graphics/gameover.png
+share/fallingtime/data/graphics/gcw0.png
+share/fallingtime/data/graphics/gcw0analog.png
+share/fallingtime/data/graphics/gcw0g.png
+share/fallingtime/data/graphics/gcw1.png
+share/fallingtime/data/graphics/icebergs.png
+share/fallingtime/data/graphics/icon.png
+share/fallingtime/data/graphics/keyboard0.png
+share/fallingtime/data/graphics/keyboard1.png
+share/fallingtime/data/graphics/penguin_ball.png
+share/fallingtime/data/graphics/penguin_black.png
+share/fallingtime/data/graphics/penguin_blue.png
+share/fallingtime/data/graphics/penguin_red.png
+share/fallingtime/data/graphics/sparks.png
+share/fallingtime/data/graphics/sparks_red.png
+share/fallingtime/data/graphics/stars.png
+share/fallingtime/data/graphics/tail.png
+share/fallingtime/data/sounds/beep.ogg
+share/fallingtime/data/sounds/bounce.ogg
+share/fallingtime/data/sounds/chicken.ogg
+share/fallingtime/data/sounds/lose.ogg
+share/fallingtime/data/sounds/music.ogg
+share/fallingtime/data/sounds/penguin.ogg
+share/fallingtime/data/sounds/quack.ogg
+share/fallingtime/data/sounds/roll.ogg
+share/fallingtime/data/sounds/score.ogg
+share/fallingtime/data/sounds/start.ogg
+share/fallingtime/data/sounds/turkey.ogg
+share/pixmaps/fallingtime.png
diff -r edf9b98432ce -r 015931e3b5f1 games/fallingtime/distinfo
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/games/fallingtime/distinfo        Sun Sep 22 12:10:45 2019 +0000
@@ -0,0 +1,10 @@
+$NetBSD: distinfo,v 1.1 2019/09/22 12:10:45 nia Exp $
+
+SHA1 (fallingtime-1.0.1.tar.gz) = 40abd3595f891b33fcc26f39379ea04be73fa5ba
+RMD160 (fallingtime-1.0.1.tar.gz) = 47591713db84edbc6ed7450dcd9ec4695e676703
+SHA512 (fallingtime-1.0.1.tar.gz) = 1e169faf407d6ba6137275e459eb14d7759bf248eec615d139236e8bbc0acffe92cdd1309d66f415847d5682681bbff9ea10a63626cc604ac7698c126d2cf446
+Size (fallingtime-1.0.1.tar.gz) = 1875727 bytes
+SHA1 (patch-CMakeLists.txt) = 27d7c488cdd24162f49f3391c75e7b8afb8ba521
+SHA1 (patch-cfgpath.h) = 95f82b5c981136a43b68764b33ded926e4dd807a
+SHA1 (patch-chipmunk_include_chipmunk_chipmunk.h) = 076caf52ccd588c59f0448050350af7209f6360e
+SHA1 (patch-pkg_default.gcw0.desktop) = c3cc6d289369cbfb49ea3adf2f068c49717a71af
diff -r edf9b98432ce -r 015931e3b5f1 games/fallingtime/files/fallingtime
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/games/fallingtime/files/fallingtime       Sun Sep 22 12:10:45 2019 +0000
@@ -0,0 +1,6 @@
+#!/bin/sh
+#
+# $NetBSD: fallingtime,v 1.1 2019/09/22 12:10:45 nia Exp $
+# Launcher script for fallingtime.
+
+cd /usr/pkg/share/fallingtime && /usr/pkg/libexec/falling_time
diff -r edf9b98432ce -r 015931e3b5f1 games/fallingtime/files/fallingtime.template
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/games/fallingtime/files/fallingtime.template      Sun Sep 22 12:10:45 2019 +0000
@@ -0,0 +1,6 @@
+#!/bin/sh
+#
+# $NetBSD: fallingtime.template,v 1.1 2019/09/22 12:10:45 nia Exp $
+# Launcher script for fallingtime.
+
+cd @@PREFIX@@/share/fallingtime && @@PREFIX@@/libexec/falling_time
diff -r edf9b98432ce -r 015931e3b5f1 games/fallingtime/patches/patch-CMakeLists.txt
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/games/fallingtime/patches/patch-CMakeLists.txt    Sun Sep 22 12:10:45 2019 +0000
@@ -0,0 +1,33 @@
+$NetBSD: patch-CMakeLists.txt,v 1.1 2019/09/22 12:10:45 nia Exp $
+
+Set the correct install prefix.
+
+--- CMakeLists.txt.orig        2015-10-21 09:55:38.000000000 +0000
++++ CMakeLists.txt
+@@ -126,13 +126,11 @@ set_target_properties(falling_time PROPE
+ ################
+ 
+ # Executables
+-set(INSTALL_PREFIX ".")
+ if(WIN32)
+       set(EXE_EXTENSION ".exe")
+       set(LIB_EXTENSION ".dll")
+ elseif(APPLE)
+       set(LIB_EXTENSION ".dylib")
+-      set(INSTALL_PREFIX "falling_time")
+ else()
+       set(EXE_EXTENSION "")
+       set(LIB_EXTENSION ".so")
+@@ -151,11 +149,7 @@ endif()
+ SET(SOURCE_DIRECTORY ".")
+ INSTALL(DIRECTORY
+       ${SOURCE_DIRECTORY}/data
+-      DESTINATION ${INSTALL_PREFIX})
+-INSTALL(FILES
+-      ${SOURCE_DIRECTORY}/COPYRIGHT
+-      ${SOURCE_DIRECTORY}/README.md
+-      DESTINATION ${INSTALL_PREFIX})
++      DESTINATION ${INSTALL_DATA_PREFIX})
+ IF(UNIX AND NOT APPLE AND NOT BEOS AND NOT HAIKU)
+       # TODO: .desktop file and png icon
+ elseif(WIN32)
diff -r edf9b98432ce -r 015931e3b5f1 games/fallingtime/patches/patch-cfgpath.h
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/games/fallingtime/patches/patch-cfgpath.h Sun Sep 22 12:10:45 2019 +0000
@@ -0,0 +1,51 @@
+$NetBSD: patch-cfgpath.h,v 1.1 2019/09/22 12:10:45 nia Exp $
+
+Support NetBSD.
+
+--- ./cfgpath.h.orig   2015-10-21 02:55:38.000000000 -0700
++++ ./cfgpath.h        2016-01-23 22:09:05.000000000 -0800
+@@ -39,7 +39,7 @@
+ #define mkdir _mkdir
+ #endif
+ 
+-#ifdef __linux__
++#if defined(__linux__) || defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__DragonFly__)
+ #include <string.h>
+ #include <stdlib.h>
+ #include <sys/stat.h>
+@@ -88,7 +88,7 @@
+  */
+ static inline void get_user_config_file(char *out, unsigned int maxlen, const char *appname)
+ {
+-#ifdef __linux__
++#if defined(__linux__) || defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__DragonFly__)
+       const char *out_orig = out;
+       char *home = getenv("XDG_CONFIG_HOME");
+       unsigned int config_len = 0;
+@@ -194,7 +194,7 @@
+  */
+ static inline void get_user_config_folder(char *out, unsigned int maxlen, const char *appname)
+ {
+-#ifdef __linux__
++#if defined(__linux__) || defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__DragonFly__)
+       const char *out_orig = out;
+       char *home = getenv("XDG_CONFIG_HOME");
+       unsigned int config_len = 0;
+@@ -311,7 +311,7 @@
+  */
+ static inline void get_user_data_folder(char *out, unsigned int maxlen, const char *appname)
+ {
+-#ifdef __linux__
++#if defined(__linux__) || defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__DragonFly__)
+       const char *out_orig = out;
+       char *home = getenv("XDG_DATA_HOME");
+       unsigned int config_len = 0;
+@@ -396,7 +396,7 @@
+  */
+ static inline void get_user_cache_folder(char *out, unsigned int maxlen, const char *appname)
+ {
+-#ifdef __linux__
++#if defined(__linux__) || defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__DragonFly__)
+       const char *out_orig = out;
+       char *home = getenv("XDG_CACHE_HOME");
+       unsigned int config_len = 0;
diff -r edf9b98432ce -r 015931e3b5f1 games/fallingtime/patches/patch-chipmunk_include_chipmunk_chipmunk.h
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/games/fallingtime/patches/patch-chipmunk_include_chipmunk_chipmunk.h      Sun Sep 22 12:10:45 2019 +0000
@@ -0,0 +1,16 @@
+$NetBSD: patch-chipmunk_include_chipmunk_chipmunk.h,v 1.1 2019/09/22 12:10:45 nia Exp $
+
+Support alloca in stdlib.
+
+--- chipmunk/include/chipmunk/chipmunk.h.orig  2015-10-21 09:55:38.000000000 +0000
++++ chipmunk/include/chipmunk/chipmunk.h
+@@ -32,6 +32,9 @@
+ #ifdef WIN32
+       // For alloca().
+       #include <malloc.h>
++#endif
++#if defined(__NetBSD__) || defined(__FreeBSD__)
++      #include <stdlib.h>
+ #else
+       #include <alloca.h>
+ #endif
diff -r edf9b98432ce -r 015931e3b5f1 games/fallingtime/patches/patch-pkg_default.gcw0.desktop
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/games/fallingtime/patches/patch-pkg_default.gcw0.desktop  Sun Sep 22 12:10:45 2019 +0000
@@ -0,0 +1,21 @@
+$NetBSD: patch-pkg_default.gcw0.desktop,v 1.1 2019/09/22 12:10:45 nia Exp $
+
+Correct icon and executable name.
+
+--- pkg/default.gcw0.desktop.orig      2015-10-21 09:55:38.000000000 +0000
++++ pkg/default.gcw0.desktop
+@@ -1,11 +1,7 @@
+ [Desktop Entry]
+-
+ Name=Falling Time
+ Comment=Guide a falling ball through blocks. Avoid getting crushed!
+-Icon=icon
+-Exec=falling_time
++Icon=fallingtime
++Exec=fallingtime
+ Terminal=false
+-Type=Application
+-StartupNotify=true
+-Categories=games;
+-X-OD-NeedsGSensor=true
++Categories=Game;ArcadeGame;



Home | Main Index | Thread Index | Old Index