summaryrefslogtreecommitdiff
path: root/config
diff options
context:
space:
mode:
authorAndoni Morales Alastruey <ylatuya@gmail.com>2013-02-22 11:58:53 +0100
committerAndoni Morales Alastruey <ylatuya@gmail.com>2013-02-22 22:23:20 +0100
commit7046dfe650935d158425985f5edc01ae337d90ab (patch)
tree0a905646242a6601e9fe66b398bdb913a262979b /config
parentcbc2fe937713d431a3a8c7b4a5c6811ebb5d19bc (diff)
ios.config: use tools from the iOS SDK
Diffstat (limited to 'config')
-rw-r--r--config/ios.config17
1 files changed, 12 insertions, 5 deletions
diff --git a/config/ios.config b/config/ios.config
index 9fe2b53..37ba4f9 100644
--- a/config/ios.config
+++ b/config/ios.config
@@ -33,20 +33,27 @@ if not os.path.exists(sysroot):
ccache = use_ccache and 'ccache ' or ''
extra_cflags=''
if target_arch == Architecture.ARMv7:
- str_arch = ' armv7'
+ arch_cflags = ' -arch armv7'
elif target_arch == Architecture.ARM:
- str_arch = ' armv6'
+ str_arch = ' -arch armv6'
elif target_arch == Architecture.X86:
- str_arch = ' i386 '
+ str_arch = ' -arch i386 '
extra_cflags='-D__IPHONE_OS_VERSION_MIN_REQUIRED=%s0000' %v1
else:
raise FatalError("Arch not supported")
# Toolchain environment
os.environ['CC']= os.path.join(iphone_platform, 'usr', 'bin', 'llvm-gcc-4.2')
-os.environ['CFLAGS'] = '-arch %s -isysroot %s -miphoneos-version-min=%s %s' %(str_arch, sysroot, min_version, extra_cflags)
-os.environ['LDFLAGS'] = '-arch %s -isysroot %s -Wl,-iphoneos_version_min,%s -Wl,-undefined,error -Wl,-headerpad_max_install_names' %(str_arch, sysroot, min_version)
os.environ['OBJC'] = os.environ['CC']
+os.environ['LD']= os.path.join(iphone_platform, 'usr', 'bin', 'ld')
+os.environ['AR']= os.path.join(iphone_platform, 'usr', 'bin', 'ar')
+os.environ['NM']= os.path.join(iphone_platform, 'usr', 'bin', 'nm')
+os.environ['NMEDIT']= os.path.join(iphone_platform, 'usr', 'bin', 'nmedit')
+os.environ['RANLIB']= os.path.join(iphone_platform, 'usr', 'bin', 'ranlib')
+os.environ['AS']= os.path.join(iphone_platform, 'usr', 'bin', 'as')
+os.environ['GAS']= '%s %s' % ('gas-preprocessor.pl', os.environ['CC'])
+os.environ['CFLAGS'] = '%s -isysroot %s -miphoneos-version-min=%s %s' %(arch_cflags, sysroot, min_version, extra_cflags)
+os.environ['LDFLAGS'] = '%s -isysroot %s -Wl,-iphoneos_version_min,%s -Wl,-undefined,error -Wl,-headerpad_max_install_names' %(arch_cflags, sysroot, min_version)
os.environ['CXX']= os.path.join(iphone_platform, 'usr', 'bin', 'llvm-g++-4.2')
os.environ['CPP']= os.path.join(iphone_platform, 'usr', 'bin', 'llvm-cpp-4.2')