diff options
-rwxr-xr-x | packages/linux-kernel/build-intel-qat.sh | 22 | ||||
-rwxr-xr-x | packages/linux-kernel/build-linux-firmware.sh | 20 | ||||
-rw-r--r-- | packages/linux-kernel/vyos-intel-qat.postinst | 2 |
3 files changed, 14 insertions, 30 deletions
diff --git a/packages/linux-kernel/build-intel-qat.sh b/packages/linux-kernel/build-intel-qat.sh index 3313abbe..bf431b04 100755 --- a/packages/linux-kernel/build-intel-qat.sh +++ b/packages/linux-kernel/build-intel-qat.sh @@ -74,25 +74,15 @@ do chmod 644 ${DEBIAN_DIR}/lib/firmware/* chmod 755 ${DEBIAN_DIR}/etc/init.d/* ${DEBIAN_DIR}/usr/local/bin/* - mkdir -p $(dirname "${DEBIAN_CONTROL}") - cat << EOF >${DEBIAN_CONTROL} -Package: vyos-intel-${DRIVER_NAME} -Version: ${DRIVER_VERSION}${DRIVER_VERSION_EXTRA} -Section: kernel -Priority: extra -Architecture: ${DEBIAN_ARCH} -Maintainer: VyOS Package Maintainers <maintainers@vyos.net> -Description: Vendor based driver for Intel ${DRIVER_NAME} -Depends: linux-image-${KERNEL_VERSION}${KERNEL_SUFFIX} -EOF - + # build Debian package + echo "I: Building Debian package vyos-intel-${DRIVER_NAME}" # delete non required files which are also present in the kernel package # und thus lead to duplicated files find ${DEBIAN_DIR} -name "modules.*" | xargs rm -f - - # build Debian package - echo "I: Building Debian package vyos-intel-${DRIVER_NAME}" - fakeroot dpkg-deb --build ${DEBIAN_DIR} + cd ${CWD} + fpm --input-type dir --output-type deb --name vyos-intel-${DRIVER_NAME} \ + --version ${DRIVER_VERSION}${DRIVER_VERSION_EXTRA} --deb-compression gz \ + -C ${DEBIAN_DIR} --after-install ${CWD}/vyos-intel-qat.postinst echo "I: Cleanup ${DRIVER_NAME} source" cd ${CWD} diff --git a/packages/linux-kernel/build-linux-firmware.sh b/packages/linux-kernel/build-linux-firmware.sh index 37a3768a..aca88907 100755 --- a/packages/linux-kernel/build-linux-firmware.sh +++ b/packages/linux-kernel/build-linux-firmware.sh @@ -68,20 +68,12 @@ do FW_DIR="${VYOS_FIRMWARE_DIR}/lib/firmware/$(dirname ${FW})" mkdir -p ${FW_DIR} echo "I: install firmware: ${FW}" - cp ${CWD}/linux-firmware/${FW} ${FW_DIR} + cp ${CWD}/linux-firmware/${FW} ${FW_DIR} done -# Describe Debian package -mkdir ${VYOS_FIRMWARE_DIR}/DEBIAN -cat << EOF >${VYOS_FIRMWARE_DIR}/DEBIAN/control -Package: ${VYOS_FIRMWARE_NAME} -Version: ${GIT_COMMIT} -Section: kernel -Priority: extra -Architecture: all -Maintainer: VyOS Package Maintainers <maintainers@vyos.net> -Description: Firmware blobs for use with the Linux kernel -EOF +echo "I: Create linux-firmware package" +cd ${CWD} +fpm --input-type dir --output-type deb --name ${VYOS_FIRMWARE_NAME} \ + --version ${GIT_COMMIT} --deb-compression xz -C ${VYOS_FIRMWARE_DIR} -# Build Debian package -fakeroot dpkg-deb --build ${VYOS_FIRMWARE_DIR} +rm -rf ${VYOS_FIRMWARE_DIR} diff --git a/packages/linux-kernel/vyos-intel-qat.postinst b/packages/linux-kernel/vyos-intel-qat.postinst new file mode 100644 index 00000000..35d5de0c --- /dev/null +++ b/packages/linux-kernel/vyos-intel-qat.postinst @@ -0,0 +1,2 @@ +#!/bin/sh +depmod -a |