summaryrefslogtreecommitdiff
path: root/packages/linux-kernel/build-accel-ppp.sh
diff options
context:
space:
mode:
authorChristian Poessinger <christian@poessinger.com>2020-06-24 20:16:04 +0200
committerChristian Poessinger <christian@poessinger.com>2020-06-24 21:04:17 +0200
commitc1abd123989f82feca0223bbb462bce3a62fc618 (patch)
tree07762da1874f97c4bf8cb0b04398c649889847dd /packages/linux-kernel/build-accel-ppp.sh
parent488ebdf6ca0de558dbbadcab1342f7625aa3a588 (diff)
downloadvyos-build-c1abd123989f82feca0223bbb462bce3a62fc618.tar.gz
vyos-build-c1abd123989f82feca0223bbb462bce3a62fc618.zip
Jenkins: T2625: import Kernel Pipeline
Imported from https://github.com/vyos/vyos-build-kernel commit 9e7c12b
Diffstat (limited to 'packages/linux-kernel/build-accel-ppp.sh')
-rwxr-xr-xpackages/linux-kernel/build-accel-ppp.sh33
1 files changed, 33 insertions, 0 deletions
diff --git a/packages/linux-kernel/build-accel-ppp.sh b/packages/linux-kernel/build-accel-ppp.sh
new file mode 100755
index 00000000..a434bb16
--- /dev/null
+++ b/packages/linux-kernel/build-accel-ppp.sh
@@ -0,0 +1,33 @@
+#!/bin/sh
+CWD=$(pwd)
+KERNEL_VAR_FILE=${CWD}/kernel-vars
+
+ACCEL_SRC=${CWD}/accel-ppp
+if [ ! -d ${ACCEL_SRC} ]; then
+ echo "Accel-PPP source not found"
+ exit 1
+fi
+
+if [ ! -f ${KERNEL_VAR_FILE} ]; then
+ echo "Kernel variable file '${KERNEL_VAR_FILE}' does not exist, run ./build_kernel.sh first"
+ exit 1
+fi
+
+. ${KERNEL_VAR_FILE}
+mkdir -p ${ACCEL_SRC}/build
+cd ${ACCEL_SRC}/build
+
+echo "I: Build Accel-PPP Debian package"
+cmake -DBUILD_IPOE_DRIVER=TRUE \
+ -DBUILD_VLAN_MON_DRIVER=TRUE \
+ -DCMAKE_INSTALL_PREFIX=/usr \
+ -DKDIR=${KERNEL_DIR} \
+ -DLUA=TRUE \
+ -DLUA=5.3 \
+ -DMODULES_KDIR=${KERNEL_VERSION}${KERNEL_SUFFIX} \
+ -DCPACK_TYPE=Debian10 ..
+make
+cpack -G DEB
+
+# rename resulting Debian package according git description
+mv accel-ppp*.deb ${CWD}/accel-ppp_$(git describe --always --tags)_$(dpkg --print-architecture).deb