osmith has uploaded this change for review.

View Change

contrib/jenkins.sh: new file

Related: OS#5407
Change-Id: I904ab66a1ecd72492642ac2cc4cb102c7283c590
---
A contrib/jenkins.sh
1 file changed, 29 insertions(+), 0 deletions(-)

git pull ssh://gerrit.osmocom.org:29418/dahdi-linux refs/changes/59/27059/1
diff --git a/contrib/jenkins.sh b/contrib/jenkins.sh
new file mode 100755
index 0000000..666a014
--- /dev/null
+++ b/contrib/jenkins.sh
@@ -0,0 +1,29 @@
+#!/bin/sh -ex
+
+DEFCONFIG="${DEFCONFIG:-x86_64_defconfig}"
+TOPDIR="$(realpath "$(dirname "$(realpath "$0")")/..")"
+KSRC="${KSRC:-$TOPDIR/../linux}"
+JOBS="${JOBS:-9}"
+
+if ! [ -d "$KSRC" ]; then
+ set +x
+ echo "ERROR: KSRC does not exist: $KSRC"
+ echo "Let the KSRC env var point at a linux source tree and try again."
+ exit 1
+fi
+
+if ! [ -e "$KSRC/.config" ]; then
+ make -C "$KSRC" "$DEFCONFIG"
+fi
+
+if [ "$KSRC/arch/x86/configs/$DEFCONFIG" -nt "$KSRC/.config" ]; then
+ set +x
+ echo "ERROR: .config inside kernel source tree is older than $DEFCONFIG"
+ echo "Move/delete/touch .config and try again."
+ exit 1
+fi
+
+git -C "$KSRC" log -1 --pretty="%t - %s"
+
+make -j "$JOBS" -C "$KSRC" modules_prepare
+make -j "$JOBS" -C "$TOPDIR" KSRC="$KSRC"

To view, visit change 27059. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: dahdi-linux
Gerrit-Branch: master
Gerrit-Change-Id: I904ab66a1ecd72492642ac2cc4cb102c7283c590
Gerrit-Change-Number: 27059
Gerrit-PatchSet: 1
Gerrit-Owner: osmith <osmith@sysmocom.de>
Gerrit-MessageType: newchange