diff options
author | ohfp <1813007-ohfp@users.noreply.gitlab.com> | 2020-03-06 21:17:06 +0100 |
---|---|---|
committer | ohfp <1813007-ohfp@users.noreply.gitlab.com> | 2020-03-06 21:17:06 +0100 |
commit | 8378fcc076b44e46203e9fc1a50d57bac73a1d8c (patch) | |
tree | be90108b8eb3c255a161ab7b06e4f2d1b79c6a6f /.gitlab-ci.yml | |
parent | fix appimage build (diff) | |
download | librewolf-linux-8378fcc076b44e46203e9fc1a50d57bac73a1d8c.tar.gz librewolf-linux-8378fcc076b44e46203e9fc1a50d57bac73a1d8c.tar.bz2 librewolf-linux-8378fcc076b44e46203e9fc1a50d57bac73a1d8c.zip |
Partial rewrite of build process
Switching to an Arch based build process for easier maintenance and
using specific runners for tasks where that might be necessary.
Right now, parent/child pipelines for somewhat parallel builds for
different architectures / semi-independent pak-builds don't seem to
properly work yet due to `trigger:` not being recognized when it should,
so that's not yet implemented.
Diffstat (limited to '.gitlab-ci.yml')
-rw-r--r-- | .gitlab-ci.yml | 127 |
1 files changed, 78 insertions, 49 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index f230b82..dd96d4a 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,54 +1,83 @@ -image: ubuntu:18.04 +stages: + - build + - paks -variables: - BINARY_TARBALL: "$CI_PROJECT_DIR/LibreWolf.tar.bz2" - APPIMAGE_FILE: "$CI_PROJECT_DIR/LibreWolf.AppImage" - FLATPAK_REPO: "$CI_PROJECT_DIR/librewolf-flatpak-repo" - FLATPAK_BUNDLE: "$CI_PROJECT_DIR/LibreWolf.flatpak" +.carch_aarch64: &carch_aarch64 + variables: + CARCH: 'aarch64' -stages: - - Build - - Package - - Deploy - -Build Tarball: - stage: Build - tags: [librewolf] - script: - - $CI_PROJECT_DIR/binary_tarball/build_tarball.sh $BINARY_TARBALL - artifacts: - name: "Librewolf-$CI_COMMIT_REF_NAME-Linux-Tarball" - paths: - - "$BINARY_TARBALL" - -Build AppImage: - stage: Package - tags: [gitlab-org] - script: - - $CI_PROJECT_DIR/appimage/build_appimage.sh $BINARY_TARBALL $APPIMAGE_FILE - artifacts: - name: "Librewolf-$CI_COMMIT_REF_NAME-Linux-Appimage" - paths: - - "$APPIMAGE_FILE" - -Build Flatpak: - image: black0/flatpak - stage: Package - tags: - - gitlab-org - script: - - $CI_PROJECT_DIR/flatpak/build_flatpak.sh $BINARY_TARBALL $FLATPAK_REPO $FLATPAK_BUNDLE - artifacts: - name: "Librewolf-$CI_COMMIT_REF_NAME-Linux-Flatpak" - paths: - - "$FLATPAK_REPO" - - "$FLATPAK_BUNDLE" - -Release to Gitlab: - stage: Deploy - image: python3 +.carch_x86_64: &carch_x86_64 + variables: + CARCH: 'x86_64' + +.main_build_config: &main_build_config + stage: build script: - - pip3 install gitlab-release - - gitlab-release LibreWolf.tar.bz2 LibreWolf.AppImage librewolf-flatpak-repo LibreWolf.flatpak + - ./scripts/01_arch_build.sh + - ./scripts/02_configure_tarball.sh + artifacts: + name: "Librewolf-${CI_COMMIT_TAG}-${CARCH}" + paths: + - "librewolf*pkg.tar*" + - "LibreWolf.${CARCH}.tar.bz2" only: - tags + +.flatpak_config: &flatpak_config + stage: paks + artifacts: + name: "Librewolf-${CI_COMMIT_TAG}-Flatpak-${CARCH}" + paths: + - "LibreWolf.${CARCH}.flatpak" + - "${CI_PROJECT_DIR}/librewolf-flatpak-repo" + only: + - tags + script: + - ./flatpak/build_flatpak.sh "${CI_PROJECT_DIR}/LibreWolf.${CARCH}.tar.bz2" "${CI_PROJECT_DIR}/librewolf-flatpak-repo" "${CI_PROJECT_DIR}/LibreWolf.${CARCH}.flatpak" + +.appimage_config: &appimage_config + stage: paks + artifacts: + name: "Librewolf-${CI_COMMIT_TAG}-AppImage-${CARCH}" + paths: + - "LibreWolf.${CARCH}.AppImage" + only: + - tags + script: + - ./appimage/build_appimage.sh "${CI_PROJECT_DIR}/LibreWolf.${CARCH}.tar.bz2" "${CI_PROJECT_DIR}/LibreWolf.${CARCH}.AppImage" + +build_x86_64: + image: archlinux/base + tags: [x86_64b] + <<: *carch_x86_64 + <<: *main_build_config + +build_aarch64: + image: registry.gitlab.com/ohfp/manjaro-arm-docker + tags: [aarch64b] + <<: *carch_aarch64 + <<: *main_build_config + +flatpak_x86_64: + image: ubuntu:18.04 + tags: [flat_runner] + <<: *carch_x86_64 + <<: *flatpak_config + +flatpak_aarch64: + image: arm64v8/ubuntu:18.04 + tags: [flat_runner_aarch64] + <<: *carch_aarch64 + <<: *flatpak_config + +appimage_x86_64: + image: ubuntu:18.04 + tags: [x86_64b] + <<: *carch_x86_64 + <<: *appimage_config + +appimage_aarch64: + image: arm64v8/ubuntu:18.04 + tags: [aarch64b] + <<: *carch_aarch64 + <<: *appimage_config |