From 9a4f58582e737b38212de6d53d95fbeaf0813cb4 Mon Sep 17 00:00:00 2001 From: Josip Ponjavic Date: Thu, 9 Jan 2020 22:54:02 +0100 Subject: [PATCH] 5.4.10-2 (clr 5.4.8-886) add option to reuse custom config --- .SRCINFO | 2 +- PKGBUILD | 28 +++++++++++++++++++++++++--- 2 files changed, 26 insertions(+), 4 deletions(-) diff --git a/.SRCINFO b/.SRCINFO index 14f5741..f2e3a1d 100644 --- a/.SRCINFO +++ b/.SRCINFO @@ -1,7 +1,7 @@ pkgbase = linux-clear pkgdesc = Clear Linux pkgver = 5.4.10 - pkgrel = 1 + pkgrel = 2 url = https://github.com/clearlinux-pkgs/linux arch = x86_64 license = GPL2 diff --git a/PKGBUILD b/PKGBUILD index a1941be..02a3cc1 100644 --- a/PKGBUILD +++ b/PKGBUILD @@ -56,6 +56,13 @@ _subarch=31 # More at this wiki page ---> https://wiki.archlinux.org/index.php/Modprobed-db _localmodcfg= +# Use the current kernel's .config file +# Enabling this option will use the .config of the RUNNING kernel rather than +# the ARCH defaults. Useful when the package gets updated and you already went +# through the trouble of customizing your config options. NOT recommended when +# a new kernel is released, but again, convenient for package bumps. +_use_current= + ### IMPORTANT: Do no edit below this line unless you know what you're doing _major=5.4 @@ -64,7 +71,7 @@ _srcname=linux-${_major} _clr=${_major}.8-886 pkgbase=linux-clear pkgver=${_major}.${_minor} -pkgrel=1 +pkgrel=2 pkgdesc='Clear Linux' arch=('x86_64') url="https://github.com/clearlinux-pkgs/linux" @@ -130,7 +137,7 @@ prepare() { msg2 "Enable extra stuff from arch kernel..." # General setup - scripts/config --module IKCONFIG \ + scripts/config --enable IKCONFIG \ --enable-after IKCONFIG IKCONFIG_PROC \ --undefine RT_GROUP_SCHED @@ -188,6 +195,21 @@ prepare() { make -s kernelrelease > version msg2 "Prepared %s version %s" "$pkgbase" "$( ./.config + else + warning "Your kernel was not compiled with IKCONFIG_PROC!" + warning "You cannot read the current config!" + warning "Aborting!" + exit + fi + fi + ### Optionally load needed modules for the make localmodconfig # See https://aur.archlinux.org/packages/modprobed-db if [ -n "$_localmodcfg" ]; then @@ -214,7 +236,7 @@ prepare() { build() { cd ${_srcname} - make bzImage modules + make -j$(nproc) bzImage modules } _package() {