DIST pf-sources-5.3_p3.patch 980797 BLAKE2B 96bd53791737fcb1d1503b719a8654a90bd9045ab678289fb457992725b40c6ddd86d4970dc462a3b707de7fc38ecd55b95f0191941fc79777f2b17ba22a9cc8 SHA512 d3bb38efa4174494a6669b77805207d6af1d6b00ff1d887f8f4d3b0f4682548e347ce96e0c1841d4a4f81f0721327b4f2c8d7b169f3b0850a895f1dac2b3d4c3
DIST pf-sources-5.3_p4.patch 1340441 BLAKE2B fe979e8511d6bfa481749e50d8f4f2edc8016477de4edc644cd57015b0568c9948e7643871642ce67a5a9250294e3981951b87a3f60161ceec6232c206031349 SHA512 879991193cd6fd77f17f5fafbfd6172528837c57014a6d220d37cc57cd9bd51ebae9d7687762eb972cea16c37f7e48d440d9d55e7f4532ec09f218cf7a2cac4c
DIST pf-sources-5.3_p5.patch 1596810 BLAKE2B ba0229daedb6e883192fc3de569601bc2284dfdb012c4a46b7367772aec07570b826e9fb23725b68deac2a35613c44c83ae587dfb2d4787ef5bba39b995535b5 SHA512 7524528d02f4d593eae506c055c414f28875ee3f32334cf420ad4357e41fb8dbd0b3801d98676ca624566351145fde032c1ff8a25f762aa058c9558ffdf014cd
+DIST pf-sources-5.3_p6.patch 2032026 BLAKE2B 5384f2196b3799861e79ab223a1370f4049b86f0cc201d2ab09d31127e08fff3de0b2403693046b5f7a5f73750e12f027f30a5897ca6e457f0fac760bf0b8c6f SHA512 31b5e1d7bfe934a7733f81b663f8022b3c292acda3cef982ca4e56fee0a1df151e58c4a8e3af3d9a85927cac773add4492f5be369526308f665c3bafb629e936
--- /dev/null
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+ETYPE="sources"
+KEYWORDS="~amd64 ~ppc ~ppc64 ~x86"
+
+HOMEPAGE="https://gitlab.com/post-factum/pf-kernel/wikis/README
+ https://dev.gentoo.org/~mpagano/genpatches/"
+
+IUSE=""
+
+# No 'experimental' USE flag provided, but we still want to use genpatches
+K_EXP_GENPATCHES_NOUSE="1"
+
+# No reason to bump this number unless something new gets included in genpatches,
+# in that case we can manually remove the linux kernel patches from genpatches.
+K_GENPATCHES_VER="1"
+
+K_NOSETEXTRAVERSION="1"
+
+# Not supported by the Gentoo security crew
+K_SECURITY_UNSUPPORTED="1"
+
+K_USEPV="yes"
+
+# We want the very basic patches from gentoo-sources, experimental patch
+# is already included in pf-sources
+K_WANT_GENPATCHES="base extras"
+
+UNIPATCH_STRICTORDER="yes"
+
+inherit eutils kernel-2
+detect_version
+
+DESCRIPTION="Linux kernel fork that includes the pf-kernel patchset and Gentoo's genpatches"
+
+PF_URI="https://github.com/pfactum/pf-kernel/compare/v${PV/_p*/}...v${PV/_p*/}-pf${PV/*_p/}.diff -> ${P}.patch"
+SRC_URI="
+ ${KERNEL_URI}
+ ${PF_URI}
+ https://dev.gentoo.org/~mpagano/genpatches/tarballs/genpatches-${PV/_p*/}-${K_GENPATCHES_VER}.base.tar.xz
+ https://dev.gentoo.org/~mpagano/genpatches/tarballs/genpatches-${PV/_p*/}-${K_GENPATCHES_VER}.extras.tar.xz
+"
+
+KV_FULL="${PVR}-pf"
+S="${WORKDIR}/linux-${KV_FULL}"
+
+PATCHES=(
+ "${DISTDIR}/${P}.patch"
+)
+
+K_EXTRAEINFO="For more info on pf-sources and details on how to report problems,
+see: ${HOMEPAGE}."
+
+pkg_setup(){
+ ewarn
+ ewarn "${PN} is *not* supported by the Gentoo Kernel Project in any way."
+ ewarn "If you need support, please contact the pf developers directly."
+ ewarn "Do *not* open bugs in Gentoo's bugzilla unless you have issues with"
+ ewarn "the ebuilds. Thank you."
+ ewarn
+ kernel-2_pkg_setup
+}
+
+src_prepare() {
+ default
+ kernel-2_src_prepare
+}
+
+pkg_postinst() {
+ kernel-2_pkg_postinst
+ optfeature "Userspace KSM helper" sys-process/uksmd
+}