NixOS / nixpkgs

Nix Packages collection & NixOS
MIT License
18.16k stars 14.19k forks source link

Build failure: ghostscript-10.04.0 #355377

Open anned20 opened 3 days ago

anned20 commented 3 days ago

Steps To Reproduce

Steps to reproduce the behavior:

  1. build ghostscript-10.04.0

Build log

rewriting symlink /nix/store/58s4hjjydcvld4zcqha58ziwjybkfyvw-ghostscript-10.04.0-man/share/man/man1/gsbj.1.gz to be relative to /nix/store/58s4hjjydcvld4zcqha58ziwjybkfyvw-ghostscript-10.04.0-man
rewriting symlink /nix/store/58s4hjjydcvld4zcqha58ziwjybkfyvw-ghostscript-10.04.0-man/share/man/man1/gsdj.1.gz to be relative to /nix/store/58s4hjjydcvld4zcqha58ziwjybkfyvw-ghostscript-10.04.0-man
rewriting symlink /nix/store/58s4hjjydcvld4zcqha58ziwjybkfyvw-ghostscript-10.04.0-man/share/man/man1/eps2eps.1.gz to be relative to /nix/store/58s4hjjydcvld4zcqha58ziwjybkfyvw-ghostscript-10.04.0-man
rewriting symlink /nix/store/58s4hjjydcvld4zcqha58ziwjybkfyvw-ghostscript-10.04.0-man/share/man/man1/gsdj500.1.gz to be relative to /nix/store/58s4hjjydcvld4zcqha58ziwjybkfyvw-ghostscript-10.04.0-man
rewriting symlink /nix/store/58s4hjjydcvld4zcqha58ziwjybkfyvw-ghostscript-10.04.0-man/share/man/man1/gslj.1.gz to be relative to /nix/store/58s4hjjydcvld4zcqha58ziwjybkfyvw-ghostscript-10.04.0-man
rewriting symlink /nix/store/58s4hjjydcvld4zcqha58ziwjybkfyvw-ghostscript-10.04.0-man/share/man/man1/ps2pdf14.1.gz to be relative to /nix/store/58s4hjjydcvld4zcqha58ziwjybkfyvw-ghostscript-10.04.0-man
rewriting symlink /nix/store/58s4hjjydcvld4zcqha58ziwjybkfyvw-ghostscript-10.04.0-man/share/man/man1/ps2pdf13.1.gz to be relative to /nix/store/58s4hjjydcvld4zcqha58ziwjybkfyvw-ghostscript-10.04.0-man
rewriting symlink /nix/store/58s4hjjydcvld4zcqha58ziwjybkfyvw-ghostscript-10.04.0-man/share/man/man1/ps2pdf12.1.gz to be relative to /nix/store/58s4hjjydcvld4zcqha58ziwjybkfyvw-ghostscript-10.04.0-man
@nix { "action": "setPhase", "phase": "installCheckPhase" }
Running phase: installCheckPhase
dyld[68823]: Library not loaded: libgs.10.dylib
  Referenced from: <497CFDBA-A6D1-332C-B983-C3CFF6293055> /nix/store/ag7vqbvj1pk7lqczyc3h9ynwv3y199z8-ghostscript-10.04.0/bin/gs
  Reason: tried: 'libgs.10.dylib' (no such file), '/System/Volumes/Preboot/Cryptexes/OSlibgs.10.dylib' (no such file), 'libgs.10.dylib' (no such file), '/usr/local/lib/libgs.10.dylib' (no such file), '/usr/lib/libgs.10.dylib' (no such file, not in dyld cache), '/private/tmp/nix-build-ghostscript-10.04.0.drv-0/ghostscript-10.04.0/libgs.10.dylib' (no such file), '/System/Volumes/Preboot/Cryptexes/OS/private/tmp/nix-build-ghostscript-10.04.0.drv-0/ghostscript-10.04.0/libgs.10.dylib' (>
/nix/store/vrjr8rg1gsvvncgdl7qybh5h7vgqdxvn-stdenv-darwin/setup: line 1596: 68823 Abort trap: 6           $out/bin/gs --version

Notify maintainers

@tobim

Metadata


Add a :+1: reaction to issues you find important.

carlocab commented 2 days ago

The way MacPorts handles this might help: https://github.com/macports/macports-ports/blob/d8a05520fa6a81fa5b0365068590aff184976b69/print/ghostscript/Portfile#L114

So adding

DARWIN_LDFLAGS_SO_PREFIX=$out/lib/

to the build environment should fix it.

tobim commented 2 days ago

Hey, thanks for reporting this. I'll try to find some time to take a look in a couple of hours.

dereulenspiegel commented 1 day ago

Hello :)

Just wanted to mention that this also happens on x86_64-darwin.

tobim commented 23 hours ago

The linked PR should fix that too.