diff --git a/pkgs/development/tools/build-managers/cmake/2.8.nix b/pkgs/development/tools/build-managers/cmake/2.8.nix index 590de68d52f..fb38e52811c 100644 --- a/pkgs/development/tools/build-managers/cmake/2.8.nix +++ b/pkgs/development/tools/build-managers/cmake/2.8.nix @@ -1,5 +1,6 @@ { stdenv, fetchurl, fetchpatch, replace, curl, expat, zlib, bzip2 , useNcurses ? false, ncurses, useQt4 ? false, qt4, wantPS ? false, ps ? null +, buildPlatform, hostPlatform }: with stdenv.lib; @@ -35,7 +36,7 @@ stdenv.mkDerivation rec { })] ++ # Don't search in non-Nix locations such as /usr, but do search in our libc. [ ./search-path.patch ] ++ - optional (stdenv ? cross) (fetchurl { + optional (hostPlatform != buildPlatform) (fetchurl { name = "fix-darwin-cross-compile.patch"; url = "http://public.kitware.com/Bug/file_download.php?" + "file_id=4981&type=bug";