[x86_64] Meson cross-compile template is arch-agnostic
# https://github.com/mesonbuild/meson/issues/309
# axle_repo_root will be filled in when the .ini is generated for the first time
-toolchain_root = axle_repo_root + '/i686-toolchain'
+arch = 'x86_64'
+toolchain_root = axle_repo_root + '/' + arch + '-toolchain'
sysroot = axle_repo_root + '/axle-sysroot'
[properties]
-c_args = ['-I' + sysroot + '/usr/i686-axle/include', '-g', '-fdiagnostics-color=always']
-c_link_args = ['-T', axle_repo_root + '/programs/linker.ld', '-lc', '-L' + sysroot + '/usr/i686-axle/lib', '-nostartfiles', '-Bstatic']
+c_args = ['-I' + sysroot + '/usr/' + arch + '-axle/include', '-g', '-fdiagnostics-color=always']
+c_link_args = ['-T', axle_repo_root + '/programs/linker.ld', '-lc', '-L' + sysroot + '/usr/' + arch + '-axle/lib', '-nostartfiles', '-Bstatic']
# Exposed to build scripts
initrd_dir = axle_repo_root + '/initrd/'
-include_root = sysroot + '/usr/i686-axle/include'
-libraries_root = sysroot + '/usr/i686-axle/lib'
+include_root = sysroot + '/usr/' + arch + '-axle/include'
+libraries_root = sysroot + '/usr/' + arch + '-axle/lib'
[binaries]
-c = toolchain_root + '/bin/i686-elf-gcc'
-ar = toolchain_root + '/bin/i686-elf-ar'
-ranlib = toolchain_root + '/bin/i686-elf-ranlib'
+c = toolchain_root + '/bin/' + arch + '-elf-gcc'
+ar = toolchain_root + '/bin/' + arch + '-elf-ar'
+ranlib = toolchain_root + '/bin/' + arch + '-elf-ranlib'
[host_machine]
system = 'axle'
cpu_family = 'x86'
-cpu = 'i686'
+cpu = arch
endian = 'little'
