diff options
author | B. Watson <yalhcru@gmail.com> | 2021-02-25 02:02:45 -0500 |
---|---|---|
committer | Willy Sudiarto Raharjo <willysr@slackbuilds.org> | 2021-02-27 08:24:37 +0700 |
commit | f7d1c506f63d6336fa0ba3dc0d91fe18188d7690 (patch) | |
tree | 98e8055279b6e948dfa3fb47ea48c956db9ce90b /games | |
parent | ad58997b24b73308f4a867c8f9816ade2f64705b (diff) | |
download | slackbuilds-f7d1c506f63d6336fa0ba3dc0d91fe18188d7690.tar.gz |
games/srb2: Updated for version 2.2.8.
Signed-off-by: B. Watson <yalhcru@gmail.com>
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'games')
-rw-r--r-- | games/srb2/README | 4 | ||||
-rw-r--r-- | games/srb2/srb2.SlackBuild | 48 | ||||
-rw-r--r-- | games/srb2/srb2.desktop | 4 | ||||
-rw-r--r-- | games/srb2/srb2.info | 20 |
4 files changed, 37 insertions, 39 deletions
diff --git a/games/srb2/README b/games/srb2/README index 61de91f456..73f6f2db87 100644 --- a/games/srb2/README +++ b/games/srb2/README @@ -12,3 +12,7 @@ installed. I'm not 100% sure what libgme does for srb2: it's a "game music emulation" library, but the game music doesn't sound different to me when srb2 is built with libgme, and I don't see any config settings to enable it. I haven't played the entire game yet though... + +Note for users upgrading from version 2.1.x to 2.2.x: I had to +delete my old config (rm -rf ~/.srb2) to get the game to run without +segfaulting. diff --git a/games/srb2/srb2.SlackBuild b/games/srb2/srb2.SlackBuild index 26fb5abb25..356c8bfb5c 100644 --- a/games/srb2/srb2.SlackBuild +++ b/games/srb2/srb2.SlackBuild @@ -7,7 +7,7 @@ # Licensed under the WTFPL. See http://www.wtfpl.net/txt/copying/ for details. PRGNAM=srb2 -VERSION=${VERSION:-2.1.21} +VERSION=${VERSION:-2.2.8} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} @@ -61,23 +61,24 @@ chown -R root:root . find -L . -perm /111 -a \! -perm 755 -a -exec chmod 755 {} \+ -o \ \! -perm /111 -a \! -perm 644 -a -exec chmod 644 {} \+ -# Assets (actually WAD files) aren't found in the source, have to download -# them separately. The build actually checks for them & refuses to compile -# if they're missing, which is kinda unfair since it doesn't ship with -# the damn things... To save 208MB of space in $TMP, we symlink the files. -# Can't just touch them, since the md5sums of the files get hardcoded -# into the binary (and it'll refuse to run if they don't match). -DATAFILES="srb2.srb zones.dta player.dta rings.dta music.dta patch.dta" -for i in $DATAFILES; do - ln -s $CWD/$i assets/$i -done +# Assets (actually WAD and pk3 aka zip files) aren't found in the +# source, have to download them separately. The build actually checks +# for them & refuses to compile if they're missing, which is kinda +# unfair since it doesn't ship with the damn things... so we have to +# extract them from the 'full' zip file. Can't just touch them, since +# the md5sums of the files get hardcoded into the binary (and it'll +# refuse to run if they don't match). +( cd assets + mkdir installer + cd installer + unzip $CWD/SRB2-v$VERSION-Full.zip '*.dta' '*.pk3' +) # As shipped, the path /usr/games/SRB2 is hardcoded in various places # in the source (no cmake variable to change it). It should be in # /usr/share/games, not /usr/games, so sed-fest: sed -i 's,usr/games,usr/share/games,g' \ - src/sdl/i_system.c src/sdl/i_ttf.c \ - src/sdl12/i_system.c src/sdl12/i_ttf.c + src/sdl/i_system.c src/sdl/i_ttf.c mkdir -p build cd build @@ -96,21 +97,24 @@ cd .. mkdir -p $PKG/usr/games $PKG/usr/share/games/SRB2 \ $PKG/usr/share/pixmaps $PKG/usr/share/applications \ $PKG/usr/doc/$PRGNAM-$VERSION -install -s -m0755 build/bin/$PRGNAM-$VERSION $PKG/usr/games -ln -s $PRGNAM-$VERSION $PKG/usr/games/$PRGNAM +# as of 2.2.8 the binary's name changed. +install -s -m0755 build/bin/lsdl$PRGNAM-$VERSION $PKG/usr/games +ln -s lsdl$PRGNAM-$VERSION $PKG/usr/games/lsdl$PRGNAM +ln -s lsdl$PRGNAM-$VERSION $PKG/usr/games/$PRGNAM install -m0644 assets/LICENSE* assets/README* $PKG/usr/doc/$PRGNAM-$VERSION install -m0644 $PRGNAM.png $PKG/usr/share/pixmaps -# Install data files from $CWD, not the symlinks in assets/ echo -n "Copying data files: " -for i in $DATAFILES; do - echo -n "$i " - cat $CWD/$i > $PKG/usr/share/games/SRB2/$i -done +( cd assets/installer + for i in *; do + echo -n "$i " + cat $i > $PKG/usr/share/games/SRB2/$i + done +) echo -# desktop file is a modified version of debian/srb2.desktop. I took out -# the absolute paths. +# desktop file is a modified version of debian/srb2.desktop. I fixed +# the absolute paths and got it to validate. cat $CWD/$PRGNAM.desktop > $PKG/usr/share/applications/$PRGNAM.desktop # dev and modding docs in doc/, config files for cwiid and various doom diff --git a/games/srb2/srb2.desktop b/games/srb2/srb2.desktop index 240596a7df..7675458e95 100644 --- a/games/srb2/srb2.desktop +++ b/games/srb2/srb2.desktop @@ -1,8 +1,8 @@ [Desktop Entry] Name=Sonic Robo Blast 2 Comment=A free 3D Sonic the Hedgehog fangame closely inspired by the original Sonic games on the Sega Genesis. -Exec=srb2 -Icon=srb2 +Exec=/usr/games/srb2 +Icon=/usr/share/pixmaps/srb2.png Terminal=false Type=Application StartupNotify=false diff --git a/games/srb2/srb2.info b/games/srb2/srb2.info index bffae6cbe0..08c0c3587a 100644 --- a/games/srb2/srb2.info +++ b/games/srb2/srb2.info @@ -1,20 +1,10 @@ PRGNAM="srb2" -VERSION="2.1.21" +VERSION="2.2.8" HOMEPAGE="https://www.srb2.org/" -DOWNLOAD="https://github.com/STJr/SRB2/archive/SRB2_release_2.1.21/SRB2-SRB2_release_2.1.21.tar.gz \ - http://alam.srb2.org/SRB2/2.1.21-Final/Resources/music.dta \ - http://alam.srb2.org/SRB2/2.1.21-Final/Resources/patch.dta \ - http://alam.srb2.org/SRB2/2.1.21-Final/Resources/player.dta \ - http://alam.srb2.org/SRB2/2.1.21-Final/Resources/rings.dta \ - http://alam.srb2.org/SRB2/2.1.21-Final/Resources/srb2.srb \ - http://alam.srb2.org/SRB2/2.1.21-Final/Resources/zones.dta" -MD5SUM="69c97da9638e3daedec5a8c7be76b5ab \ - 2a4b6ae74a84e990d6e6c81ad0c1309f \ - dbbf8bc6121618ee3be2d5b14650429b \ - cfca0f1c73023cbbd8f844f45480f799 \ - 85901ad4bf94637e5753d2ac2c03ea26 \ - c1b9577687f8a795104aef4600720ea7 \ - 303838c6c534d9540288360fa49cca60" +DOWNLOAD="https://github.com/STJr/SRB2/archive/SRB2_release_2.2.8/SRB2-SRB2_release_2.2.8.tar.gz \ + https://github.com/STJr/SRB2/releases/download/SRB2_release_2.2.8/SRB2-v2.2.8-Full.zip" +MD5SUM="24485b3fac77cc2de5ff164f29da81f1 \ + 46df8c6d29c1bca8c82af434e8f64313" DOWNLOAD_x86_64="" MD5SUM_x86_64="" REQUIRES="SDL2_mixer" |