darwin x11/opengl: only copy subset of files (close #1165)

Copy only the pc files related to X11 and OpenGL.

This should allow us to build our own version of libraries like
cairo without having the native ones be accidentally dynamically
linked in to things that depend on them.

Before this patch if we `dyldinfo -dylibs libpangocairo` we can
see that it was dynamically linked against the OS X (but seemingly
built against include files from the nix one, as we would get a
runtime complaint about missing symbols)
This commit is contained in:
Eric Kow 2013-11-03 16:35:56 +00:00 committed by Vladimír Čunát
parent 0eeee298ef
commit 1be6aae4b4

View file

@ -7,6 +7,10 @@ stdenv.mkDerivation rec {
builder = writeScript "${name}-builder.sh" ''
/bin/mkdir -p $out
/bin/ln -sv /usr/X11/{bin,lib,include,share} $out/
/bin/mkdir $out/lib
/bin/ln -sv /usr/X11/lib/{*.dylib,X11,xorg} $out/lib
/bin/mkdir $out/lib/pkgconfig
/bin/ln -sv /usr/X11/lib/pkgconfig/{x*.pc,gl*.pc} $out/lib/pkgconfig
/bin/ln -sv /usr/X11/{bin,include,share} $out/
'';
}