mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-16 14:54:29 +01:00
Merge pull request #104593 from siriobalmelli-foss/fix/ghostscript
ghostscript: fix broken rpath on Darwin
This commit is contained in:
commit
a97cb19b38
1 changed files with 13 additions and 1 deletions
|
@ -103,8 +103,20 @@ stdenv.mkDerivation rec {
|
|||
done
|
||||
'';
|
||||
|
||||
# dynamic library name only contains maj.min, eg. '9.53'
|
||||
dylib_version = lib.versions.majorMinor version;
|
||||
preFixup = lib.optionalString stdenv.isDarwin ''
|
||||
install_name_tool -change libgs.dylib.${version} $out/lib/libgs.dylib.${version} $out/bin/gs
|
||||
install_name_tool -change libgs.dylib.$dylib_version $out/lib/libgs.dylib.$dylib_version $out/bin/gs
|
||||
'';
|
||||
|
||||
# validate dynamic linkage
|
||||
doInstallCheck = true;
|
||||
installCheckPhase = ''
|
||||
runHook preInstallCheck
|
||||
|
||||
$out/bin/gs --version
|
||||
|
||||
runHook postInstallCheck
|
||||
'';
|
||||
|
||||
meta = {
|
||||
|
|
Loading…
Reference in a new issue