Made OpenGL a propagated dependency for mesa on darwin (fixes a host of building errors, especially in haskell pacakges). Also fixed freeglut on darwin.

Signed-off-by: Pamelloes <pamelloes@gmail.com>

Pamelloes 8d278b47 d9739ebc

+10
+8
pkgs/development/libraries/freeglut/default.nix
··· 11 12 buildInputs = [ libXi libXrandr libXxf86vm mesa xlibsWrapper cmake ]; 13 14 meta = with stdenv.lib; { 15 description = "Create and manage windows containing OpenGL contexts"; 16 longDescription = ''
··· 11 12 buildInputs = [ libXi libXrandr libXxf86vm mesa xlibsWrapper cmake ]; 13 14 + cmakeFlags = stdenv.lib.optionals stdenv.isDarwin [ 15 + "-DOPENGL_INCLUDE_DIR=${mesa}/include" 16 + "-DOPENGL_gl_LIBRARY:FILEPATH=${mesa}/lib/libGL.dylib" 17 + "-DOPENGL_glu_LIBRARY:FILEPATH=${mesa}/lib/libGLU.dylib" 18 + "-DFREEGLUT_BUILD_DEMOS:BOOL=OFF" 19 + "-DFREEGLUT_BUILD_STATIC:BOOL=OFF" 20 + ]; 21 + 22 meta = with stdenv.lib; { 23 description = "Create and manage windows containing OpenGL contexts"; 24 longDescription = ''
+2
pkgs/development/libraries/mesa-darwin/default.nix
··· 25 libffi libvdpau 26 ] ++ stdenv.lib.optionals stdenv.isDarwin [ OpenGL apple_sdk.sdk Xplugin ]; 27 28 postUnpack = '' 29 ln -s darwin $sourceRoot/configs/current 30 '';
··· 25 libffi libvdpau 26 ] ++ stdenv.lib.optionals stdenv.isDarwin [ OpenGL apple_sdk.sdk Xplugin ]; 27 28 + propagatedBuildInputs = stdenv.lib.optionals stdenv.isDarwin [ OpenGL ]; 29 + 30 postUnpack = '' 31 ln -s darwin $sourceRoot/configs/current 32 '';