Make wrapper for each symlink

idk why i have to do this but the name of the executable seems to be
directly encoded into the produced binary
This commit is contained in:
NullBite 2024-02-15 20:02:26 +01:00
parent b36ab9ecf5
commit 8d4fdc5556
Signed by: nullbite
GPG Key ID: 6C4D545385D4925A

View File

@ -24,11 +24,12 @@ stdenvNoCC.mkDerivation {
nativeBuildInputs = [ makeBinaryWrapper ];
src = ./.;
installPhase = ''
makeBinaryWrapper "${atool}/bin/atool" "$out/bin/atool" \
--inherit-argv0 --prefix PATH : "${wrappedPath}"
for i in acat adiff als apack arepack aunpack ; do
ln -s $out/bin/atool $out/bin/$i
# symlinking them doesn't work for some reason so i have to build multiple
for i in atool acat adiff als apack arepack aunpack ; do
makeBinaryWrapper "${atool}/bin/$i" "$out/bin/$i" \
--inherit-argv0 --prefix PATH : "${wrappedPath}"
done
# i have no idea if this is the "right" way to do this
mkdir -p "$out/share"
ln -s "${atool}/share/man" "$out/share/man"