[dpdk-dev] [PATCH v5 4/4] ci: add aarch64 -> arm32 cross compiling jobs
Juraj Linkeš
juraj.linkes at pantheon.tech
Mon Jul 6 11:11:54 CEST 2020
> -----Original Message-----
> From: Juraj Linkeš <juraj.linkes at pantheon.tech>
> Sent: Monday, July 6, 2020 10:28 AM
> To: bruce.richardson at intel.com; aconole at redhat.com;
> maicolgabriel at hotmail.com
> Cc: dev at dpdk.org; Juraj Linkeš <juraj.linkes at pantheon.tech>
> Subject: [PATCH v5 4/4] ci: add aarch64 -> arm32 cross compiling jobs
>
> Add two jobs (static and shared libs), both building on aarch64 and producing 32
> bit arm binaries. Do not run tests in these jobs.
>
> Signed-off-by: Juraj Linkeš <juraj.linkes at pantheon.tech>
> ---
> .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..e5407fb37
> 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 [ "$ARM" = "1" ]; then
> + # convert the arch specifier
> + OPTS="$OPTS --cross-file config/arm/arm_armv7a_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 [ "$(uname -m)" = "x86_64" ]; then
> devtools/test-null.sh
> fi
>
Now that I think about this a bit more, shouldn't this check be "if this is a native build, run test-null.sh?". If so, should we do something like this?
if file build/app/dpdk-testpmd | sed 's/-/_/g' | grep -q "$(uname -m)"; then
devtools/test-null.sh
fi
The sed is there because file returns x86-64 and uname returns x86_64.
What do you think?
> diff --git a/.travis.yml b/.travis.yml
> index 14f812423..baba29539 100644
> --- a/.travis.yml
> +++ b/.travis.yml
> @@ -21,6 +21,10 @@ _aarch64_packages: &aarch64_packages
> - *required_packages
> - [gcc-aarch64-linux-gnu, libc6-dev-arm64-cross, pkg-config-aarch64-linux-
> gnu]
>
> +_arm_packages: &arm_packages
> + - *required_packages
> + - [gcc-arm-linux-gnueabihf, libc6-dev-armhf-cross,
> +pkg-config-arm-linux-gnueabihf]
> +
> _libabigail_build_packages: &libabigail_build_packages
> - [autoconf, automake, libtool, pkg-config, libxml2-dev, libdw-dev]
>
> @@ -124,6 +128,21 @@ jobs:
> packages:
> - *required_packages
> - *libabigail_build_packages
> + # aarch64 cross-compiling arm jobs
> + - env: DEF_LIB="shared" ARM=1
> + arch: arm64
> + compiler: gcc
> + addons:
> + apt:
> + packages:
> + - *arm_packages
> + - env: DEF_LIB="static" ARM=1
> + arch: arm64
> + compiler: gcc
> + addons:
> + apt:
> + packages:
> + - *arm_packages
> # aarch64 clang jobs
> - env: DEF_LIB="static"
> arch: arm64
> --
> 2.20.1
More information about the dev
mailing list