mirror of
https://gitlab.redox-os.org/redox-os/redox.git
synced 2026-06-24 05:44:17 +08:00
Merge branch 'games' into 'master'
Fix some games See merge request redox-os/cookbook!686
This commit is contained in:
commit
1b85ee15de
@ -4,17 +4,14 @@ dependencies = [
|
||||
"sdl2-image",
|
||||
"sdl2-mixer",
|
||||
"sdl2-ttf",
|
||||
"llvm18",
|
||||
]
|
||||
script = """
|
||||
DYNAMIC_INIT
|
||||
cp "${COOKBOOK_SOURCE}/../gears.c" ./gears.c
|
||||
rsync -av --delete --exclude='.git' "${COOKBOOK_SOURCE}/../assets" ./assets
|
||||
${CXX} -O2 -I "${COOKBOOK_SYSROOT}/include" $LDFLAGS gears.c -o sdl2_gears \
|
||||
-dynamic -lSDL2_image -lSDL2_mixer -lSDL2_ttf -lSDL2 -lorbital \
|
||||
$("${PKG_CONFIG}" --libs osmesa) -lfreetype -lpng -ljpeg -lvorbisfile -lvorbis -logg -lz
|
||||
rm -rf "${COOKBOOK_STAGE}/usr/games/sdl2_gears"
|
||||
mkdir -pv "${COOKBOOK_STAGE}/usr/games/sdl2_gears"
|
||||
cp -v "sdl2_gears" "${COOKBOOK_STAGE}/usr/games/sdl2_gears/sdl2_gears"
|
||||
cp -rv "assets" "${COOKBOOK_STAGE}/usr/games/sdl2_gears/assets"
|
||||
mkdir -p "${COOKBOOK_STAGE}/usr/games/sdl2_gears"
|
||||
${CXX} -O2 -I "${COOKBOOK_SYSROOT}/include" $LDFLAGS ${COOKBOOK_RECIPE}/gears.c \
|
||||
-o sdl2_gears -dynamic \
|
||||
-lSDL2_image -lSDL2_mixer -lSDL2_ttf $("${PKG_CONFIG}" --libs osmesa) \
|
||||
-lSDL2 -lorbital -lfreetype -lpng -ljpeg -lvorbisfile -lvorbis -logg -lz
|
||||
cp -rv "${COOKBOOK_RECIPE}/assets" "${COOKBOOK_STAGE}/usr/games/sdl2_gears/"
|
||||
cp -v sdl2_gears "${COOKBOOK_STAGE}/usr/games/sdl2_gears/"
|
||||
"""
|
||||
|
||||
2
recipes/wip/games/action/openlara/assets/README.md
Normal file
2
recipes/wip/games/action/openlara/assets/README.md
Normal file
@ -0,0 +1,2 @@
|
||||
|
||||
To make assets working, purchase from https://www.gog.com/en/game/tomb_raider_123, then add 'audio', 'level', and 'video' to this folder. Additional info can be read from https://github.com/XProger/OpenLara/pull/414/files
|
||||
@ -1,5 +1,20 @@
|
||||
#TODO lacking a build system
|
||||
#TODO: Compiled, not tested further
|
||||
[source]
|
||||
git = "https://github.com/XProger/OpenLara"
|
||||
|
||||
[build]
|
||||
template = "custom"
|
||||
dependencies = [
|
||||
"sdl2",
|
||||
]
|
||||
script = """
|
||||
DYNAMIC_INIT
|
||||
SRC="${COOKBOOK_SOURCE}/src"
|
||||
mkdir -p "${COOKBOOK_STAGE}/usr/games/OpenLara"
|
||||
${CXX} "-I${COOKBOOK_SYSROOT}/include" "-I$SRC/" ${LDFLAGS} -DSDL2_GLES -D_GAPI_GLES2 -std=c++11 \
|
||||
-O3 -fno-exceptions -fno-rtti -ffunction-sections -fdata-sections -Wl,--gc-sections -DNDEBUG -D__SDL2__ \
|
||||
-dynamic -lSDL2 -lGLESv2 -lEGL $("${PKG_CONFIG}" --libs osmesa) -o OpenLara \
|
||||
$SRC/platform/sdl2/main.cpp "$SRC/libs/stb_vorbis/stb_vorbis.c" "$SRC/libs/minimp3/minimp3.cpp" "$SRC/libs/tinf/tinflate.c"
|
||||
cp -rv "${COOKBOOK_RECIPE}/assets" "${COOKBOOK_STAGE}/usr/games/sdl2_gears/"
|
||||
cp OpenLara ${COOKBOOK_STAGE}/usr/games/OpenLara/OpenLara
|
||||
"""
|
||||
|
||||
@ -1,8 +1,10 @@
|
||||
#TODO make all dependencies work
|
||||
#TODO quinn-udp crate error
|
||||
[source]
|
||||
git = "https://github.com/veloren/veloren"
|
||||
shallow = true
|
||||
[build]
|
||||
template = "cargo"
|
||||
package_path="client"
|
||||
dependencies = [
|
||||
"glib",
|
||||
"cairo",
|
||||
|
||||
@ -1,12 +1,15 @@
|
||||
#TODO not compiled or tested
|
||||
#TODO requires ifaddrs.h
|
||||
# build instructions: https://github.com/supertuxkart/stk-code/blob/master/INSTALL.md#compiling
|
||||
[source]
|
||||
tar = "https://github.com/supertuxkart/stk-code/releases/download/1.4/SuperTuxKart-1.4-src.tar.xz"
|
||||
tar = "https://github.com/supertuxkart/stk-code/releases/download/1.5/SuperTuxKart-1.5-src.tar.gz"
|
||||
[build]
|
||||
template = "cmake"
|
||||
cmakeflags = [
|
||||
"-DNO_SHADERC=ON",
|
||||
"-DUSE_WIIUSE=OFF",
|
||||
"-DUSE_DNS_C=ON",
|
||||
"-DBUILD_RECORDER=OFF",
|
||||
"-DPTHREAD_LIBRARY=/dev/null"
|
||||
]
|
||||
dependencies = [
|
||||
"openal",
|
||||
|
||||
15
recipes/wip/games/racing/supertuxkart/redox.patch
Normal file
15
recipes/wip/games/racing/supertuxkart/redox.patch
Normal file
@ -0,0 +1,15 @@
|
||||
diff -ruwN source/src/guiengine/widgets/spinner_widget.cpp source-new/src/guiengine/widgets/spinner_widget.cpp
|
||||
--- source/src/guiengine/widgets/spinner_widget.cpp 2025-10-20 04:04:17.000000000 +0700
|
||||
+++ source-new/src/guiengine/widgets/spinner_widget.cpp 2025-11-09 11:29:52.678400188 +0700
|
||||
@@ -493,10 +493,7 @@
|
||||
}
|
||||
else
|
||||
{
|
||||
- std::wstringstream ws;
|
||||
- ws << (m_value*m_step);
|
||||
- std::wstring text = ws.str();
|
||||
- m_children[1].m_element->setText( text.c_str() );
|
||||
+ m_children[1].m_element->setText( stringw(m_value*m_step).c_str() );
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -10,8 +10,6 @@ dependencies = [
|
||||
"libpng",
|
||||
"libjpeg",
|
||||
"sdl2",
|
||||
"mesa",
|
||||
"mesa-glu",
|
||||
"openal",
|
||||
"libvorbis",
|
||||
]
|
||||
|
||||
@ -1,33 +0,0 @@
|
||||
VERSION=1.0-rc3
|
||||
GIT=https://github.com/angelXwind/OpenSyobonAction
|
||||
BUILD_DEPENDS=(sdl1 liborbital sdl1-mixer sdl1-image sdl-gfx sdl1-ttf freetype2 libjpeg libpng zlib libogg libvorbis)
|
||||
|
||||
function recipe_version {
|
||||
echo "$VERSION"
|
||||
skip=1
|
||||
}
|
||||
|
||||
function recipe_build {
|
||||
sysroot="$(realpath ../sysroot)"
|
||||
export SDL_CONFIG="${PKG_CONFIG} sdl"
|
||||
export CPPFLAGS="-I$sysroot/include"
|
||||
export LDFLAGS="-L$sysroot/lib --static"
|
||||
"$REDOX_MAKE" -j"$($NPROC)"
|
||||
skip=1
|
||||
}
|
||||
|
||||
function recipe_clean {
|
||||
"$REDOX_MAKE" clean
|
||||
skip=1
|
||||
}
|
||||
|
||||
function recipe_stage {
|
||||
dest="$(realpath $1)"
|
||||
mkdir -pv "$1/bin"
|
||||
mkdir -pv "$1/share/syobonaction"
|
||||
cp -Rv ./SyobonAction "$1/bin/syobonaction"
|
||||
cp -Rv ./BGM "$1/share/syobonaction"
|
||||
cp -Rv ./res "$1/share/syobonaction"
|
||||
cp -Rv ./SE "$1/share/syobonaction"
|
||||
skip=1
|
||||
}
|
||||
26
recipes/wip/games/syobonaction/recipe.toml
Normal file
26
recipes/wip/games/syobonaction/recipe.toml
Normal file
@ -0,0 +1,26 @@
|
||||
[source]
|
||||
git = "https://github.com/angelXwind/OpenSyobonAction"
|
||||
patches = [
|
||||
"01_redox.patch"
|
||||
]
|
||||
|
||||
[build]
|
||||
template = "custom"
|
||||
dependencies = [
|
||||
"sdl1-mixer",
|
||||
"sdl1-image",
|
||||
"sdl-gfx",
|
||||
"sdl1-ttf",
|
||||
]
|
||||
script = """
|
||||
DYNAMIC_INIT
|
||||
export LDFLAGS="$LDFLAGS -lorbital"
|
||||
rsync -a --delete "${COOKBOOK_SOURCE}/" ./
|
||||
make
|
||||
mkdir -pv "${COOKBOOK_STAGE}/usr/bin"
|
||||
mkdir -pv "${COOKBOOK_STAGE}/usr/share/syobonaction"
|
||||
cp -Rv ./SyobonAction "${COOKBOOK_STAGE}/usr/bin/syobonaction"
|
||||
cp -Rv ./BGM "${COOKBOOK_STAGE}/usr/share/syobonaction"
|
||||
cp -Rv ./res "${COOKBOOK_STAGE}/usr/share/syobonaction"
|
||||
cp -Rv ./SE "${COOKBOOK_STAGE}/usr/share/syobonaction"
|
||||
"""
|
||||
Loading…
Reference in New Issue
Block a user