diff options
Diffstat (limited to 'Library/ENV')
| -rwxr-xr-x | Library/ENV/4.3/cc | 27 |
1 files changed, 13 insertions, 14 deletions
diff --git a/Library/ENV/4.3/cc b/Library/ENV/4.3/cc index 7a40d2e38..b29acb64d 100755 --- a/Library/ENV/4.3/cc +++ b/Library/ENV/4.3/cc @@ -24,20 +24,6 @@ end LOGGER = Logger.new -def cccfg? flags - flags.split('').all?{|c| ENV['HOMEBREW_CCCFG'].include? c } if ENV['HOMEBREW_CCCFG'] -end -def nclt? - $sdkroot != nil -end -def syspath - if nclt? - %W{#$sdkroot/usr #$sdkroot/usr/local} - else - %W{/usr /usr/local} - end -end - class Cmd def initialize path, args @arg0 = File.basename(path).freeze @@ -192,6 +178,13 @@ class Cmd args.concat ENV['HOMEBREW_ARCHFLAGS'].split(' ') if cccfg? 'u' args end + def syspath + if nclt? + %W{#$sdkroot/usr #$sdkroot/usr/local} + else + %W{/usr /usr/local} + end + end def syslibpath # We reject brew's lib as we explicitly add this as a -L flag, thus it # is given higher priority by cc, so it surpasses the system libpath. @@ -249,6 +242,12 @@ class Cmd # configure scripts generated with autoconf 2.61 or later export as_nl ENV.key? 'as_nl' end + def nclt? + $sdkroot != nil + end + def cccfg? flags + flags.split('').all?{|c| ENV['HOMEBREW_CCCFG'].include? c } if ENV['HOMEBREW_CCCFG'] + end end if __FILE__ == $PROGRAM_NAME |
