Update and add some games

master
Sven Slootweg 6 years ago
parent b652703a97
commit 29317e9fb7

@ -0,0 +1,39 @@
{ stdenv, pkgs, dosbox, unzip, ... }:
let
fetchfile = (import ../../lib/fetchfile.nix) { inherit stdenv pkgs; };
in
stdenv.mkDerivation {
name = "epic-pinball";
src = fetchfile {
path = ../../../nixrc-src-games/epic_pinball_the_complete_collection_en_1_0_16760.sh;
storeHash = "64545yf8d203lgk5jv5bqbnyh7xpblmb";
};
phases = "unpackPhase installPhase";
unpackCmd = "${unzip}/bin/unzip -qq $src || true";
sourceRoot = "data";
installPhase = ''
mkdir -p $out
mv noarch/*.conf $out/
mv noarch/data $out/data
mkdir -p $out/bin
cat <<EOF > $out/bin/epic-pinball
#!${stdenv.shell}
${dosbox}/bin/dosbox -conf "$out/dosbox_epin.conf" -conf "$out/dosbox_epin_single.conf" -conf "$out/sven.conf" -no-console -c exit
EOF
cat <<EOF > $out/sven.conf
[sdl]
fullscreen=false
output=openglnb
EOF
chmod +x $out/bin/epic-pinball
'';
}

@ -0,0 +1,60 @@
{ stdenv, pkgs, requireFile, SDL2, makeWrapper,
mesa_glu, alsaLib,
unzip, strace, ... }:
let
originalArchive = "gog_prison_architect_2.18.0.20.sh";
fetchfile = (import ../../lib/fetchfile.nix) { inherit stdenv pkgs; };
in
stdenv.mkDerivation rec {
name = "prison-architect-${version}";
version = "2.18.0.20";
src = fetchfile {
path = ../../../nixrc-src-games/gog_prison_architect_2.18.0.20.sh;
storeHash = "i2sl8hc5aaay2gw371zr0hpjdh6gw7ns";
};
phases = "unpackPhase installPhase";
unpackCmd = "${unzip}/bin/unzip -qq $src || true";
sourceRoot = "data";
libPath = stdenv.lib.makeLibraryPath [
mesa_glu
alsaLib
stdenv.cc.cc.lib
SDL2
];
buildInputs = [
makeWrapper
];
installPhase = ''
mkdir -p $out
mv noarch/game/* $out/
mkdir -p $out/bin
chmod +x $out/PrisonArchitect.x86_64
patchelf \
--set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) \
$out/PrisonArchitect.x86_64
#for lib in linux/*.so{,.*}; do
# patchelf --set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) $lib
#done
makeWrapper ${strace}/bin/strace $out/bin/prison-architect-strace \
--add-flags -f \
--add-flags $out/PrisonArchitect.x86_64 \
--set SDL_AUDIODRIVER alsa \
--prefix LD_LIBRARY_PATH : /run/opengl-driver/lib:$libPath
makeWrapper $out/PrisonArchitect.x86_64 $out/bin/prison-architect \
--set SDL_AUDIODRIVER alsa \
--prefix LD_LIBRARY_PATH : /run/opengl-driver/lib:$libPath
'';
}

@ -0,0 +1,72 @@
{
stdenv, pkgs, requireFile, makeWrapper,
libX11, libXext, libXcursor, libXrandr,
alsaLib, mesa_glu, libudev, unzip, mods, ...
}:
let
fetchfile = (import ../../lib/fetchfile.nix) { inherit stdenv pkgs; };
buildNumber = "1722";
in
stdenv.mkDerivation rec {
name = "rimworld-${version}";
version = "alpha-18";
MODLIST = mods;
src = fetchfile {
path = ../../../nixrc-src-games/RimWorldBeta18Linux.zip;
storeHash = "gxff7zx0dwfr2gbj8y3wqn1by8a22dmz";
};
phases = "unpackPhase installPhase";
unpackCmd = "${unzip}/bin/unzip -qq $src || true";
libPath = stdenv.lib.makeLibraryPath [
alsaLib
mesa_glu
libX11
libXext
libXcursor
libXrandr
libudev
stdenv.cc.cc.lib
];
buildInputs = [
makeWrapper
];
installPhase = ''
mkdir -p $out
mv * $out/
chmod +x $out/start_RimWorld.sh
chmod +x $out/start_RimWorld_openglfix.sh
chmod +x $out/RimWorld${buildNumber}Linux.x86_64
chmod +x $out/RimWorld${buildNumber}Linux.x86
for modPath in $MODLIST
do
echo "Installing mod from $modPath..."
${unzip}/bin/unzip "$modPath" -d "$out/Mods/"
done
patchelf \
--set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) \
$out/RimWorld${buildNumber}Linux.x86_64
#wrapProgram $out/RimWorld${buildNumber}Linux.x86_64 \
# --prefix LD_LIBRARY_PATH : /run/opengl-driver/lib:$libPath
mkdir -p $out/bin
makeWrapper $out/RimWorld${buildNumber}Linux.x86_64 $out/bin/rimworld \
--add-flags -logfile \
--add-flags /tmp/rimworld_log \
--prefix LD_LIBRARY_PATH : /run/opengl-driver/lib:$libPath
patchShebangs $out/start_RimWorld.sh
patchShebangs $out/start_RimWorld_openglfix.sh
'';
}

@ -1,15 +1,22 @@
{ stdenv, requireFile, SDL2, makeWrapper,
mesa_glu,
unzip, ... }:
{ stdenv, pkgs, requireFile, SDL2, makeWrapper,
mesa_glu, libSM, libICE, libX11, libXext,
unzip, strace, mods ? [], ... }:
let
originalArchive = "gog_starbound_2.13.0.14.sh";
fetchfile = (import ../../lib/fetchfile.nix) { inherit stdenv pkgs; };
listToBashArray = import ../../lib/list-to-bash-array.nix;
#modArray = listToBashArray { name = "modList"; args = builtins.trace mods mods; };
in
stdenv.mkDerivation rec {
name = "starbound-${version}";
version = "2.13.0.14";
MODLIST = mods;
src = ../../../nixrc-src-games/gog_starbound_2.13.0.14.sh;
src = fetchfile {
path = ../../../nixrc-src-games/gog_starbound_2.13.0.14.sh;
storeHash = "y9q03x9n467wh90wn228716kznx8mygx";
};
phases = "unpackPhase installPhase";
@ -21,6 +28,10 @@ in
mesa_glu
stdenv.cc.cc.lib
SDL2
libSM
libICE
libX11
libXext
];
buildInputs = [
@ -45,6 +56,13 @@ in
}
EOF
for modPath in $MODLIST
do
echo "$modPath"
${unzip}/bin/unzip "$modPath" -d "$out/mods/"
#cp -v "$modPath" "$out/mods/"
done
patchelf \
--set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) \
$out/linux/starbound
@ -53,7 +71,7 @@ in
patchelf --set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) $lib
done
makeWrapper strace $out/bin/starbound-strace \
makeWrapper ${strace}/bin/strace $out/bin/starbound-strace \
--add-flags -f \
--add-flags $out/linux/starbound \
--prefix LD_LIBRARY_PATH : /run/opengl-driver/lib:$libPath:$out/linux

@ -1,18 +1,22 @@
{ stdenv, requireFile, SDL2, makeWrapper, mono44,
{ stdenv, pkgs, requireFile, SDL2, makeWrapper, mono44,
libX11, libXext, libXcursor, libXxf86vm, libXi, libXinerama, libXrandr,
libgcrypt, libgpgerror,
alsaLib, libpulseaudio, libogg, libvorbis,
mesa_glu, libudev, lzma, dbus,
unzip, ... }:
unzip, strace, ... }:
let
originalArchive = "gog_stardew_valley_2.6.0.7.sh";
fetchfile = (import ../../lib/fetchfile.nix) { inherit stdenv pkgs; };
in
stdenv.mkDerivation rec {
name = "stardew-valley-${version}";
version = "2.6.0.7";
src = ../../../nixrc-src-games/gog_stardew_valley_2.6.0.7.sh;
src = fetchfile {
path = ../../../nixrc-src-games/gog_stardew_valley_2.6.0.7.sh;
storeHash = "llm002l2zsqfnw4rldkn1w5qnzz7xcfr";
};
phases = "unpackPhase installPhase";
@ -69,7 +73,7 @@ in
patchelf --set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) $lib
done
makeWrapper strace $out/stardew-valley-strace \
makeWrapper ${strace}/bin/strace $out/stardew-valley-strace \
--run 'cd "`dirname "$0"`"' \
--add-flags -f \
--add-flags $out/StardewValley.bin.x86_64 \

Loading…
Cancel
Save