diff options
author | Red Davies <red@infect.me> | 2019-11-05 20:28:30 -0500 |
---|---|---|
committer | Red Davies <red@infect.me> | 2019-11-05 20:28:30 -0500 |
commit | c8bfae0819a1343bd435d7a6e22671594ecb5e5d (patch) | |
tree | fdb094c17374e15afd8abf9708c76d444a742672 /pkgs/development/libraries/icu | |
parent | e73c93d8e63af332f42b6ed820382dfdec6d2745 (diff) |
icu: bugfix #71142 - Fixes icu-config reporting bad location
Diffstat (limited to 'pkgs/development/libraries/icu')
-rw-r--r-- | pkgs/development/libraries/icu/base.nix | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/pkgs/development/libraries/icu/base.nix b/pkgs/development/libraries/icu/base.nix index 0a8cb7d468433..47ca63fca9902 100644 --- a/pkgs/development/libraries/icu/base.nix +++ b/pkgs/development/libraries/icu/base.nix @@ -63,10 +63,16 @@ let # remove dependency on bootstrap-tools in early stdenv build postInstall = stdenv.lib.optionalString stdenv.isDarwin '' sed -i 's/INSTALL_CMD=.*install/INSTALL_CMD=install/' $out/lib/icu/${version}/pkgdata.inc - '' + '' + '' + (let + replacements = [ + { from = "\${prefix}/include"; to = "${placeholder "dev"}/include"; } # --cppflags-searchpath + { from = "\${pkglibdir}/Makefile.inc"; to = "${placeholder "dev"}/lib/icu/Makefile.inc"; } # --incfile + { from = "\${pkglibdir}/pkgdata.inc"; to = "${placeholder "dev"}/lib/icu/pkgdata.inc"; } # --incpkgdatafile + ]; + in '' substituteInPlace "$dev/bin/icu-config" \ - --replace \''${pkglibdir}/Makefile.inc "$dev/lib/icu/Makefile.inc" - ''; + ${lib.concatMapStringsSep " " (r: "--replace '${r.from}' '${r.to}'") replacements} + ''); postFixup = ''moveToOutput lib/icu "$dev" ''; }; |