Currently the build for Haze produces images for ath79 target (default).
This is happening, because there is no ipq807x target in the tree
anymore, because upstream in commit f02f6aaa8d ("ipq807x: rename
target to qualcommax") renamed the target for following reasons:
Currently, ipq807x only covers Qualcomm IPQ807x SoC-s.
However, Qualcomm also has IPQ60xx and IPQ50xx SoC-s under the AX WiSoC-s
and they share a lot of stuff with IPQ807x, especially IPQ60xx so to avoid
duplicating kernel patches and everything lets make a common target with
per SoC subtargets.
Start doing that by renaming ipq807x to qualcommax so that dependencies
on ipq807x target can be updated.
So lets fix the profile using the new target/subtarget structure.
Fixes: PCF-1605
References: PCF-1574
References: https://github.com/openwrt/openwrt/commit/f02f6aaa8d4e
Signed-off-by: Petr Štetiar <petr.stetiar@prplfoundation.org>
217 lines
6.9 KiB
YAML
217 lines
6.9 KiB
YAML
variables:
|
|
CI_DESIGNATED_BRANCH: prpl/nightly
|
|
CI_DESIGNATED_BRANCH_SLUG: prpl-nightly
|
|
|
|
stages:
|
|
- generate
|
|
- build
|
|
|
|
.build feed with SDK:
|
|
tags:
|
|
- package-builder
|
|
stage: build
|
|
image: $CI_SDK_IMAGE
|
|
variables:
|
|
CI_SDK_TOPDIR: /home/builder
|
|
CI_SDK_INSTALL_FEEDS: base packages luci routing
|
|
CI_SDK_BUILD_CONFIG: >
|
|
+BUILD_LOG -AUTOREMOVE -ALL -ALL_NONSHARED -ALL_KMODS -SIGNED_PACKAGES
|
|
|
|
before_script:
|
|
- set -o pipefail
|
|
- git config --global --add safe.directory '*'
|
|
|
|
- cd $CI_SDK_TOPDIR
|
|
- mkdir logs
|
|
|
|
- sed -i -E 's;git.openwrt.org/(feed|project);github.com/openwrt;' feeds.conf.default
|
|
- echo "src-include defaults feeds.conf.default" > feeds.conf
|
|
- echo "src-link ci $CI_PROJECT_DIR" >> feeds.conf
|
|
|
|
- >
|
|
for feed in $CI_SDK_INSTALL_FEEDS ci; do
|
|
./scripts/feeds update "$feed" ;
|
|
./scripts/feeds install -a -p "$feed" ;
|
|
done 2>&1 | tee logs/build.log
|
|
|
|
- sync
|
|
- sleep 1
|
|
- sync
|
|
|
|
- >
|
|
for option in $CI_SDK_BUILD_CONFIG $CI_SDK_BUILD_CONFIG_EXTRA; do
|
|
echo "$option" | sed -E "s/^\+(.*)$/CONFIG_\1=y/;s/^\-(.*)$/CONFIG_\1=n/" >> .config
|
|
done
|
|
- cat .config | tee --append logs/build.log
|
|
- sed -i '/^config SAH_/{N;/\n\tbool/N;/\n\tdefault/d;}' Config-build.in
|
|
- make defconfig | tee --append logs/build.log
|
|
- ./scripts/diffconfig.sh | tee --append logs/build.log
|
|
|
|
- sync
|
|
- sleep 1
|
|
- sync
|
|
|
|
script:
|
|
- git config --global --add safe.directory '*'
|
|
|
|
- >
|
|
test -n "$CI_SDK_BEFORE_COMPILE_COMMAND" &&
|
|
echo "Running CI_SDK_BEFORE_COMPILE_COMMAND=$CI_SDK_BEFORE_COMPILE_COMMAND" &&
|
|
/bin/sh -c "$CI_SDK_BEFORE_COMPILE_COMMAND"
|
|
|
|
- >
|
|
for package in $CI_SDK_BUILD_PACKAGES; do
|
|
make V=sc package/$package/{download,check} FIXUP=1
|
|
done 2>&1 | tee --append logs/build.log
|
|
|
|
- >
|
|
topdir=$(pwd);
|
|
for feed in $(find feeds -follow -name .git); do
|
|
pushd $(dirname $feed) > /dev/null; git diff-index --exit-code HEAD || {
|
|
ret=$?
|
|
echo "Feed $(dirname $feed) packages integrity issues, please check feed-packages-hash-issues.patch from artifacts"
|
|
git diff | tee $topdir/feed-packages-hash-issues.patch
|
|
exit $ret
|
|
}
|
|
popd > /dev/null
|
|
done
|
|
|
|
- >
|
|
for package in $CI_SDK_BUILD_PACKAGES; do
|
|
make -j ${CI_SDK_BUILD_PARALLEL:-$(nproc)} package/$package/compile
|
|
done 2>&1 | tee --append logs/build.log
|
|
|
|
after_script:
|
|
- cp -R "$CI_SDK_TOPDIR/logs" "$CI_SDK_TOPDIR/bin" $CI_PROJECT_DIR || true
|
|
- >
|
|
if grep -qr 'make\[[[:digit:]]\].*Error [[:digit:]]$' logs; then
|
|
printf "\n====== Showing Make errors found in the log files ======";
|
|
for file in $(grep -lr 'make\[[[:digit:]]\].*Error [[:digit:]]$' logs); do
|
|
printf "\n====== Make errors from $CI_JOB_URL/artifacts/file/$file ======\n" ;
|
|
grep -r -C5 'make\[[[:digit:]]\].*Error [[:digit:]]$' $file ;
|
|
done
|
|
fi
|
|
|
|
artifacts:
|
|
expire_in: 1 month
|
|
when: always
|
|
paths:
|
|
- logs/
|
|
- ./feed-packages-hash-issues.patch
|
|
|
|
.generate SDK package build jobs:
|
|
stage: generate
|
|
image: alpine
|
|
|
|
variables:
|
|
CI_SDK_BUILD_PACKAGES: |
|
|
please-provide
|
|
CI_SDK_PACKAGE_JOBS_TEMPLATE: |
|
|
{% if env['CI_SDK_PIPELINE_SOURCE'] %}
|
|
workflow:
|
|
rules:
|
|
- if: $$CI_PIPELINE_SOURCE == "{{ env['CI_SDK_PIPELINE_SOURCE'] }}"
|
|
{% endif %}
|
|
include:
|
|
- remote: https://gitlab.com/prpl-foundation/prplos/prplos/-/raw/$CI_DESIGNATED_BRANCH/.gitlab/sdk.yml
|
|
{% for sdk in env['CI_SDK_TARGETS'].rstrip().split("\n") %}
|
|
{% for package in env['CI_SDK_BUILD_PACKAGES'].rstrip().split("\n") %}
|
|
build {{ package | trim }} with {{ sdk | trim }} SDK:
|
|
extends: .build feed with {{ sdk | trim }} SDK
|
|
variables:
|
|
CI_SDK_BUILD_PACKAGES: {{ package | trim }}
|
|
CI_SDK_BUILD_CONFIG_EXTRA: +PACKAGE_{{ package | trim }}
|
|
{% endfor %}
|
|
{% endfor %}
|
|
|
|
before_script:
|
|
- apk add py3-jinja2
|
|
|
|
script:
|
|
- |
|
|
echo "$CI_SDK_PACKAGE_JOBS_TEMPLATE" | python3 -c '
|
|
import os
|
|
import sys
|
|
import jinja2
|
|
sys.stdout.write(
|
|
jinja2.Template(sys.stdin.read()
|
|
).render(env=os.environ))' > sdk-package-jobs.yml
|
|
- cat sdk-package-jobs.yml
|
|
|
|
artifacts:
|
|
paths:
|
|
- sdk-package-jobs.yml
|
|
|
|
.execute SDK package build jobs:
|
|
stage: build
|
|
needs:
|
|
- generate
|
|
|
|
trigger:
|
|
include:
|
|
- artifact: sdk-package-jobs.yml
|
|
job: generate
|
|
strategy: depend
|
|
|
|
.build feed with OpenWrt SDK:
|
|
extends: .build feed with SDK
|
|
variables:
|
|
CI_SDK_BEFORE_COMPILE_COMMAND: sudo apt-get update; sudo apt-get install -y python-yaml python3-yaml
|
|
CI_SDK_TOPDIR: /home/build/openwrt
|
|
|
|
.build feed with intel_mips-xrx500 SDK:
|
|
extends: .build feed with SDK
|
|
variables:
|
|
CI_SDK_IMAGE: registry.gitlab.com/prpl-foundation/prplos/prplos/$CI_DESIGNATED_BRANCH_SLUG/sdk-intel_mips-xrx500:latest
|
|
CI_SDK_INSTALL_FEEDS: base packages luci routing feed_intel
|
|
|
|
.build feed with ipq40xx-generic SDK:
|
|
extends: .build feed with SDK
|
|
variables:
|
|
CI_SDK_IMAGE: registry.gitlab.com/prpl-foundation/prplos/prplos/$CI_DESIGNATED_BRANCH_SLUG/sdk-ipq40xx-generic:latest
|
|
|
|
.build feed with mvebu-cortexa9 SDK:
|
|
extends: .build feed with SDK
|
|
variables:
|
|
CI_SDK_IMAGE: registry.gitlab.com/prpl-foundation/prplos/prplos/$CI_DESIGNATED_BRANCH_SLUG/sdk-mvebu-cortexa9:latest
|
|
|
|
.build feed with x86-64 SDK:
|
|
extends: .build feed with SDK
|
|
variables:
|
|
CI_SDK_IMAGE: registry.gitlab.com/prpl-foundation/prplos/prplos/$CI_DESIGNATED_BRANCH_SLUG/sdk-x86-64:latest
|
|
|
|
.build feed with qualcommax-ipq807x SDK:
|
|
extends: .build feed with SDK
|
|
variables:
|
|
CI_SDK_IMAGE: registry.gitlab.com/prpl-foundation/prplos/prplos/$CI_DESIGNATED_BRANCH_SLUG/sdk-qualcommax-ipq807x:latest
|
|
|
|
.build feed with qca_ipq95xx-generic SDK:
|
|
extends: .build feed with SDK
|
|
variables:
|
|
CI_SDK_IMAGE: registry.gitlab.com/prpl-foundation/prplos/prplos/$CI_DESIGNATED_BRANCH_SLUG/sdk-qca_ipq95xx-generic:latest
|
|
|
|
.build feed with ath79-generic-19.07.7 SDK:
|
|
extends: .build feed with OpenWrt SDK
|
|
variables:
|
|
CI_SDK_IMAGE: openwrtorg/sdk:ath79-generic-19.07.7
|
|
|
|
.build feed with x86-64-prplos-next SDK:
|
|
extends: .build feed with SDK
|
|
variables:
|
|
CI_SDK_IMAGE: registry.gitlab.com/prpl-foundation/prplos/prplos/prplos-next/sdk-x86-64:latest
|
|
|
|
.build feed with qualcommax-ipq807x-prplos-next SDK:
|
|
extends: .build feed with SDK
|
|
variables:
|
|
CI_SDK_IMAGE: registry.gitlab.com/prpl-foundation/prplos/prplos/prplos-next/sdk-qualcommax-ipq807x:latest
|
|
|
|
.build feed with qca_ipq95xx-generic-prplos-next SDK:
|
|
extends: .build feed with SDK
|
|
variables:
|
|
CI_SDK_IMAGE: registry.gitlab.com/prpl-foundation/prplos/prplos/prplos-next/sdk-qca_ipq95xx-generic:latest
|
|
|
|
.build feed with mvebu-cortexa9-prplos-next SDK:
|
|
extends: .build feed with SDK
|
|
variables:
|
|
CI_SDK_IMAGE: registry.gitlab.com/prpl-foundation/prplos/prplos/prplos-next/sdk-mvebu-cortexa9:latest
|