darwin/libiconv: fix static/shared logic

The conditional was incorrect - postInstall script should only hsppen
when enableShared = true.

(cherry picked from commit 5e06294276)
This commit is contained in:
Matthew Bauer 2018-12-04 21:13:24 -06:00 committed by John Ericson
parent 7fcbc52d7d
commit f11d5341aa

View File

@ -15,7 +15,7 @@ appleDerivation {
(lib.enableFeature enableShared "shared") (lib.enableFeature enableShared "shared")
]; ];
postInstall = lib.optionalString (!enableStatic) '' postInstall = lib.optionalString enableShared ''
mv $out/lib/libiconv.dylib $out/lib/libiconv-nocharset.dylib mv $out/lib/libiconv.dylib $out/lib/libiconv-nocharset.dylib
${stdenv.cc.bintools.targetPrefix}install_name_tool -id $out/lib/libiconv-nocharset.dylib $out/lib/libiconv-nocharset.dylib ${stdenv.cc.bintools.targetPrefix}install_name_tool -id $out/lib/libiconv-nocharset.dylib $out/lib/libiconv-nocharset.dylib