-
Notifications
You must be signed in to change notification settings - Fork 49
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added Darkest Dungeon (GoG) derivation #118
base: master
Are you sure you want to change the base?
Conversation
This is a first draft. The game works perfectly but some things might still be missing (ex. gamemode support) but those should be trivial to implement later on. I hope.
According to the docs it gets automatically executed after execution.
Reduces redundancy and makes the unpackPhase extract, more or less, only what is needed.
The
I mostly ignore the feasibility of the last two. I'll start working on those a soon as possible. |
Gamemode support can be achieved the same as here. dlcs ? {},
mods ? {},
# ...
}: let
unpackDlc = name: zip: ''
mkdir -p $out/dlcs/${name}
cd $out/dlcs/${name}
unzip ${zip}
# return to base dir
'';
in {
# ...
buildPhase = ''
# ...
concatStringsSep "\n" mapAttrs unpackDlc dlcs;
# same for mods
''; |
Regarding Here is my current best attempt: installPhase = let
script = writeShellScriptBin pname ''
export LD_LIBRARY_PATH=${lib.makeLibraryPath commonDeps}
${lib.optionalString gamemodeIntegration "${gamemode}/bin/gamemoderun"} $out/share/${pname}/darkest.bin.x86_64
'';
in ''
mkdir -p $out/share/${pname}
mkdir -p $out/share/icons/hicolor
mkdir -p $out/bin
# Only copies this folder since the rest is useless.
mv data/noarch/game/* $out/share/${pname}
# Installs the icon.
mv data/noarch/support/icon.png $out/share/icons/hicolor/${pname}.png
cp ${script}/bin/${pname} $out/bin/darkest
''; |
Looks good, what doesn't work? Does the resulting script have the gamemode invocation as expected? |
The wrapper errors out trying to execute the original binary because it's not found. The exact error message: $ nix run .\#darkest-dungeon
env: ‘/share/darkest-dungeon/darkest.bin.x86_64’: No such file or directory I don't know why does it treat |
Oh, I know what's going on. The |
Hi and sorry for not answering for a long time. I did wrote a response but apparently GitHub decided to not send it... I've been pretty busy lately with school stuff but here I am. I got stuck with both the I'm trying to add DLCs right now. |
It would be better to do rebases instead of merges, as merges make the history non-linear. |
Adds a Darkest Dungeon derivation. (Link to the game website).
This is related to the issue #110. While this is just a single game and not a builder I think it still has value because:
WIP