feat(prboom): TOML recipe

Signed-off-by: Anhad Singh <andypython@protonmail.com>
This commit is contained in:
Anhad Singh 2025-02-02 16:41:48 +11:00
parent 7a0b6a54ab
commit 49b31c3d89
No known key found for this signature in database
GPG Key ID: 80E0357347554B89
2 changed files with 35 additions and 42 deletions

View File

@ -1,42 +0,0 @@
#TODO: remove --without-mixer when it no longer crashes on x86_64
VERSION=2.5.0
TAR=https://downloads.sourceforge.net/project/prboom/prboom%20stable/$VERSION/prboom-$VERSION.tar.gz
BUILD_DEPENDS=(sdl1 liborbital sdl1-mixer libogg libvorbis)
function recipe_version {
echo "$VERSION"
skip=1
}
function recipe_build {
export CFLAGS="-static"
export MIXER_LIBS="-lSDL_mixer -lvorbisfile -lvorbis -logg"
sysroot="$(realpath ../sysroot)"
autoreconf -if
wget -O autotools/config.sub "https://gitlab.redox-os.org/redox-os/gnu-config/-/raw/master/config.sub?inline=false"
./configure \
--prefix=/ \
--build=${BUILD} \
--host=${HOST} \
--disable-cpu-opt \
--disable-i386-asm \
--disable-gl \
--disable-sdltest \
--without-mixer \
--without-net \
--with-sdl-prefix="$sysroot" \
ac_cv_lib_SDL_mixer_Mix_OpenAudio=yes
"$REDOX_MAKE" -j"$($NPROC)"
skip=1
}
function recipe_clean {
"$REDOX_MAKE" clean
skip=1
}
function recipe_stage {
dest="$(realpath $1)"
"$REDOX_MAKE" DESTDIR="$dest/usr" install
skip=1
}

View File

@ -0,0 +1,35 @@
#TODO: remove --without-mixer when it no longer crashes on x86_64
[source]
tar = "https://downloads.sourceforge.net/project/prboom/prboom%20stable/2.5.0/prboom-2.5.0.tar.gz"
blake3 = "24c1b9b5aa15fd73e59162055f2c6d8faa82759b76ddfca9828cd2a5c8dc6b2a"
script = """
DYNAMIC_INIT
autotools_recursive_regenerate
wget -O autotools/config.sub "https://gitlab.redox-os.org/redox-os/gnu-config/-/raw/master/config.sub?inline=false"
"""
[build]
template = "custom"
dependencies = [
"sdl1",
"liborbital",
"sdl1-mixer",
"libogg",
"libvorbis"
]
script = """
export CFLAGS="-static"
export MIXER_LIBS="-lSDL_mixer -lvorbisfile -lvorbis -logg"
COOKBOOK_CONFIGURE_FLAGS+=(
--disable-cpu-opt
--disable-i386-asm
--disable-gl
--disable-sdltest
--without-mixer
--without-net
--with-sdl-prefix="${COOKBOOK_SYSROOT}"
ac_cv_lib_SDL_mixer_Mix_OpenAudio=yes
)
cookbook_configure
"""