Organize compiler methods
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
This commit is contained in:
parent
0bb95960e6
commit
f2e076e5cc
@ -175,21 +175,6 @@ module MacOS extend self
|
||||
end
|
||||
end
|
||||
|
||||
def gcc_42_build_version
|
||||
@gcc_42_build_version ||= if File.exist? "#{dev_tools_path}/gcc-4.2" \
|
||||
and not Pathname.new("#{dev_tools_path}/gcc-4.2").realpath.basename.to_s =~ /^llvm/
|
||||
`#{dev_tools_path}/gcc-4.2 --version` =~ /build (\d{4,})/
|
||||
$1.to_i
|
||||
end
|
||||
end
|
||||
|
||||
def gcc_40_build_version
|
||||
@gcc_40_build_version ||= if File.exist? "#{dev_tools_path}/gcc-4.0"
|
||||
`#{dev_tools_path}/gcc-4.0 --version` =~ /build (\d{4,})/
|
||||
$1.to_i
|
||||
end
|
||||
end
|
||||
|
||||
def xcode_prefix
|
||||
@xcode_prefix ||= begin
|
||||
path = Pathname.new xcode_folder
|
||||
@ -305,6 +290,21 @@ module MacOS extend self
|
||||
end
|
||||
end
|
||||
|
||||
def gcc_40_build_version
|
||||
@gcc_40_build_version ||= if locate("gcc-4.0")
|
||||
`#{locate("gcc-4.0")} --version` =~ /build (\d{4,})/
|
||||
$1.to_i
|
||||
end
|
||||
end
|
||||
|
||||
def gcc_42_build_version
|
||||
@gcc_42_build_version ||= if locate("gcc-4.2") \
|
||||
and not locate("gcc-4.2").realpath.basename.to_s =~ /^llvm/
|
||||
`#{locate("gcc-4.2")} --version` =~ /build (\d{4,})/
|
||||
$1.to_i
|
||||
end
|
||||
end
|
||||
|
||||
def llvm_build_version
|
||||
# for Xcode 3 on OS X 10.5 this will not exist
|
||||
# NOTE may not be true anymore but we can't test
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user