From ab2cbdbe5b1d6f65f467611ba977640b1aaeced9 Mon Sep 17 00:00:00 2001 From: Matthieu Gautier Date: Tue, 28 Mar 2023 17:47:48 +0200 Subject: [PATCH] Introduce aarch64 target. In opposition to 32 bits, it is adapted to all PI (as long as they are in 64 bits). --- kiwixbuild/dependencies/armhf.py | 16 ++++++++++++++++ kiwixbuild/platforms/armhf.py | 14 ++++++++++++++ 2 files changed, 30 insertions(+) diff --git a/kiwixbuild/dependencies/armhf.py b/kiwixbuild/dependencies/armhf.py index 44912da..c0b350d 100644 --- a/kiwixbuild/dependencies/armhf.py +++ b/kiwixbuild/dependencies/armhf.py @@ -7,6 +7,9 @@ base_url = 'https://master.dl.sourceforge.net/project/raspberry-pi-cross-compile # This is Gcc 10.3.0 and Raspberry Pi 2 and 3 only ! armhf_base_url = base_url + 'Raspberry%20Pi%20GCC%20Cross-Compiler%20Toolchains/Stretch/GCC%2010.3.0/Raspberry%20Pi%202%2C%203/' +# This is Gcc 10.3.0 and ALL rapsberry Pi arch64 +aarch_base_url = base_url + 'Bonus%20Raspberry%20Pi%20GCC%2064-Bit%20Toolchains/Raspberry%20Pi%20GCC%2064-Bit%20Cross-Compiler%20Toolchains/Stretch/GCC%2010.3.0/' + class armhf_toolchain(Dependency): dont_skip = True neutral = True @@ -18,3 +21,16 @@ class armhf_toolchain(Dependency): armhf_base_url + 'cross-gcc-10.3.0-pi_2-3.tar.gz') Builder = NoopBuilder + + +class aarch64_toolchain(Dependency): + dont_skip = True + neutral = True + name = "aarch64" + + class Source(ReleaseDownload): + archive = Remotefile('cross-gcc-10.3.0-pi_64.tar.gz', + '5b3fdb7ee8c496c377ab8b11d7ffd404b4d3041f4fdcfeebcbcb734d45a5f3e9', + aarch_base_url + 'cross-gcc-10.3.0-pi_64.tar.gz') + + Builder = NoopBuilder diff --git a/kiwixbuild/platforms/armhf.py b/kiwixbuild/platforms/armhf.py index fd7cf17..20bb5c5 100644 --- a/kiwixbuild/platforms/armhf.py +++ b/kiwixbuild/platforms/armhf.py @@ -106,3 +106,17 @@ class ArmhfDyn(ArmhfPlatformInfo): class ArmhfStatic(ArmhfPlatformInfo): name = 'armhf_static' static = True + + +class Aarch64(ArmhfPlatformInfo): + build = 'aarch64' + arch_full = 'aarch64-linux-gnu' + toolchain_names = ['aarch64'] + +class Aarch64Dyn(Aarch64): + name = 'aarch64_dyn' + static = False + +class Aarch64Static(Aarch64): + name = 'aarch64_static' + static = True