Merge pull request #33382 from LnL7/darwin-cmake-outputs

cmake: fix hook for multiple outputs on darwin
This commit is contained in:
Daiderd Jordan 2018-01-07 09:46:58 +01:00 committed by GitHub
commit 84f9736014
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 1 additions and 5 deletions

View File

@ -43,7 +43,7 @@ cmakeConfigurePhase() {
# libraries are in a system path or in the same directory as the # libraries are in a system path or in the same directory as the
# executable. This flag makes the shared library accessible from its # executable. This flag makes the shared library accessible from its
# nix/store directory. # nix/store directory.
cmakeFlags="-DCMAKE_INSTALL_NAME_DIR=$prefix/lib $cmakeFlags" cmakeFlags="-DCMAKE_INSTALL_NAME_DIR=${!outputLib}/lib $cmakeFlags"
cmakeFlags="-DCMAKE_INSTALL_LIBDIR=${!outputLib}/lib $cmakeFlags" cmakeFlags="-DCMAKE_INSTALL_LIBDIR=${!outputLib}/lib $cmakeFlags"
cmakeFlags="-DCMAKE_INSTALL_INCLUDEDIR=${!outputDev}/include $cmakeFlags" cmakeFlags="-DCMAKE_INSTALL_INCLUDEDIR=${!outputDev}/include $cmakeFlags"

View File

@ -21,10 +21,6 @@ stdenv.mkDerivation rec {
# and the wonderful bazel BUILD file is already there (yay case-insensitivity?) # and the wonderful bazel BUILD file is already there (yay case-insensitivity?)
prePatch = "rm BUILD"; prePatch = "rm BUILD";
preConfigure = stdenv.lib.optionalString stdenv.isDarwin ''
cmakeFlagsArray+=("-DCMAKE_INSTALL_NAME_DIR=$lib/lib")
'';
meta = with stdenv.lib; { meta = with stdenv.lib; {
inherit (src.meta) homepage; inherit (src.meta) homepage;