8 changed files with 134 additions and 25 deletions
@ -1,5 +1,5 @@ |
|||
jenkins-debian-glue-buildenv-devuan (1.0) unstable; urgency=medium |
|||
jenkins-buildenv-devuan (1.0) unstable; urgency=medium |
|||
|
|||
* Split out from src:jenkins-debian-glue. |
|||
|
|||
-- Mark Hindley <mark@hindley.org.uk> Sat, 03 Jul 2021 17:58:22 +0100 |
|||
-- Mark Hindley <mark@hindley.org.uk> Tue, 08 Feb 2022 12:30:03 +0000 |
|||
|
@ -1,22 +1,25 @@ |
|||
Source: jenkins-debian-glue-buildenv-devuan |
|||
Source: jenkins-buildenv-devuan |
|||
Section: devel |
|||
Priority: optional |
|||
Maintainer: Mark Hindley <mark@hindley.org.uk> |
|||
Standards-Version: 4.5.1 |
|||
Vcs-Git: https://git.devuan.org/devuan/jenkins-debian-glue-buildenv-devuan.git |
|||
Vcs-Browser: https://git.devuan.org/devuan/jenkins-debian-glue-buildenv-devuan |
|||
Vcs-Git: https://git.devuan.org/devuan/jenkins-buildenv-devuan.git |
|||
Vcs-Browser: https://git.devuan.org/devuan/jenkins-buildenv-devuan |
|||
Origin: Devuan |
|||
Build-Depends: |
|||
debhelper-compat (= 13), |
|||
|
|||
Package: jenkins-debian-glue-buildenv-devuan |
|||
Package: jenkins-buildenv-devuan |
|||
Architecture: all |
|||
Depends: sudo, |
|||
jenkins-debian-glue-buildenv, |
|||
default-jre-headless, |
|||
openssh-client, |
|||
Depends: cowbuilder, |
|||
default-jre-headless, |
|||
openssh-client, |
|||
sudo, |
|||
${misc:Depends} |
|||
Conflicts: jenkins-debian-glue-buildenv-devuan |
|||
Provides: jenkins-debian-glue-buildenv-devuan |
|||
Replaces: jenkins-debian-glue-buildenv-devuan |
|||
Recommends: devuan-lintian-profile |
|||
Description: Devuan GNU/Linux support for jenkins debian glue |
|||
This package provides Devuan specific additional files |
|||
used for building Devuan packages in jenkins. |
|||
Description: Setup jenkins builder for Devuan |
|||
This package provides dependencies and Devuan specific files |
|||
for setting up a Devuan infrastructure binary builder for jenkins. |
|||
|
@ -0,0 +1,2 @@ |
|||
devuan/pbuilder-hookdir/ usr/share/jenkins-buildenv-devuan/ |
|||
devuan/sudoers/jenkins etc/sudoers.d/ |
@ -0,0 +1 @@ |
|||
/usr/share/jenkins-buildenv-devuan /usr/share/jenkins-debian-glue |
@ -1,2 +0,0 @@ |
|||
/devuan/pbuilderrc etc/jenkins/ |
|||
/devuan/sudoers/jenkins etc/sudoers.d/ |
@ -0,0 +1,108 @@ |
|||
#!/bin/sh |
|||
# Copyright 2013 Michael Prokop <mika@debian.org> |
|||
# Copyright 2012 Christoph Berg <myon@debian.org> |
|||
# Licensed under the terms of the MIT License. |
|||
|
|||
if [ "${ADT:-}" = "skip" ]; then |
|||
echo "Skipping autopkgtests as requested (ADT is set to 'skip')" |
|||
exit 0 |
|||
fi |
|||
|
|||
if [ "${ADT:-}" = "external" ]; then |
|||
echo "Skipping internal autopkgtests as external testing was requested via ADT variable" |
|||
exit 0 |
|||
fi |
|||
|
|||
set -ex |
|||
|
|||
cd /tmp/buildd/*/debian/.. |
|||
|
|||
if [ ! -f debian/tests/control ]; then |
|||
echo "Package does not have autopkgtest support, debian/tests/control is missing" |
|||
exit 0 |
|||
fi |
|||
|
|||
if [ ! -f debian/files ]; then |
|||
echo "Package source is not built, debian/files is missing" >&2 |
|||
exit 1 |
|||
fi |
|||
|
|||
if [ -n "${ADT_OPTIONS:-}" ] ; then |
|||
echo "*** Using provided ADT_OPTIONS $ADT_OPTIONS ***" |
|||
fi |
|||
|
|||
# try to launch autopkgtest in a new PID namespace so several testsuites can run |
|||
# in parallel, newpid exists in jessie and newer only though |
|||
unset newpid_name |
|||
if ! apt-cache policy newpid | grep -q 'newpid:' ; then |
|||
echo "The newpid package doesn't seem to be available, not considering for installation" |
|||
else |
|||
echo "The newpid package seems to be available, considering for installation" |
|||
newpid_name='newpid' |
|||
fi |
|||
|
|||
# autopkgtest uses apt-utils's apt-ftparchive and |
|||
# pbuilder's pbuilder-satisfydepends-classic |
|||
apt-get install -y autopkgtest apt-utils pbuilder $newpid_name |
|||
|
|||
case ${NEWPID_OPTS:-} in |
|||
--suppress|--false) |
|||
echo "Suppressing use of newpid!" |
|||
$newpid_name="" |
|||
;; |
|||
*) |
|||
newpid_name="$newpid_name $NEWPID_OPTS" |
|||
;; |
|||
esac |
|||
|
|||
if [ -x /usr/bin/autopkgtest ]; then |
|||
# starting with autopkgtest 5.0 there's only the dedicated autopkgtest CLI |
|||
AUTOPKG_BINARY=autopkgtest |
|||
elif [ -x /usr/bin/adt-run ] ; then |
|||
# autopkgtest as in Debian/jessie (v3.6jessie1) and older doesn't provide |
|||
# autopkgtest binary yet, but let's be backwards compatible |
|||
AUTOPKG_BINARY=adt-run |
|||
else |
|||
echo "Error: neither autopkgtest nor adt-run binary found." >&2 |
|||
exit 1 |
|||
fi |
|||
|
|||
# since autopkgtest 3.16 the --tmp-dir option is gone, make sure |
|||
# we've --output-dir available though before using it |
|||
if "$AUTOPKG_BINARY" --help | grep -q -- --output-dir 2>/dev/null ; then |
|||
OUTPUT_OPTION='--output-dir' |
|||
else |
|||
OUTPUT_OPTION='--tmp-dir' |
|||
fi |
|||
|
|||
mkdir -p /tmp/buildd/autopkgtest.out |
|||
|
|||
if [ -x /usr/bin/autopkgtest ]; then |
|||
# new autopkgtest interface |
|||
$newpid_name "$AUTOPKG_BINARY" \ |
|||
${OUTPUT_OPTION} /tmp/buildd/autopkgtest.out \ |
|||
--summary /tmp/buildd/autopkgtest.summary \ |
|||
"${PWD}" \ |
|||
/tmp/buildd/*.deb \ |
|||
${ADT_OPTIONS:-} -- null || EXIT=$? |
|||
else |
|||
# old adt interface |
|||
$newpid_name "$AUTOPKG_BINARY" \ |
|||
${OUTPUT_OPTION} /tmp/buildd/autopkgtest.out \ |
|||
--summary /tmp/buildd/autopkgtest.summary \ |
|||
/tmp/buildd/*.deb \ |
|||
--built-tree "${PWD}" \ |
|||
${ADT_OPTIONS:-} --- adt-virt-null || EXIT=$? |
|||
fi |
|||
|
|||
# collect autopkgtest output in a single file so pbuilder automatically copies it |
|||
tar acf /tmp/buildd/autopkgtest.tar.gz /tmp/buildd/autopkgtest.out |
|||
|
|||
case ${EXIT:-0} in |
|||
2|4|6|8) # let adtsummary_tap report the failure |
|||
exit 0 |
|||
;; |
|||
*) |
|||
exit ${EXIT:-0} |
|||
;; |
|||
esac |
@ -0,0 +1,7 @@ |
|||
#!/bin/sh |
|||
# Don't rebuild man-db |
|||
|
|||
echo "I: Preseed man-db/auto-update to false" |
|||
debconf-set-selections <<EOF |
|||
man-db man-db/auto-update boolean false |
|||
EOF |
@ -1,10 +0,0 @@ |
|||
MIRRORSITE="http://pkgmaster.devuan.org/merged/" |
|||
COMPONENTS="main contrib non-free" |
|||
DEBOOTSTRAPOPTS=("${DEBOOTSTRAPOPTS[@]}" "--keyring=/usr/share/keyrings/devuan-keyring.gpg" "--no-merged-usr") |
|||
PBUILDERSATISFYDEPENDSCMD=/usr/lib/pbuilder/pbuilder-satisfydepends-apt |
|||
EXTRAPACKAGES="$EXTRAPACKAGES devuan-keyring" |
|||
AUTOCLEANAPTCACHE=yes |
|||
|
|||
if [[ $ARCH == arm* ]] ; then |
|||
ADT=skip |
|||
fi |
Loading…
Reference in new issue