sys/sys-kernel/inf-kernel/inf-kernel-0.0.1.1.ebuild

50 lines
1.2 KiB
Bash

# Copyright 1999-2022 Gentoo Authors, 2022 Inference
# SPDX-License-Identifier: GPL-2.0-only
EAPI="8"
K_NOUSENAME="yes"
K_NOSETEXTRAVERSION="yes"
K_SECURITY_UNSUPPORTED="1"
ETYPE="sources"
inherit kernel-2
detect_version
DESCRIPTION="Inferencium Kernel source code."
HOMEPAGE="https://git.inferencium.net/Inferencium/inf-kernel/"
SRC_URI="https://git.inferencium.net/Inferencium/inf-kernel/archive/${P}.tar.gz"
S="${WORKDIR}/${PN}"
KEYWORDS="~amd64 ~arm64"
src_unpack() {
default
}
install_sources() {
local file
cd "${S}" || die
dodir /usr/src
einfo ">>> Copying source code ..."
file="$(find ${WORKDIR} -iname "docs" -type d)"
if [[ -n ${file} ]]; then
for file in $(find ${file} -type f); do
echo "${file//*docs\/}" >> "${S}"/patches.txt
echo "===================================================" >> "${S}"/patches.txt
cat ${file} >> "${S}"/patches.txt
echo "===================================================" >> "${S}"/patches.txt
echo "" >> "${S}"/patches.txt
done
fi
mv "${WORKDIR}"/inf-kernel* "${ED}"/src/${PN} || die
if [[ -n ${UNIPATCH_DOCS} ]]; then
for i in ${UNIPATCH_DOCS}; do
dodoc "${T}"/${i}
done
fi
}