diff options
author | Angelos Mouzakitis <a.mouzakitis@virtualopensystems.com> | 2023-10-10 14:33:42 +0000 |
---|---|---|
committer | Angelos Mouzakitis <a.mouzakitis@virtualopensystems.com> | 2023-10-10 14:33:42 +0000 |
commit | af1a266670d040d2f4083ff309d732d648afba2a (patch) | |
tree | 2fc46203448ddcc6f81546d379abfaeb323575e9 /meson/cross | |
parent | e02cda008591317b1625707ff8e115a4841aa889 (diff) |
Change-Id: Iaf8d18082d3991dec7c0ebbea540f092188eb4ec
Diffstat (limited to 'meson/cross')
-rw-r--r-- | meson/cross/arm64cl.txt | 17 | ||||
-rw-r--r-- | meson/cross/armcc.txt | 20 | ||||
-rw-r--r-- | meson/cross/armclang-linux.txt | 34 | ||||
-rw-r--r-- | meson/cross/armclang.txt | 20 | ||||
-rw-r--r-- | meson/cross/c2000.txt | 28 | ||||
-rw-r--r-- | meson/cross/ccomp-armv7a.txt | 13 | ||||
-rw-r--r-- | meson/cross/ccrx.txt | 22 | ||||
-rw-r--r-- | meson/cross/iphone.txt | 27 | ||||
-rw-r--r-- | meson/cross/linux-mingw-w64-32bit.json | 7 | ||||
-rw-r--r-- | meson/cross/linux-mingw-w64-32bit.txt | 31 | ||||
-rw-r--r-- | meson/cross/linux-mingw-w64-64bit.json | 7 | ||||
-rw-r--r-- | meson/cross/linux-mingw-w64-64bit.txt | 30 | ||||
-rw-r--r-- | meson/cross/none.txt | 18 | ||||
-rw-r--r-- | meson/cross/ownstdlib.txt | 13 | ||||
-rw-r--r-- | meson/cross/tvos.txt | 28 | ||||
-rw-r--r-- | meson/cross/ubuntu-armhf.json | 5 | ||||
-rw-r--r-- | meson/cross/ubuntu-armhf.txt | 29 | ||||
-rw-r--r-- | meson/cross/ubuntu-faketarget.txt | 13 | ||||
-rw-r--r-- | meson/cross/wasm.txt | 18 | ||||
-rw-r--r-- | meson/cross/xc16.txt | 26 |
20 files changed, 406 insertions, 0 deletions
diff --git a/meson/cross/arm64cl.txt b/meson/cross/arm64cl.txt new file mode 100644 index 000000000..f22fca8a8 --- /dev/null +++ b/meson/cross/arm64cl.txt @@ -0,0 +1,17 @@ +[binaries] +c = 'cl' +cpp = 'cl' +ar = 'lib' +windres = 'rc' + +[built-in options] +c_args = ['-DWINAPI_FAMILY=WINAPI_FAMILY_APP'] +c_link_args = ['-APPCONTAINER', 'WindowsApp.lib'] +cpp_args = ['-DWINAPI_FAMILY=WINAPI_FAMILY_APP'] +cpp_link_args = ['-APPCONTAINER', 'WindowsApp.lib'] + +[host_machine] +system = 'windows' +cpu_family = 'aarch64' +cpu = 'armv8' +endian = 'little' diff --git a/meson/cross/armcc.txt b/meson/cross/armcc.txt new file mode 100644 index 000000000..ae65c9e5e --- /dev/null +++ b/meson/cross/armcc.txt @@ -0,0 +1,20 @@ +# This file assumes that path to the arm compiler toolchain is added +# to the environment(PATH) variable, so that Meson can find +# the armcc, armlink and armar while building. +[binaries] +c = 'armcc' +cpp = 'armcc' +ar = 'armar' +strip = 'armar' + +[built-in options] +# The '--cpu' option with the appropriate target type should be mentioned +# to cross compile c/c++ code with armcc,. +c_args = ['--cpu=Cortex-M0plus'] +cpp_args = ['--cpu=Cortex-M0plus'] + +[host_machine] +system = 'bare metal' # Update with your system name - bare metal/OS. +cpu_family = 'arm' +cpu = 'Cortex-M0+' +endian = 'little' diff --git a/meson/cross/armclang-linux.txt b/meson/cross/armclang-linux.txt new file mode 100644 index 000000000..10f6fa44b --- /dev/null +++ b/meson/cross/armclang-linux.txt @@ -0,0 +1,34 @@ +# Using ARM compilers from Linux command line is tricky and +# not really well documented because they want you to use +# their IDE instead. +# +# First you need to do the full install with the IDE and set +# up license files et al. This may be possible from the command +# line. +# +# Then you need to do the following: +# +# Select toolchain by running /opt/arm/developmentstudio-2019.0/bin/select_default_toolchain +# Armcc is only available in toolchain version 5. +# Armclang is only available in toolchain version 6. +# Start shell with /opt/arm/developmentstudio-2019.0/bin/suite_exec zsh +# Now the compilers will work. + +[binaries] +# we could set exe_wrapper = qemu-arm-static but to test the case +# when cross compiled binaries can't be run we don't do that +c = '/opt/arm/developmentstudio-2019.0/sw/ARMCompiler6.12/bin/armclang' +#c = '/opt/arm/developmentstudio-2019.0/sw/ARMCompiler5.06u6/bin/armcc' +#cpp = '/usr/bin/arm-linux-gnueabihf-g++' +ar = '/opt/arm/developmentstudio-2019.0/sw/ARMCompiler6.12/bin/armar' +#strip = '/usr/arm-linux-gnueabihf/bin/strip' +#pkgconfig = '/usr/bin/arm-linux-gnueabihf-pkg-config' + +[built-in options] +c_args = ['--target=aarch64-arm-none-eabi'] + +[host_machine] +system = 'baremetal' +cpu_family = 'arm' +cpu = 'armv7' # Not sure if correct. +endian = 'little' diff --git a/meson/cross/armclang.txt b/meson/cross/armclang.txt new file mode 100644 index 000000000..6146e0d74 --- /dev/null +++ b/meson/cross/armclang.txt @@ -0,0 +1,20 @@ +# This file assumes that path to the arm compiler toolchain is added +# to the environment(PATH) variable, so that Meson can find +# the armclang, armlink and armar while building. +[binaries] +c = 'armclang' +cpp = 'armclang' +ar = 'armar' +strip = 'armar' + +[built-in options] +# The '--target', '-mcpu' options with the appropriate values should be mentioned +# to cross compile c/c++ code with armclang. +c_args = ['--target=arm-arm-none-eabi', '-mcpu=cortex-m0plus'] +cpp_args = ['--target=arm-arm-none-eabi', '-mcpu=cortex-m0plus'] + +[host_machine] +system = 'bare metal' # Update with your system name - bare metal/OS. +cpu_family = 'arm' +cpu = 'Cortex-M0+' +endian = 'little' diff --git a/meson/cross/c2000.txt b/meson/cross/c2000.txt new file mode 100644 index 000000000..61c03109d --- /dev/null +++ b/meson/cross/c2000.txt @@ -0,0 +1,28 @@ +# This file assumes that path to the Texas Instruments C20000 toolchain is added +# to the environment(PATH) variable, so that Meson can find +# cl2000 and ar2000 while building. +[binaries] +c = 'cl2000' +ar = 'ar2000' +strip = 'cl2000' + +[host_machine] +system = 'bare metal' +cpu_family = 'c2000' +cpu = 'c28x' +endian = 'little' + +[built-in options] +c_args = [ + '-v28', + '-ml', + '-mt'] +c_link_args = [ + '-z', + '--rom_model', + '\f28004x_flash.cmd'] +cpp_args = [] +cpp_link_args = [] + +[properties] +needs_exe_wrapper = true diff --git a/meson/cross/ccomp-armv7a.txt b/meson/cross/ccomp-armv7a.txt new file mode 100644 index 000000000..af66ed269 --- /dev/null +++ b/meson/cross/ccomp-armv7a.txt @@ -0,0 +1,13 @@ +[binaries] +c = 'ccomp' +ar = 'ccomp' +strip = 'strip' + +[built-in options] +c_args = ['-target', 'armv7a-eabi', '-fall'] + +[host_machine] +system = 'bare metal' # Update with your system name - bare metal/OS. +cpu_family = 'arm' +cpu = 'Cortex-A9' +endian = 'little' diff --git a/meson/cross/ccrx.txt b/meson/cross/ccrx.txt new file mode 100644 index 000000000..f1b536c3a --- /dev/null +++ b/meson/cross/ccrx.txt @@ -0,0 +1,22 @@ +# This file assumes that path to the Renesas CC-RX toolchain is added +# to the environment(PATH) variable, so that Meson can find +# ccrx and rlink while building. +[binaries] +c = 'ccrx' +cpp = 'ccrx' +ar = 'rlink' +strip = 'rlink' + +[built-in options] +# The '--cpu' option with the appropriate target type should be mentioned +# to cross compile c/c++ code with ccrx,. +c_args = ['-cpu=rx600'] +cpp_args = ['-cpu=rx600'] +c_link_args = [] +cpp_link_args = [] + +[host_machine] +system = 'bare metal' +cpu_family = 'rx' +cpu = 'rx600' +endian = 'little' diff --git a/meson/cross/iphone.txt b/meson/cross/iphone.txt new file mode 100644 index 000000000..965940722 --- /dev/null +++ b/meson/cross/iphone.txt @@ -0,0 +1,27 @@ +# This is a cross compilation file from OSX Yosemite to iPhone +# Apple keeps changing the location and names of files so +# these might not work for you. Use the googels and xcrun. + +[binaries] +c = 'clang' +cpp = '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'] + +[properties] +root = '/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer' +has_function_printf = true +has_function_hfkerhisadf = false + +[host_machine] +system = 'darwin' +cpu_family = 'arm' +cpu = 'armv7' +endian = 'little' + diff --git a/meson/cross/linux-mingw-w64-32bit.json b/meson/cross/linux-mingw-w64-32bit.json new file mode 100644 index 000000000..476111183 --- /dev/null +++ b/meson/cross/linux-mingw-w64-32bit.json @@ -0,0 +1,7 @@ +{ + "file": "linux-mingw-w64-32bit.txt", + "tests": ["common", "cmake"], + "env": { + "WINEPATH": "/usr/lib/gcc/i686-w64-mingw32/9.2-posix;/usr/i686-w64-mingw32/bin;/usr/i686-w64-mingw32/lib" + } +} diff --git a/meson/cross/linux-mingw-w64-32bit.txt b/meson/cross/linux-mingw-w64-32bit.txt new file mode 100644 index 000000000..caf1da1a0 --- /dev/null +++ b/meson/cross/linux-mingw-w64-32bit.txt @@ -0,0 +1,31 @@ +[binaries] +c = '/usr/bin/i686-w64-mingw32-gcc' +cpp = '/usr/bin/i686-w64-mingw32-g++' +objc = '/usr/bin/i686-w64-mingw32-gcc' +ar = '/usr/bin/i686-w64-mingw32-ar' +strip = '/usr/bin/i686-w64-mingw32-strip' +pkgconfig = '/usr/bin/i686-w64-mingw32-pkg-config' +windres = '/usr/bin/i686-w64-mingw32-windres' +exe_wrapper = 'wine' +ld = '/usr/bin/i686-w64-mingw32-ld' +cmake = '/usr/bin/cmake' + +[properties] +# Directory that contains 'bin', 'lib', etc +root = '/usr/i686-w64-mingw32' +# Directory that contains 'bin', 'lib', etc for the toolchain and system libraries +sys_root = '/usr/i686-w64-mingw32/sys-root/mingw' + +[host_machine] +system = 'windows' +cpu_family = 'x86' +cpu = 'i686' +endian = 'little' + +[cmake] + +CMAKE_BUILD_WITH_INSTALL_RPATH = 'ON' +CMAKE_FIND_ROOT_PATH_MODE_PROGRAM = 'NEVER' +CMAKE_FIND_ROOT_PATH_MODE_LIBRARY = 'ONLY' +CMAKE_FIND_ROOT_PATH_MODE_INCLUDE = 'ONLY' +CMAKE_FIND_ROOT_PATH_MODE_PACKAGE = 'ONLY' diff --git a/meson/cross/linux-mingw-w64-64bit.json b/meson/cross/linux-mingw-w64-64bit.json new file mode 100644 index 000000000..df344da9d --- /dev/null +++ b/meson/cross/linux-mingw-w64-64bit.json @@ -0,0 +1,7 @@ +{ + "file": "linux-mingw-w64-64bit.txt", + "tests": ["common", "cmake"], + "env": { + "WINEPATH": "/usr/lib/gcc/x86_64-w64-mingw32/9.2-posix;/usr/x86_64-w64-mingw32/bin;/usr/x86_64-w64-mingw32/lib" + } +} diff --git a/meson/cross/linux-mingw-w64-64bit.txt b/meson/cross/linux-mingw-w64-64bit.txt new file mode 100644 index 000000000..f49fb35bf --- /dev/null +++ b/meson/cross/linux-mingw-w64-64bit.txt @@ -0,0 +1,30 @@ +[binaries] +c = '/usr/bin/x86_64-w64-mingw32-gcc' +cpp = '/usr/bin/x86_64-w64-mingw32-g++' +objc = '/usr/bin/x86_64-w64-mingw32-gcc' +ar = '/usr/bin/x86_64-w64-mingw32-ar' +strip = '/usr/bin/x86_64-w64-mingw32-strip' +pkgconfig = '/usr/bin/x86_64-w64-mingw32-pkg-config' +windres = '/usr/bin/x86_64-w64-mingw32-windres' +exe_wrapper = 'wine64' +cmake = '/usr/bin/cmake' + +[properties] +# Directory that contains 'bin', 'lib', etc +root = '/usr/x86_64-w64-mingw32' +# Directory that contains 'bin', 'lib', etc for the toolchain and system libraries +sys_root = '/usr/x86_64-w64-mingw32/sys-root/mingw' + +[host_machine] +system = 'windows' +cpu_family = 'x86_64' +cpu = 'x86_64' +endian = 'little' + +[cmake] + +CMAKE_BUILD_WITH_INSTALL_RPATH = 'ON' +CMAKE_FIND_ROOT_PATH_MODE_PROGRAM = 'NEVER' +CMAKE_FIND_ROOT_PATH_MODE_LIBRARY = 'ONLY' +CMAKE_FIND_ROOT_PATH_MODE_INCLUDE = 'ONLY' +CMAKE_FIND_ROOT_PATH_MODE_PACKAGE = 'ONLY' diff --git a/meson/cross/none.txt b/meson/cross/none.txt new file mode 100644 index 000000000..8727e27f4 --- /dev/null +++ b/meson/cross/none.txt @@ -0,0 +1,18 @@ +# native file used to make the build machine compiler unusable + +[host_machine] +system = 'none' +cpu_family = 'none' +cpu = 'none' +endian = 'little' + +[properties] + +[binaries] +c = ['false'] +cpp = ['false'] +objc = ['false'] +objcpp = ['false'] +ar = ['false'] +pkgconfig = ['false'] +cmake = ['false'] diff --git a/meson/cross/ownstdlib.txt b/meson/cross/ownstdlib.txt new file mode 100644 index 000000000..bdff6f44d --- /dev/null +++ b/meson/cross/ownstdlib.txt @@ -0,0 +1,13 @@ +# This is a setup for compiling a program that runs natively +# but uses a custom std lib. This test will only work on +# x86_64. + +[target_machine] +system = 'linux' +cpu_family = 'x86_64' +cpu = 'x86_64' +endian = 'little' + +[properties] + +c_stdlib = 'mylibc' # Subproject name diff --git a/meson/cross/tvos.txt b/meson/cross/tvos.txt new file mode 100644 index 000000000..833f04bfd --- /dev/null +++ b/meson/cross/tvos.txt @@ -0,0 +1,28 @@ +# This is a cross compilation file from OSX Yosemite to Apple tvOS +# Apple keeps changing the location and names of files so +# these might not work for you. Use the googels and xcrun. + +[binaries] +c = 'clang' +cpp = 'clang++' +ar = 'ar' +strip = 'strip' + +[built-in options] +c_args = ['-arch', 'arm64', '-mtvos-version-min=12.0', '-isysroot', '/Applications/Xcode.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk'] +cpp_args = ['-arch', 'arm64', '-mtvos-version-min=12.0', '-isysroot', '/Applications/Xcode.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk'] +c_link_args = ['-arch', 'arm64', '-mtvos-version-min=12.0', '-isysroot', '/Applications/Xcode.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk'] +cpp_link_args = ['-arch', 'arm64', '-mtvos-version-min=12.0', '-isysroot', '/Applications/Xcode.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk'] + +[properties] +root = '/Applications/Xcode.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer' + +has_function_printf = true +has_function_hfkerhisadf = false + +[host_machine] +system = 'darwin' +cpu_family = 'arm' +cpu = 'arm64' +endian = 'little' + diff --git a/meson/cross/ubuntu-armhf.json b/meson/cross/ubuntu-armhf.json new file mode 100644 index 000000000..40f5619c2 --- /dev/null +++ b/meson/cross/ubuntu-armhf.json @@ -0,0 +1,5 @@ +{ + "file": "ubuntu-armhf.txt", + "tests": ["common"], + "env": {} +} diff --git a/meson/cross/ubuntu-armhf.txt b/meson/cross/ubuntu-armhf.txt new file mode 100644 index 000000000..69e0c8611 --- /dev/null +++ b/meson/cross/ubuntu-armhf.txt @@ -0,0 +1,29 @@ +[binaries] +# we could set exe_wrapper = qemu-arm-static but to test the case +# when cross compiled binaries can't be run we don't do that +c = '/usr/bin/arm-linux-gnueabihf-gcc' +cpp = '/usr/bin/arm-linux-gnueabihf-g++' +rust = ['rustc', '--target', 'arm-unknown-linux-gnueabihf', '-C', 'linker=/usr/bin/arm-linux-gnueabihf-gcc-7'] +ar = '/usr/arm-linux-gnueabihf/bin/ar' +strip = '/usr/arm-linux-gnueabihf/bin/strip' +pkgconfig = '/usr/bin/arm-linux-gnueabihf-pkg-config' +ld = '/usr/bin/arm-linux/gnueabihf-ld' + +[built-in options] +# Used in unit test '140 get define' +c_args = ['-DMESON_TEST_ISSUE_1665=1'] +cpp_args = '-DMESON_TEST_ISSUE_1665=1' + +[properties] +root = '/usr/arm-linux-gnueabihf' + +has_function_printf = true +has_function_hfkerhisadf = false + +skip_sanity_check = true + +[host_machine] +system = 'linux' +cpu_family = 'arm' +cpu = 'armv7' # Not sure if correct. +endian = 'little' diff --git a/meson/cross/ubuntu-faketarget.txt b/meson/cross/ubuntu-faketarget.txt new file mode 100644 index 000000000..cc43998cc --- /dev/null +++ b/meson/cross/ubuntu-faketarget.txt @@ -0,0 +1,13 @@ +# This is a setup for compiling a program that runs natively +# but produces output that runs on a different platform. +# That is either a cross compiler or something like binutils. + +# We don't need to specify any properties or compilers, +# for we use the native ones and can run the resulting +# binaries directly. + +[target_machine] +system = 'linux' +cpu_family = 'mips' +cpu = 'mips' +endian = 'little' diff --git a/meson/cross/wasm.txt b/meson/cross/wasm.txt new file mode 100644 index 000000000..f2d0cd7f5 --- /dev/null +++ b/meson/cross/wasm.txt @@ -0,0 +1,18 @@ +[binaries] +c = '/home/jpakkane/emsdk/fastcomp/emscripten/emcc' +cpp = '/home/jpakkane/emsdk/fastcomp/emscripten/em++' +ar = '/home/jpakkane/emsdk/fastcomp/emscripten/emar' + +[built-in options] +c_args = ['-s', 'WASM=1', '-s', 'EXPORT_ALL=1'] +c_link_args = ['-s','EXPORT_ALL=1'] +cpp_args = ['-s', 'WASM=1', '-s', 'EXPORT_ALL=1'] +cpp_link_args = ['-s', 'EXPORT_ALL=1'] + +[host_machine] + +system = 'emscripten' +cpu_family = 'wasm32' +cpu = 'wasm32' +endian = 'little' + diff --git a/meson/cross/xc16.txt b/meson/cross/xc16.txt new file mode 100644 index 000000000..c66889deb --- /dev/null +++ b/meson/cross/xc16.txt @@ -0,0 +1,26 @@ +# This file assumes that path to the Microchip xc16 toolchain is added +# to the environment(PATH) variable, so that Meson can find +# xc16-gcc and xc16-ar while building. +[binaries] +c = 'xc16-gcc' +ar = 'xc16-ar' +strip = 'xc16-gcc' + +[host_machine] +system = 'bare metal' +cpu_family = 'dspic' +cpu = '33ep64mc203' +endian = 'little' + +[properties] +needs_exe_wrapper = true + +[built-in options] +c_args = [ + '-c', + '-mcpu=33EP64MC203', + '-omf=elf'] +c_link_args = [ + '-mcpu=33EP64MC203', + '-omf=elf', + '-Wl,--script=p33EP64MC203.gld,'] |