# SliTaz package receipt. PACKAGE="linux-module-headers" VERSION="4.19.294" CATEGORY="development" SHORT_DESC="Header files and scripts for building modules for linux kernel." MAINTAINER="devel@slitaz.org" LICENSE="GPL2" DEPENDS="slitaz-toolchain xz" WANTED="linux" WEB_SITE="https://kernel.org/" KVERSION=$VERSION-slitaz # Rules to gen a SliTaz package suitable for Tazpkg. genpkg_rules() { mkdir -p $fs/lib/modules/$KVERSION $fs/usr cp -a $install/usr/src $fs/usr [ -e $fs/usr/src/linux-$VERSION-slitaz/include/linux/version.h ] || ln -s ../generated/uapi/linux/version.h \ $fs/usr/src/linux-$VERSION-slitaz/include/linux/version.h } pre_remove() { if [ -e "$1/usr/src/linux" ]; then rm -rf "$1/usr/src/linux" fi } post_install() { # Added soft link to make it easier to point to kernel folder [ -L "$1/usr/src/linux" ] && rm -f "$1/usr/src/linux" ln -sf /usr/src/linux-$KVERSION "$1/usr/src/linux" ln -sf /usr/src/linux-$KVERSION "$1/lib/modules/$KVERSION/build" }