fix where it does not generate 64bit type into brigesupport in 3rd-party library on MacOSX platform

http://hipbyte.myjetbrains.com/youtrack/issue/RM-192
This commit is contained in:
Watson
2013-07-10 11:02:33 +09:00
parent b66b7c2af8
commit a8a76ad537
3 changed files with 12 additions and 5 deletions

View File

@@ -292,13 +292,20 @@ EOS
end
end
def gen_bridge_metadata(headers, bs_file, c_flags, exceptions=[])
def gen_bridge_metadata(platform, headers, bs_file, c_flags, exceptions=[])
sdk_path = self.sdk(local_platform)
includes = headers.map { |header| "-I'#{File.dirname(header)}'" }.uniq
exceptions = exceptions.map { |x| "\"#{x}\"" }.join(' ')
a = sdk_version.scan(/(\d+)\.(\d+)/)[0]
sdk_version_headers = ((a[0].to_i * 10000) + (a[1].to_i * 100)).to_s
extra_flags = OSX_VERSION >= 10.7 ? '--no-64-bit' : ''
extra_flags = begin
case platform
when "MacOSX"
'--64-bit'
else
OSX_VERSION >= 10.7 ? '--no-64-bit' : ''
end
end
sh "RUBYOPT='' /usr/bin/gen_bridge_metadata --format complete #{extra_flags} --cflags \" #{c_flags} -isysroot #{sdk_path} -miphoneos-version-min=#{sdk_version} -D__ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__=#{sdk_version_headers} -I. #{includes.join(' ')}\" #{headers.map { |x| "\"#{x}\"" }.join(' ')} -o \"#{bs_file}\" #{ "-e #{exceptions}" if exceptions.length != 0}"
end