From c90247aa44272b60df247c6c83512e2a6bd23395 Mon Sep 17 00:00:00 2001 From: Jack Nagel Date: Wed, 28 May 2014 09:20:44 -0500 Subject: [PATCH] Place X11 ahead of OpenGL when X11 is active Fixes Homebrew/homebrew#29651. --- Library/Homebrew/extend/ENV/super.rb | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Library/Homebrew/extend/ENV/super.rb b/Library/Homebrew/extend/ENV/super.rb index c68e6eb866..e1288f5cb0 100644 --- a/Library/Homebrew/extend/ENV/super.rb +++ b/Library/Homebrew/extend/ENV/super.rb @@ -167,8 +167,8 @@ module Superenv paths << "#{HOMEBREW_PREFIX}/include" paths << "#{effective_sysroot}/usr/include/libxml2" unless deps.include? "libxml2" paths << "#{effective_sysroot}/usr/include/apache2" if MacOS::Xcode.without_clt? - paths << "#{effective_sysroot}/System/Library/Frameworks/OpenGL.framework/Versions/Current/Headers" paths << MacOS::X11.include.to_s << "#{MacOS::X11.include}/freetype2" if x11? + paths << "#{effective_sysroot}/System/Library/Frameworks/OpenGL.framework/Versions/Current/Headers" paths.to_path_s end @@ -179,8 +179,8 @@ module Superenv def determine_library_paths paths = keg_only_deps.map { |dep| "#{HOMEBREW_PREFIX}/opt/#{dep}/lib" } paths << "#{HOMEBREW_PREFIX}/lib" - paths << "#{effective_sysroot}/System/Library/Frameworks/OpenGL.framework/Versions/Current/Libraries" paths << MacOS::X11.lib.to_s if x11? + paths << "#{effective_sysroot}/System/Library/Frameworks/OpenGL.framework/Versions/Current/Libraries" paths.to_path_s end @@ -194,15 +194,15 @@ module Superenv paths = [] paths << "#{effective_sysroot}/usr/include/libxml2" unless deps.include? "libxml2" paths << "#{effective_sysroot}/usr/include/apache2" if MacOS::Xcode.without_clt? - paths << "#{effective_sysroot}/System/Library/Frameworks/OpenGL.framework/Versions/Current/Headers" paths << MacOS::X11.include.to_s << "#{MacOS::X11.include}/freetype2" if x11? + paths << "#{effective_sysroot}/System/Library/Frameworks/OpenGL.framework/Versions/Current/Headers" paths.to_path_s end def determine_cmake_library_path paths = [] - paths << "#{effective_sysroot}/System/Library/Frameworks/OpenGL.framework/Versions/Current/Libraries" paths << MacOS::X11.lib.to_s if x11? + paths << "#{effective_sysroot}/System/Library/Frameworks/OpenGL.framework/Versions/Current/Libraries" paths.to_path_s end