On Mon, Jul 9, 2018 at 11:44 AM, Niels Möller <[email protected]> wrote: >> @@ -1,7 +1,7 @@ >> variables: >> BUILD_IMAGES_PROJECT: gnutls/build-images >> - FEDORA_BUILD: buildenv-f26 >> - FEDORA_X86_BUILD: buildenv-f26-x86 >> + FEDORA_BUILD: buildenv-f28 >> + FEDORA_X86_BUILD: buildenv-f28-x86 >> GET_SOURCES_ATTEMPTS: "3" >> >> # remove any pre-installed headers from nettle > > Applied. Should hopefully make the gnutls build pass, leaving only the > aarch64 ci failures. > > Is it easy to add a (32-bit) arm build in .gitlab-ci? Any of real > hardware, qemu virtual machine, or cross compile + qemu-user testing, > would be good to have. Otherwise, I'll have to do some local testing to > ensure that arm fat and non-fat builds still work.
Patch is attached adding the builds from gnutls (mips,arm,aarch64). The output is at: https://gitlab.com/nmav/nettle/pipelines/25504684 The fat-arm build fails with: fat-arm.c: In function 'fat_init': fat-arm.c:194:7: error: '_nettle_sha1_compress_vec' undeclared (first use in this function); did you mean 'nettle_sha1_compress_vec'? _nettle_sha1_compress_vec = _nettle_sha1_compress_armv6; ^~~~~~~~~~~~~~~~~~~~~~~~~ nettle_sha1_compress_vec fat-arm.c:194:7: note: each undeclared identifier is reported only once for each function it appears in Makefile:258: recipe for target 'fat-arm.o' failed make[1]: *** [fat-arm.o] Error 1 btw. Note that fat-arm.c capabilities detection can be simplified with getauxval: https://community.arm.com/android-community/b/android/posts/runtime-detection-of-cpu-features-on-an-armv8-a-cpu I've modified gnutls to use that too: https://gitlab.com/gnutls/gnutls/blob/master/lib/accelerated/aarch64/aarch64-common.c#L69 regards, Nikos
From a0a05a7fa3f507179ae1f41da6b76951d002838d Mon Sep 17 00:00:00 2001 From: Nikos Mavrogiannopoulos <[email protected]> Date: Tue, 10 Jul 2018 20:58:36 +0200 Subject: [PATCH] .gitlab-ci.yml: added cross compilation and tests on mips/aarch64/arm This utilizes the qemu-user system used by gnutls. This also deprecates the previous aarch64 build. Signed-off-by: Nikos Mavrogiannopoulos <[email protected]> --- .gitlab-ci.yml | 41 ++++++++++++++++++++++++++++------------- 1 file changed, 28 insertions(+), 13 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 52f41c74..166de71b 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,5 +1,6 @@ variables: BUILD_IMAGES_PROJECT: gnutls/build-images + DEBIAN_CROSS_BUILD: buildenv-debian-cross FEDORA_BUILD: buildenv-f28 FEDORA_X86_BUILD: buildenv-f28-x86 GET_SOURCES_ATTEMPTS: "3" @@ -29,19 +30,6 @@ build/x86: - shared except: - tags -build/aarch64: - before_script: - - /bin/true - script: - - ./.bootstrap && - ./configure --enable-fat --disable-documentation && make -j4 && - make check -j4 - tags: - - aarch64 - only: - - branches@gnutls/nettle - except: - - tags build/mini-gmp: image: $CI_REGISTRY/$BUILD_IMAGES_PROJECT:$FEDORA_BUILD script: @@ -110,3 +98,30 @@ build/gnutls: - gnutls-git/*.log - gnutls-git/tests/*/*.log - gnutls-git/tests/suite/*/*.log +.Debian.cross.template: &Debian_cross_template + image: $CI_REGISTRY/$BUILD_IMAGES_PROJECT:$DEBIAN_CROSS_BUILD + before_script: + # remove any previously installed nettle headers to avoid conflicts + - for arch in armhf mips arm64;do apt-get remove -y nettle-dev:$arch;done + script: + - build=$(dpkg-architecture -qDEB_HOST_GNU_TYPE) + - host="${CI_JOB_NAME#*.cross.}" + # not setting CC_FOR_BUILD paired with qemu-user/binfmt somehow causes + # config.guess to detect the target as the build platform and not activate + # cross-compile mode even though --build is given + - export CC_FOR_BUILD="gcc" + - export CC="$host-gcc" + - ./.bootstrap + - ./configure --disable-static --enable-fat --disable-documentation --build=$build --host=$host + - make -j$(nproc) + - make -j$(nproc) check + tags: + - shared + except: + - tags +Debian.cross.arm-linux-gnueabihf: + <<: *Debian_cross_template +Debian.cross.mips-linux-gnu: + <<: *Debian_cross_template +Debian.cross.aarch64-linux-gnu: + <<: *Debian_cross_template -- 2.18.0
_______________________________________________ nettle-bugs mailing list [email protected] http://lists.lysator.liu.se/mailman/listinfo/nettle-bugs
