diff --git a/recipes/freedoom/recipe.sh b/recipes/freedoom/recipe.sh index 262f1f1e3427c0c3ecafb794c7a071015efac8b8..19adca409f301ef1dfd0556a0eebf280f24bb6b5 100644 --- a/recipes/freedoom/recipe.sh +++ b/recipes/freedoom/recipe.sh @@ -1,4 +1,5 @@ GIT=https://github.com/redox-os/freedoom.git +DEPENDS=(ion prboom) function recipe_version { echo "0.11.3" @@ -26,8 +27,18 @@ function recipe_clean { } function recipe_stage { - mkdir -pv "$1/share/games/doom" - cp -Rv ./*.wad "$1/share/games/doom" + mkdir -pv "$1/games" "$1/share/games/doom" + for file in ./*.wad + do + game="$(basename "$file" .wad)" + + wad="/share/games/doom/$game.wad" + cp -v "$file" "$1$wad" + + bin="/games/$game" + echo "#!/bin/ion" > "$1$bin" + echo "/games/prboom -geom 800x600 -vidmode 32 -iwad $wad" >> "$1$bin" + chmod +x "$1$bin" + done skip=1 } -