Skip to content
Browse files

Only add -F if the frameworks folder exists

Closes #16901.
  • Loading branch information...
1 parent ef766b1 commit 744bac12900410823a235dc53136acd88da856fb @adamv adamv committed with klausmeyer
Showing with 5 additions and 3 deletions.
  1. +5 −3 Library/Homebrew/extend/ENV.rb
View
8 Library/Homebrew/extend/ENV.rb
@@ -33,9 +33,11 @@ def setup_build_environment
self['CMAKE_PREFIX_PATH'] = "#{HOMEBREW_PREFIX}"
end
- append 'CPPFLAGS', "-F#{HOMEBREW_PREFIX}/Frameworks"
- append 'LDFLAGS', "-F#{HOMEBREW_PREFIX}/Frameworks"
- self['CMAKE_FRAMEWORK_PATH'] = HOMEBREW_PREFIX/"Frameworks"
+ if (HOMEBREW_PREFIX/'Frameworks').exist?
+ append 'CPPFLAGS', "-F#{HOMEBREW_PREFIX}/Frameworks"
+ append 'LDFLAGS', "-F#{HOMEBREW_PREFIX}/Frameworks"
+ self['CMAKE_FRAMEWORK_PATH'] = HOMEBREW_PREFIX/"Frameworks"
+ end
# Os is the default Apple uses for all its stuff so let's trust them
set_cflags "-Os #{SAFE_CFLAGS_FLAGS}"

0 comments on commit 744bac1

Please sign in to comment.
Something went wrong with that request. Please try again.