diff options
author | B. Watson <yalhcru@gmail.com> | 2021-10-27 14:06:42 -0400 |
---|---|---|
committer | Willy Sudiarto Raharjo <willysr@slackbuilds.org> | 2021-10-29 17:07:25 +0700 |
commit | 16f3196e369dfafcc57fd86ee22204a0f9293c63 (patch) | |
tree | 7d262e7310f7539417edeff8e0639879adad5b2b /games | |
parent | ced5f851e28d3fdb521dc0f83f7c662a24c80665 (diff) |
games/prboom-plus: Updated for version 2.6.1um, fix segfault.
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/prboom-plus/README | 12 | ||||
-rw-r--r-- | games/prboom-plus/prboom-plus.SlackBuild | 47 | ||||
-rw-r--r-- | games/prboom-plus/prboom-plus.info | 6 |
3 files changed, 40 insertions, 25 deletions
diff --git a/games/prboom-plus/README b/games/prboom-plus/README index 401bdfb67586..8269961fd174 100644 --- a/games/prboom-plus/README +++ b/games/prboom-plus/README @@ -14,5 +14,15 @@ shareware doom1.wad) may be placed. The IWAD directory is /usr/share/games/doom. If you don't have any IWADs, install doom_shareware_data to play shareware Doom. -Optional dependencies, autodetected: +Optional dependency, autodetected: portmidi - for the PortMIDI backend. Most users won't need this. + +*** NOTE *** + +Currently the SDL MIDI player is broken. The default player in this +build is OPL2. You won't be able to select SDL from the "Preferred +MIDI Player" menu in the game options. If you have an old config +file that sets snd_midiplayer to "sdl", the music will sound *really* +messed up. If this happens, simply edit ~/.prboom-plus/prboom-plus.cfg +and remove the line containing snd_midiplayer. Or just delete the +file, to start with default settings. diff --git a/games/prboom-plus/prboom-plus.SlackBuild b/games/prboom-plus/prboom-plus.SlackBuild index d9fd48bdbd43..1798871c2514 100644 --- a/games/prboom-plus/prboom-plus.SlackBuild +++ b/games/prboom-plus/prboom-plus.SlackBuild @@ -7,13 +7,13 @@ # Original had no license. Modified version released under the WTFPL. See # http://www.wtfpl.net/txt/copying/ for details. +# 20211027 bkw: +# - update for v2.6.1um. +# - band-aid for segfaults on -current (see below). this isn't +# a side-effect of the version upgrade: it happens on 2.6um also. + # 20210223 bkw: update for v2.6um. Upstream switched to cmake, -# so we can't build previous versions any more. A note to myself: -# SDL2 really is required. SDL2_(net|mixer|image) are technically -# optional. But I'm keeping them listed as requirements because users -# will get annoyed if they accidentally build a Doom engine that's -# incapable of playing music, or joining multiplayer games, or using -# HQ textures. +# so we can't build previous versions any more. # 20200416 bkw: # - take over maintenance @@ -26,7 +26,7 @@ cd $(dirname $0) ; CWD=$(pwd) PRGNAM=prboom-plus -VERSION=${VERSION:-2.6um} +VERSION=${VERSION:-2.6.1um} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} PKGTYPE=${PKGTYPE:-tgz} @@ -39,9 +39,6 @@ if [ -z "$ARCH" ]; then esac fi -# If the variable PRINT_PACKAGE_NAME is set, then this script will report what -# the name of the created package would be, and then exit. This information -# could be useful to other scripts. if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE" exit 0 @@ -67,17 +64,6 @@ fi set -e -# If modern cmake is missing, the error message from the old 14.2 cmake -# doesn't really make it clear why it fails, so add this check to avoid -# receiving "why won't this build?" emails. This stanza can go away after -# 15.0 is released. -if ! [ -x /opt/cmake-202x/bin/cmake ]; then - echo "*** Missing required dependency: cmame-202x. Aborting." 1>&2 - exit 1 -fi - -export PATH=/opt/cmake-202x/bin:$PATH - rm -rf $PKG mkdir -p $TMP $PKG $OUTPUT cd $TMP @@ -94,9 +80,28 @@ find -L . -perm /111 -a \! -perm 755 -a -exec chmod 755 {} \+ -o \ sed -i '/install/s,/bin,/games,' src/CMakeLists.txt sed -i '/^set(CMAKE_INSTALL_DOCDIR/d' CMakeLists.txt +MIXEROPT=ON +if [ "${BANDAID:-yes}" = "yes" ]; then + # 20211027 bkw: Band-aid. The game segfaults when the midi backend + # is set to "sdl". Adding -DWITH_MIXER=OFF stops it segfaulting, but + # it sounds *horrible*. So this bit of sed changes the default sound + # backend to "opl2", which doesn't sound as nice, but allows the game + # to run. Also it increases the default volume, since the opl2 synth + # is quieter. + MIXEROPT=OFF + sed -i -e '/"snd_midiplayer"/s,"sdl","opl2",' \ + -e '/"music_volume"/s,8,12,' \ + src/m_misc.c + + # 2nd half of the band-aid: prevent the user from choosing SDL MIDI + # from the menu. + sed -i '/"snd_midiplayer"/s,midiplayers,&+1,' src/m_menu.c +fi + mkdir -p build cd build cmake \ + -DWITH_MIXER=$MIXEROPT \ -DCMAKE_C_FLAGS:STRING="$SLKCFLAGS" \ -DCMAKE_CXX_FLAGS:STRING="$SLKCFLAGS" \ -DCMAKE_INSTALL_PREFIX=/usr \ diff --git a/games/prboom-plus/prboom-plus.info b/games/prboom-plus/prboom-plus.info index 24990de824ff..3296e63a1d13 100644 --- a/games/prboom-plus/prboom-plus.info +++ b/games/prboom-plus/prboom-plus.info @@ -1,8 +1,8 @@ PRGNAM="prboom-plus" -VERSION="2.6um" +VERSION="2.6.1um" HOMEPAGE="http://prboom-plus.sourceforge.net" -DOWNLOAD="https://github.com/coelckers/prboom-plus/archive/v2.6um/prboom-plus-2.6um.tar.gz" -MD5SUM="5e294659988c0208fefa292557d8b746" +DOWNLOAD="https://github.com/coelckers/prboom-plus/archive/v2.6.1um/prboom-plus-2.6.1um.tar.gz" +MD5SUM="e887e6032912be38a8c3d47ef1c78194" DOWNLOAD_x86_64="" MD5SUM_x86_64="" REQUIRES="" |