2018-09-15 09:42:42 +00:00
|
|
|
version: 2
|
|
|
|
jobs:
|
|
|
|
build:
|
|
|
|
docker:
|
2020-05-04 16:07:14 +00:00
|
|
|
- image: debian:bullseye
|
2018-09-15 09:42:42 +00:00
|
|
|
steps:
|
2020-05-04 16:07:14 +00:00
|
|
|
- run:
|
|
|
|
name: Install dependencies
|
|
|
|
command: |
|
|
|
|
apt update
|
|
|
|
apt install -y build-essential zlib1g-dev uuid-dev libdigest-sha-perl libelf-dev bc bzip2 bison flex git gnupg iasl m4 nasm patch python wget gnat cpio ccache pkg-config cmake libusb-1.0-0-dev autoconf texinfo ncurses-dev
|
2018-09-15 10:56:42 +00:00
|
|
|
- checkout
|
|
|
|
|
2018-09-18 16:08:16 +00:00
|
|
|
- run:
|
2020-05-04 16:07:14 +00:00
|
|
|
name: git reset
|
2018-09-18 16:08:16 +00:00
|
|
|
command: |
|
2020-05-04 16:07:14 +00:00
|
|
|
git reset --hard "$CIRCLE_SHA1" \
|
2018-09-18 16:08:16 +00:00
|
|
|
|
2020-08-11 20:38:26 +00:00
|
|
|
- run:
|
|
|
|
name: Creating all modules and patches digest
|
|
|
|
command: |
|
|
|
|
find ./patches/ ./modules/ -type f | sort -h |xargs sha256sum > /tmp/all_modules_and_patches.sha256sums \
|
|
|
|
|
|
|
|
- run:
|
|
|
|
name: Creating musl-cross-make and musl-cross-make patches digest
|
|
|
|
command: |
|
|
|
|
find ./patches/musl-cross-* modules/musl-cross* -type f | sort -h | xargs sha256sum > /tmp/musl-cross_module_and_patches.sha256sums \
|
|
|
|
|
|
|
|
|
|
|
|
- restore_cache:
|
|
|
|
keys:
|
|
|
|
#Restore existing cache for modules checksums validated to be exactly the same as in github current commit
|
|
|
|
- heads-modules-and-patches-{{ checksum "/tmp/all_modules_and_patches.sha256sums" }}
|
|
|
|
#If precedent fails. Restore cache for musl-cross module checksum validated to be exactly the same as in github current commit
|
|
|
|
- heads-cross-musl-{{ checksum "/tmp/musl-cross_module_and_patches.sha256sums" }}
|
|
|
|
|
2020-01-08 23:07:19 +00:00
|
|
|
# linuxboot steps need something to pass in the kernel header path
|
|
|
|
# skipping for now
|
|
|
|
# - run:
|
|
|
|
# name: qemu-linuxboot-edk2
|
|
|
|
# command: |
|
|
|
|
# ./build/make-4.2.1/make \
|
|
|
|
# CROSS=/cross/bin/x86_64-linux-musl- \
|
|
|
|
# BOARD=qemu-linuxboot \
|
|
|
|
# `/bin/pwd`/build/linuxboot-git/build/qemu/.configured \
|
|
|
|
# # Run first to avoid too many processes
|
|
|
|
#
|
|
|
|
# - run:
|
|
|
|
# name: qemu-linuxboot
|
|
|
|
# command: |
|
|
|
|
# ./build/make-4.2.1/make \
|
|
|
|
# CROSS=/cross/bin/x86_64-linux-musl- \
|
|
|
|
# --load 2 \
|
|
|
|
# V=1 \
|
|
|
|
# BOARD=qemu-linuxboot \
|
|
|
|
#
|
|
|
|
# - store-artifacts:
|
|
|
|
# path: build/qemu-linuxboot/linuxboot.rom
|
|
|
|
# - store-artifacts:
|
|
|
|
# path: build/qemu-linuxboot/hashes.txt
|
2018-09-18 11:14:39 +00:00
|
|
|
|
2020-06-06 16:35:13 +00:00
|
|
|
- run:
|
|
|
|
name: x230-flash
|
2020-08-12 19:07:54 +00:00
|
|
|
#We delete build/make-4.2.1/ directory until issue #799 is fixed.
|
2020-06-06 16:35:13 +00:00
|
|
|
command: |
|
2020-08-12 19:07:54 +00:00
|
|
|
rm -rf build/make-4.2.1/ build/x230-flash/* build/log/* && make --load 2 \
|
2020-06-06 16:35:13 +00:00
|
|
|
V=1 \
|
|
|
|
BOARD=x230-flash \
|
|
|
|
no_output_timeout: 3h
|
|
|
|
- run:
|
|
|
|
name: Ouput x230-flash hashes
|
|
|
|
command: |
|
|
|
|
cat build/x230-flash/hashes.txt \
|
|
|
|
- run:
|
|
|
|
name: Archiving build logs for x230-flash
|
|
|
|
command: |
|
|
|
|
tar zcvf build/x230-flash/logs.tar.gz build/log/*
|
|
|
|
- store-artifacts:
|
|
|
|
path: build/x230-flash
|
2018-09-18 17:07:14 +00:00
|
|
|
|
2020-01-08 21:45:39 +00:00
|
|
|
- run:
|
2020-06-06 16:35:13 +00:00
|
|
|
name: t430-flash
|
2020-01-08 21:45:39 +00:00
|
|
|
command: |
|
2020-06-06 16:35:13 +00:00
|
|
|
rm -rf build/t430-flash/* build/log/* && make --load 2 \
|
2020-01-08 22:26:20 +00:00
|
|
|
V=1 \
|
2020-06-06 16:35:13 +00:00
|
|
|
BOARD=t430-flash \
|
2020-05-04 16:07:14 +00:00
|
|
|
no_output_timeout: 3h
|
|
|
|
- run:
|
2020-06-06 16:35:13 +00:00
|
|
|
name: Ouput t430-flash hashes
|
2020-05-04 16:07:14 +00:00
|
|
|
command: |
|
2020-06-06 16:35:13 +00:00
|
|
|
cat build/t430-flash/hashes.txt \
|
2020-05-24 21:12:13 +00:00
|
|
|
- run:
|
2020-06-06 16:35:13 +00:00
|
|
|
name: Archiving build logs for t430-flash
|
2020-05-24 21:12:13 +00:00
|
|
|
command: |
|
2020-06-06 16:35:13 +00:00
|
|
|
tar zcvf build/t430-flash/logs.tar.gz build/log/*
|
2020-01-08 21:45:39 +00:00
|
|
|
- store-artifacts:
|
2020-06-06 16:35:13 +00:00
|
|
|
path: build/t430-flash
|
2020-05-24 21:12:13 +00:00
|
|
|
|
2020-05-04 16:07:14 +00:00
|
|
|
- run:
|
2020-06-06 16:35:13 +00:00
|
|
|
name: t430
|
2020-05-04 16:07:14 +00:00
|
|
|
command: |
|
2020-06-06 16:35:13 +00:00
|
|
|
rm -rf build/t430/* build/log/* && make --load 2 \
|
2020-05-04 16:07:14 +00:00
|
|
|
V=1 \
|
2020-06-06 16:35:13 +00:00
|
|
|
BOARD=t430 \
|
2020-05-04 16:07:14 +00:00
|
|
|
no_output_timeout: 3h
|
|
|
|
- run:
|
2020-06-06 16:35:13 +00:00
|
|
|
name: Ouput t430 hashes
|
2020-05-04 16:07:14 +00:00
|
|
|
command: |
|
2020-06-06 16:35:13 +00:00
|
|
|
cat build/t430/hashes.txt \
|
2020-05-24 21:12:13 +00:00
|
|
|
- run:
|
2020-06-06 16:35:13 +00:00
|
|
|
name: Archiving build logs for t430
|
2020-05-24 21:12:13 +00:00
|
|
|
command: |
|
2020-06-06 16:35:13 +00:00
|
|
|
tar zcvf build/t430/logs.tar.gz build/log/*
|
2020-05-24 21:12:13 +00:00
|
|
|
- store-artifacts:
|
2020-06-06 16:35:13 +00:00
|
|
|
path: build/t430
|
2020-05-24 21:12:13 +00:00
|
|
|
|
2018-09-18 17:07:14 +00:00
|
|
|
- run:
|
|
|
|
name: x230
|
|
|
|
command: |
|
2020-05-24 21:12:13 +00:00
|
|
|
rm -rf build/x230/* build/log/* && make --load 2 \
|
2020-01-08 22:26:20 +00:00
|
|
|
V=1 \
|
2018-09-18 17:07:14 +00:00
|
|
|
BOARD=x230 \
|
2020-05-04 16:07:14 +00:00
|
|
|
no_output_timeout: 3h
|
|
|
|
- run:
|
|
|
|
name: Ouput x230 hashes
|
|
|
|
command: |
|
|
|
|
cat build/x230/hashes.txt \
|
2020-05-24 21:12:13 +00:00
|
|
|
- run:
|
|
|
|
name: Archiving build logs for x230
|
|
|
|
command: |
|
|
|
|
tar zcvf build/x230/logs.tar.gz build/log/*
|
|
|
|
- store-artifacts:
|
|
|
|
path: build/x230
|
|
|
|
|
2020-05-16 17:38:14 +00:00
|
|
|
- run:
|
|
|
|
name: x230-hotp-verification
|
|
|
|
command: |
|
2020-05-24 21:12:13 +00:00
|
|
|
rm -rf build/x230-hotp-verification/* build/log/* && make --load 2 \
|
2020-05-16 17:38:14 +00:00
|
|
|
V=1 \
|
|
|
|
BOARD=x230-hotp-verification \
|
|
|
|
no_output_timeout: 3h
|
|
|
|
- run:
|
|
|
|
name: Ouput x230-hotp-verification hashes
|
|
|
|
command: |
|
|
|
|
cat build/x230-hotp-verification/hashes.txt \
|
2020-05-04 16:07:14 +00:00
|
|
|
- run:
|
2020-05-24 21:12:13 +00:00
|
|
|
name: Archiving build logs for x230-hotp-verification
|
2020-05-04 16:07:14 +00:00
|
|
|
command: |
|
2020-05-24 21:12:13 +00:00
|
|
|
tar zcvf build/x230-hotp-verification/logs.tar.gz build/log/*
|
2020-05-04 16:07:14 +00:00
|
|
|
- store-artifacts:
|
2020-05-24 21:12:13 +00:00
|
|
|
path: build/x230-hotp-verification
|
2018-09-18 17:07:14 +00:00
|
|
|
|
2020-06-06 16:35:13 +00:00
|
|
|
- run:
|
|
|
|
name: qemu-coreboot
|
|
|
|
command: |
|
2020-08-12 19:07:54 +00:00
|
|
|
rm -rf build/qemu-coreboot/* build/log/* && make --load 2 \
|
2020-06-06 16:35:13 +00:00
|
|
|
V=1 \
|
|
|
|
BOARD=qemu-coreboot \
|
|
|
|
no_output_timeout: 3h
|
|
|
|
- run:
|
|
|
|
name: Output qemu-coreboot hashes
|
|
|
|
command: |
|
|
|
|
cat build/qemu-coreboot/hashes.txt \
|
|
|
|
- run:
|
|
|
|
name: Archiving build logs for qemu-coreboot
|
|
|
|
command: |
|
|
|
|
tar zcvf build/qemu-coreboot/logs.tar.gz build/log/*
|
|
|
|
- store-artifacts:
|
|
|
|
path: build/qemu-coreboot
|
|
|
|
|
2020-05-04 16:07:14 +00:00
|
|
|
- save_cache:
|
2020-08-11 20:38:26 +00:00
|
|
|
#Generate cache for the same musl-cross module definition if hash is not previously existing
|
|
|
|
key: heads-cross-musl-{{ checksum "/tmp/musl-cross_module_and_patches.sha256sums" }}
|
|
|
|
paths:
|
|
|
|
- crossgcc
|
|
|
|
- build/musl-cross-*
|
|
|
|
|
|
|
|
- save_cache:
|
|
|
|
#Generate cache for the exact same modules definitions if hash is not previously existing
|
|
|
|
key: heads-modules-and-patches-{{ checksum "/tmp/all_modules_and_patches.sha256sums" }}
|
2020-05-04 16:07:14 +00:00
|
|
|
paths:
|
|
|
|
- packages
|
|
|
|
- crossgcc
|
|
|
|
- build
|
2018-09-15 09:42:42 +00:00
|
|
|
workflows:
|
|
|
|
version: 2
|
|
|
|
build_and_test:
|
|
|
|
jobs:
|
|
|
|
- build
|