sys-fs/btrfs-progs: Apply Flatcar modifications

This commit is contained in:
Krzesimir Nowak 2021-11-25 11:41:41 +01:00
parent baefb0d674
commit 81f7fa466f
2 changed files with 22 additions and 3 deletions

View File

@ -0,0 +1,14 @@
We forked this package for the following reasons:
- We override the udev rules directory. The configure script does not
provide a way to override it, so we need to hack it, otherwise the
configure script will figure out the wrong path in our builds. We do
it by overriding it in Makefile.inc.in. Ideal solution here would be
to patch btrfs-progs to allow overriding the udev path and then
override it in the ebuild properly, without the sed hacks.
- We change the python versions, because we still have only python
3.6.
- We stabilize the package on both amd64 and arm64 to keep it in sync
with our linux kernel version.

View File

@ -3,16 +3,19 @@
EAPI=7 EAPI=7
PYTHON_COMPAT=( python3_{8..9} ) # Flatcar: We still have python 3.6 only.
PYTHON_COMPAT=( python3_{6..9} )
inherit bash-completion-r1 python-single-r1 # Flatcar: Inherit udev eclass, so we can get the udev directory.
inherit bash-completion-r1 python-single-r1 udev
libbtrfs_soname=0 libbtrfs_soname=0
if [[ ${PV} != 9999 ]]; then if [[ ${PV} != 9999 ]]; then
MY_PV="v${PV/_/-}" MY_PV="v${PV/_/-}"
[[ "${PV}" = *_rc* ]] || \ [[ "${PV}" = *_rc* ]] || \
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~ia64 ~mips ~ppc ~ppc64 ~riscv ~sparc ~x86" # Flatcar: Stabilize our arches.
KEYWORDS="~alpha amd64 ~arm arm64 ~ia64 ~mips ~ppc ~ppc64 ~riscv ~sparc ~x86"
SRC_URI="https://www.kernel.org/pub/linux/kernel/people/kdave/${PN}/${PN}-${MY_PV}.tar.xz" SRC_URI="https://www.kernel.org/pub/linux/kernel/people/kdave/${PN}/${PN}-${MY_PV}.tar.xz"
S="${WORKDIR}/${PN}-${MY_PV}" S="${WORKDIR}/${PN}-${MY_PV}"
else else
@ -94,6 +97,8 @@ src_prepare() {
ln -s "${EPREFIX}"/usr/share/gnuconfig/config.guess config/config.guess || die ln -s "${EPREFIX}"/usr/share/gnuconfig/config.guess config/config.guess || die
ln -s "${EPREFIX}"/usr/share/gnuconfig/config.sub config/config.sub || die ln -s "${EPREFIX}"/usr/share/gnuconfig/config.sub config/config.sub || die
fi fi
# Flatcar: Replace udevdir variable with proper udev directory.
sed -i -e 's#^\(udevdir\s\+=\).*#\1 $(get_udevdir)#' Makefile.inc.in
} }
src_configure() { src_configure() {