- job: name: 96boards-reference-kernel project-type: freestyle defaults: global logrotate: daysToKeep: 60 numToKeep: 60 properties: - authorization: anonymous: - job-read - job-extended-read - job-workspace linaro: - job-read - job-extended-read - job-build - job-cancel parameters: - string: name: KERNEL_GIT_BRANCH default: '96b-kernelci' - string: name: KERNEL_GIT_URL default: 'https://git.linaro.org/people/amit.kucheria/kernel.git' - string: name: TARGET_REPO default: 'linaro-staging' disabled: true node: docker-jessie-amd64 display-name: 'Reference Platform - Linux Kernel' wrappers: - timestamps - build-name: name: '#${BUILD_NUMBER}' builders: - linaro-publish-token: host: builds.96boards.org - shell: | #!/bin/bash set -ex sudo apt-get update sudo apt-get install -y ccache python-pycurl quilt cpio rsync rpm # Checkout source code git clone -b ${KERNEL_GIT_BRANCH} ${KERNEL_GIT_URL} linux git clone --depth 1 https://git.linaro.org/ci/debian-kernel-packaging.git debian-pkg # Export the kernel packaging version cd linux ## To use when we switch to 4.5, since -rc is higher than the final tag # kernel_version=`make kernelversion | sed -e 's/\.0-rc/~rc/' kernel_version=`make kernelversion` export KERNEL_GIT_VERSION=`git log --format="%H" -1` export KDEB_PKGVERSION="${kernel_version}.linaro.${BUILD_NUMBER}-1" git tag v${kernel_version} cd .. # Build the debian source kernel cd debian-pkg # Allow our own versioning scheme sed -i 's/dfsg/linaro/g' debian/bin/genorig.py debian/lib/python/debian_linux/debian.py # Use build number as ABI sed -i "s/^abiname:.*/abiname: ${BUILD_NUMBER}/g" debian/config/defines cat << EOF > debian/changelog linux ($KDEB_PKGVERSION) jessie; urgency=medium * Auto build: - URL: ${KERNEL_GIT_URL} - Branch: ${KERNEL_GIT_BRANCH} - Hash: ${KERNEL_GIT_VERSION} -- Ricardo Salveti de Araujo `date "+%a, %d %b %Y %T %z"` EOF # Use the kernel config from the kernel tree cp ../linux/arch/arm64/configs/distro.config debian/config/arm64/config debian/rules clean || true debian/bin/genorig.py ../linux debian/rules orig fakeroot debian/rules source debuild -S -uc -us cd .. cat > ${WORKSPACE}/build-package-params < ${WORKSPACE}/build-kernel-rpm-params < MD5SUMS.txt) # Build information cat > out/HEADER.textile << EOF h4. Reference Platform - Linux Kernel Linux Kernel build consumed by the Reference Platform Builds Build Description: * Build URL: "$BUILD_URL":$BUILD_URL * Git tree: "$KERNEL_GIT_URL":$KERNEL_GIT_URL * Git branch: $KERNEL_GIT_BRANCH * Git hash: $KERNEL_GIT_VERSION * Kernel version: $kernel_version * Kernel deb version: $KDEB_PKGVERSION * Kernel rpm version: ${rpmversion}-reference.${BUILD_NUMBER} EOF # Publish test -d ${HOME}/bin || mkdir ${HOME}/bin wget -q https://git.linaro.org/ci/publishing-api.git/blob_plain/HEAD:/linaro-cp.py -O ${HOME}/bin/linaro-cp.py time python ${HOME}/bin/linaro-cp.py \ --server ${PUBLISH_SERVER} \ --link-latest \ out snapshots/reference-platform/components/linux/common/${BUILD_NUMBER}/ publishers: - archive: artifacts: '*.dsc, *.xz, *.src.rpm' - trigger-parameterized-builds: - project: build-package property-file: build-package-params condition: SUCCESS - project: build-kernel-rpm property-file: build-kernel-rpm-params condition: SUCCESS - email: recipients: 'fathi.boudra@linaro.org ricardo.salveti@linaro.org'