summaryrefslogtreecommitdiff
path: root/packages/sys-kernel/linux-sources-redcore-lts/linux-sources-redcore-lts-4.14.65.exheres-0
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2018-10-17 14:39:55 +0100
committerV3n3RiX <venerix@redcorelinux.org>2018-10-17 14:39:55 +0100
commitc0af92af4b125614c9850b61159c85af95d4dddc (patch)
treef1f299ec0e2762027807d23cbf25d1e3991dfa9a /packages/sys-kernel/linux-sources-redcore-lts/linux-sources-redcore-lts-4.14.65.exheres-0
parentf92beebe2a93c7bdda44e25ef955b8a609f9250b (diff)
sys-kernel/linux-sources-redcore-lts : initial exheres, add it as a dep for sys-kernel/linux-image-redcore-lts
Diffstat (limited to 'packages/sys-kernel/linux-sources-redcore-lts/linux-sources-redcore-lts-4.14.65.exheres-0')
-rw-r--r--packages/sys-kernel/linux-sources-redcore-lts/linux-sources-redcore-lts-4.14.65.exheres-095
1 files changed, 95 insertions, 0 deletions
diff --git a/packages/sys-kernel/linux-sources-redcore-lts/linux-sources-redcore-lts-4.14.65.exheres-0 b/packages/sys-kernel/linux-sources-redcore-lts/linux-sources-redcore-lts-4.14.65.exheres-0
new file mode 100644
index 0000000..d085454
--- /dev/null
+++ b/packages/sys-kernel/linux-sources-redcore-lts/linux-sources-redcore-lts-4.14.65.exheres-0
@@ -0,0 +1,95 @@
+# Copyright 2018 Redcore Linux Project
+# Distributed under the terms of the GNU General Public License v2
+
+SUMMARY="Redcore Linux Project LTS Kernel Sources"
+DESCRIPTION="Redcore Linux Project LTS Kernel Sources"
+HOMEPAGE="https://redcorelinux.org"
+
+DOWNLOADS="https://cdn.kernel.org/pub/linux/kernel/v4.x/linux-${PV}.tar.xz"
+
+LICENCES="GPL-2"
+SLOT="${PV}"
+PLATFORMS="~amd64"
+
+EXTRAVERSION="redcore-lts"
+KV_FULL=""${PV}"-"${EXTRAVERSION}""
+
+MYOPTIONS=""
+
+DEPENDENCIES="
+ build:
+ app-arch/xz
+ sys-apps/bc
+ sys-devel/make
+"
+
+DEFAULT_SRC_PREPARE_PATCHES=(
+ "${FILES}"/introduce-NUMA-identity-node-sched-domain.patch
+ "${FILES}"/k10temp-add-ZEN-support.patch
+ "${FILES}"/mute-pps_state_mismatch.patch
+ "${FILES}"/restore-SD_PREFER_SIBLING-on-MC-domains.patch
+ "${FILES}"/Revert-ath10k-activate-user-space-firmware-loading.patch
+ "${FILES}"/linux-hardened.patch
+ "${FILES}"/uksm-for-linux-hardened.patch
+ "${FILES}"/0015-Enable-BFQ-io-scheduler-by-default.patch
+ # allow kernel to be built via exheres
+ "${FILES}"/linux-pkg-config.patch
+ "${FILES}"/linux-objtool-dont-hardcore-ar.patch
+)
+
+WORK="${WORKBASE}"/linux-"${PV}"
+
+pkg_setup() {
+ export KBUILD_BUILD_USER="nexus"
+ export KBUILD_BUILD_HOST="nexus.redcorelinux.org"
+
+ export REAL_ARCH="$ARCH"
+ unset ARCH ; unset LDFLAGS #will interfere with Makefile if set
+}
+
+src_prepare() {
+ default
+
+ src_prepare_params=(
+ CC="${CC}"
+ HOSTCC="${CC}"
+ )
+
+ edo emake \
+ "${src_prepare_params[@]}" \
+ mrproper
+
+ edo sed -ri "s|^(EXTRAVERSION =).*|\1 -${EXTRAVERSION}|" Makefile
+ edo cp "${FILES}"/"${EXTRAVERSION}"-amd64.config .config
+}
+
+src_compile() {
+ src_compile_params=(
+ AR="${AR}"
+ AS="${AS}"
+ CC="${CC}"
+ HOSTCC="${CC}"
+ HOSTLD="${LD}"
+ LD="${LD}"
+ NM="${NM}"
+ OBJCOPY="${OBJCOPY}"
+ OBJDUMP="${OBJDUMP}"
+ )
+
+ edo emake \
+ "${src_compile_params[@]}" \
+ prepare modules_prepare
+}
+
+src_install() {
+ dodir /usr/src/linux-"${KV_FULL}"
+ edo cp -ax "${WORK}"/* "${IMAGE}"usr/src/linux-"${KV_FULL}"
+}
+
+_kernel_sources_delete() {
+ rm -rf "${ROOT}"usr/src/linux-"${KV_FULL}"
+}
+
+pkg_postrm() {
+ _kernel_sources_delete
+}