[dpdk-dev] [PATCH v11 6/7] ci: add aarch64 -> aarch32 cross compiling jobs

Juraj Linkeš juraj.linkes at pantheon.tech
Wed Dec 9 13:59:30 CET 2020


Add two jobs (static and shared libs), both building on aarch64 and
producing 32-bit arm binaries executable on armv8-a, but not armv7.
Do not run tests in these jobs.

Signed-off-by: Juraj Linkeš <juraj.linkes at pantheon.tech>
Reviewed-by: Ruifeng Wang <ruifeng.wang at arm.com>
---
 .ci/linux-build.sh |  7 ++++++-
 .travis.yml        | 19 +++++++++++++++++++
 2 files changed, 25 insertions(+), 1 deletion(-)

diff --git a/.ci/linux-build.sh b/.ci/linux-build.sh
index d079801d7..cdb371565 100755
--- a/.ci/linux-build.sh
+++ b/.ci/linux-build.sh
@@ -33,6 +33,11 @@ if [ "$AARCH64" = "1" ]; then
     OPTS="$OPTS --cross-file config/arm/arm64_armv8_linux_gcc"
 fi
 
+if [ "$AARCH32" = "1" ]; then
+    # convert the arch specifier
+    OPTS="$OPTS --cross-file config/arm/arm32_armv8a_linux_gcc"
+fi
+
 if [ "$BUILD_DOCS" = "1" ]; then
     OPTS="$OPTS -Denable_docs=true"
 fi
@@ -53,7 +58,7 @@ OPTS="$OPTS --buildtype=debugoptimized"
 meson build --werror $OPTS
 ninja -C build
 
-if [ "$AARCH64" != "1" ]; then
+if [ "$AARCH64" != "1" ] && [ "$AARCH32" != "1" ]; then
     devtools/test-null.sh
 fi
 
diff --git a/.travis.yml b/.travis.yml
index 5e12db23b..5e87029cb 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -18,6 +18,10 @@ _aarch64_packages: &aarch64_packages
   - *required_packages
   - [gcc-aarch64-linux-gnu, libc6-dev-arm64-cross, pkg-config-aarch64-linux-gnu]
 
+_arm_32b_packages: &arm_32b_packages
+  - *required_packages
+  - [gcc-arm-linux-gnueabihf, libc6-dev-armhf-cross, pkg-config-arm-linux-gnueabihf]
+
 _build_32b_packages: &build_32b_packages
   - *required_packages
   - [gcc-multilib]
@@ -104,6 +108,21 @@ jobs:
         packages:
           - *required_packages
           - *doc_packages
+  # aarch64 cross-compiling aarch32 jobs
+  - env: DEF_LIB="shared" AARCH32=1
+    arch: arm64
+    compiler: gcc
+    addons:
+      apt:
+        packages:
+          - *arm_32b_packages
+  - env: DEF_LIB="static" AARCH32=1
+    arch: arm64
+    compiler: gcc
+    addons:
+      apt:
+        packages:
+          - *arm_32b_packages
   # aarch64 clang jobs
   - env: DEF_LIB="static"
     arch: arm64
-- 
2.20.1



More information about the dev mailing list