diff options
-rw-r--r-- | cross/iphone.txt | 16 | ||||
-rw-r--r-- | test cases/osx/4 framework/meson.build | 27 |
2 files changed, 27 insertions, 16 deletions
diff --git a/cross/iphone.txt b/cross/iphone.txt index 9659407..c02e6a3 100644 --- a/cross/iphone.txt +++ b/cross/iphone.txt @@ -5,14 +5,18 @@ [binaries] c = 'clang' cpp = 'clang++' +objc = 'clang' +objcpp = 'clang++' ar = 'ar' strip = 'strip' [built-in options] -c_args = ['-arch', 'armv7', '-miphoneos-version-min=8.0', '-isysroot', '/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS8.4.sdk'] -cpp_args = ['-arch', 'armv7', '-miphoneos-version-min=8.0', '-isysroot', '/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS8.4.sdk'] -c_link_args = ['-arch', 'armv7', '-miphoneos-version-min=8.0', '-isysroot', '/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS8.4.sdk'] -cpp_link_args = ['-arch', 'armv7', '-miphoneos-version-min=8.0', '-isysroot', '/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS8.4.sdk'] +c_args = ['-arch', 'arm64', '-miphoneos-version-min=11.0', '-isysroot', '/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk'] +cpp_args = ['-arch', 'arm64', '-miphoneos-version-min=11.0', '-isysroot', '/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk'] +c_link_args = ['-arch', 'arm64', '-miphoneos-version-min=11.0', '-isysroot', '/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk'] +cpp_link_args = ['-arch', 'arm64', '-miphoneos-version-min=11.0', '-isysroot', '/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk'] +objc_args = ['-arch', 'arm64', '-miphoneos-version-min=11.0', '-isysroot', '/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk'] +objcpp_args = ['-arch', 'arm64', '-miphoneos-version-min=11.0', '-isysroot', '/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk'] [properties] root = '/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer' @@ -21,7 +25,7 @@ has_function_hfkerhisadf = false [host_machine] system = 'darwin' -cpu_family = 'arm' -cpu = 'armv7' +cpu_family = 'aarch64' +cpu = 'aarch64' endian = 'little' diff --git a/test cases/osx/4 framework/meson.build b/test cases/osx/4 framework/meson.build index 460b480..859d34e 100644 --- a/test cases/osx/4 framework/meson.build +++ b/test cases/osx/4 framework/meson.build @@ -8,16 +8,23 @@ # - "stat@sta" should be only "OpenGL.framework" # see "xcode-frameworks.png" for an example -project('xcode framework test', 'c', default_options : ['libdir=libtest']) - -dep_libs = dependency('appleframeworks', modules : ['OpenGL'], required : false) -if not dep_libs.found() - error('OpenGL framework not found') -endif -assert(dep_libs.type_name() == 'appleframeworks', 'type_name is wrong') +project('xcode framework test', 'objc', default_options : ['libdir=libtest']) dep_main = dependency('appleframeworks', modules : ['Foundation']) -stlib = static_library('stat', 'stat.c', install : true, dependencies: dep_libs) -exe = executable('prog', 'prog.c', install : true, dependencies: dep_main) - +if meson.is_cross_build() + # This is only available in iOS, not macOS. Just test finding it. + uikit_dep = dependency('appleframeworks', modules: 'UIKit') +else + dep_libs = dependency('appleframeworks', modules : ['OpenGL'], required : false) + if not dep_libs.found() + error('OpenGL framework not found') + endif + assert(dep_libs.type_name() == 'appleframeworks', 'type_name is wrong') + stlib = static_library('stat', 'stat.c', install : true, dependencies: dep_libs) + exe = executable('prog', 'prog.c', install : true, dependencies: dep_main) + uikit_dep = dependency('appleframeworks', modules: 'UIKit', required: false) + if uikit_dep.found() + error('UIKit found on macOS even though it should not be there.') + endif +endif |