6.3.9-xanmod1
* also update zfs to 8e8acabdcaeb831c777f71361722f4235b698a8d * build zfs directly in-tree
This commit is contained in:
parent
b18ae0f457
commit
0a48391a5f
52
PKGBUILD
52
PKGBUILD
|
@ -1,6 +1,7 @@
|
|||
# Maintainer: Joan Figueras <ffigue at gmail dot com>
|
||||
# Contributor: Torge Matthies <openglfreak at googlemail dot com>
|
||||
# Contributor: Jan Alexander Steffens (heftig) <jan.steffens@gmail.com>
|
||||
# Contributor: Adam Mirre (wanderer) <wanderer at dotya dot ml> - added options to build ZFS in-tree
|
||||
|
||||
##
|
||||
## The following variables can be customized at build time. Use env or export to change at your wish
|
||||
|
@ -76,14 +77,15 @@ fi
|
|||
|
||||
### IMPORTANT: Do no edit below this line unless you know what you're doing
|
||||
|
||||
pkgbase=linux-xanmod
|
||||
_major=6.2
|
||||
pkgver=${_major}.10
|
||||
pkgbase=linux-xanmod-zfs-wanderer
|
||||
_major=6.3
|
||||
pkgver=${_major}.9
|
||||
_branch=6.x
|
||||
xanmod=1
|
||||
pkgrel=${xanmod}
|
||||
pkgdesc='Linux Xanmod - Current Stable (CURRENT)'
|
||||
url="http://www.xanmod.org/"
|
||||
pkgdesc='Linux Xanmod - Current Stable (CURRENT) with recent OpenZFS version built in-tree'
|
||||
# url="http://www.xanmod.org/"
|
||||
url="https://git.dotya.ml/wanderer/linux-xanmod-zfs.git"
|
||||
arch=(x86_64)
|
||||
license=(GPL2)
|
||||
makedepends=(
|
||||
|
@ -103,6 +105,7 @@ validpgpkeys=(
|
|||
'ABAF11C65A2970B130ABE3C479BE3E4300411886' # Linux Torvalds
|
||||
'647F28654894E3BD457199BE38DBBDC86092693E' # Greg Kroah-Hartman
|
||||
)
|
||||
# ^ gpg --locate-keys torvalds@kernel.org gregkh@kernel.org
|
||||
|
||||
# Archlinux patches
|
||||
_commit="ec9e9a4219fe221dec93fa16fddbe44a34933d8d"
|
||||
|
@ -112,9 +115,9 @@ for _patch in ${_patches[@]}; do
|
|||
source+=("${_patch}::https://raw.githubusercontent.com/archlinux/svntogit-packages/${_commit}/trunk/${_patch}")
|
||||
done
|
||||
|
||||
sha256sums=('74862fa8ab40edae85bb3385c0b71fe103288bce518526d63197800b3cbdecb1'
|
||||
sha256sums=('ba3491f5ed6bd270a370c440434e3d69085fcdd528922fa01e73d7657db73b1e'
|
||||
'SKIP'
|
||||
'30d69962510bb3eb630c2f0c590a0e3187739b82e4d7835c59ab061355c20019'
|
||||
'f6010d895c549ba8fc7e4728208c04de988486de0c30a1cdf50e04855d37675d'
|
||||
'5c84bfe7c1971354cff3f6b3f52bf33e7bbeec22f85d5e7bfde383b54c679d30')
|
||||
|
||||
## ZFS makedepends, source and checksums
|
||||
|
@ -134,7 +137,7 @@ if [ "$_build_zfs" = "y" ]; then
|
|||
|
||||
# ZFS branch zfs-2.1.10-staging
|
||||
makedepends+=(git)
|
||||
source_url="https://github.com/openzfs/zfs.git#commit=184508c77880dc85f88277927230c1908d42573d"
|
||||
source_url="https://github.com/openzfs/zfs.git#commit=8e8acabdcaeb831c777f71361722f4235b698a8d"
|
||||
source+=("git+$source_url")
|
||||
sha256sums+=('SKIP')
|
||||
fi
|
||||
|
@ -147,10 +150,10 @@ prepare() {
|
|||
cd linux-${_major}
|
||||
|
||||
# Apply Xanmod patch
|
||||
patch -Np1 -i ../patch-${pkgver}-xanmod${xanmod}
|
||||
patch -Np1 -i ../patch-${pkgver}-xanmod${xanmod} || true
|
||||
|
||||
msg2 "Setting version..."
|
||||
scripts/setlocalversion --save-scmversion
|
||||
# scripts/setlocalversion --save-scmversion
|
||||
echo "-$pkgrel" > localversion.10-pkgrel
|
||||
echo "${pkgbase#linux-xanmod}" > localversion.20-pkgname
|
||||
|
||||
|
@ -252,7 +255,7 @@ prepare() {
|
|||
|
||||
build() {
|
||||
cd linux-${_major}
|
||||
make ${_compiler_flags} all
|
||||
make ${_compiler_flags} -j10 modules_prepare
|
||||
|
||||
if [ "$_build_zfs" = "y" ]; then
|
||||
cd ${srcdir}/"zfs"
|
||||
|
@ -262,10 +265,15 @@ build() {
|
|||
./configure KERNEL_LLVM=1 --prefix=/usr --sysconfdir=/etc --sbindir=/usr/bin --libdir=/usr/lib \
|
||||
--datadir=/usr/share --includedir=/usr/include --with-udevdir=/lib/udev \
|
||||
--libexecdir=/usr/lib/zfs --with-config=kernel \
|
||||
--with-linux=${srcdir}/linux-${_major}
|
||||
make ${_compiler_flags}
|
||||
--with-linux=${srcdir}/linux-${_major} \
|
||||
--with-linux-obj=${srcdir}/linux-${_major} \
|
||||
--enable-linux-builtin=yes \
|
||||
&& ./copy-builtin ${srcdir}/linux-${_major}
|
||||
cd ${srcdir}/linux-${_major}
|
||||
sed -i 's/CONFIG_LEGACY_DIRECT_IO=y/CONFIG_LEGACY_DIRECT_IO=y\nCONFIG_ZFS=y/' .config
|
||||
fi
|
||||
|
||||
make ${_compiler_flags} -j10 all
|
||||
}
|
||||
|
||||
_package() {
|
||||
|
@ -379,25 +387,7 @@ _package-headers() {
|
|||
ln -sr "$builddir" "$pkgdir/usr/src/$pkgbase"
|
||||
}
|
||||
|
||||
_package-zfs() {
|
||||
pkgdesc="zfs module for the $pkgdesc kernel"
|
||||
depends=('pahole' "linux-xanmod=$pkgver-$pkgrel")
|
||||
provides=('ZFS-MODULE')
|
||||
|
||||
local kernver="$(<${srcdir}/linux-${_major}/version)"
|
||||
local modulesdir="$pkgdir/usr/lib/modules/$kernver"
|
||||
|
||||
cd ${srcdir}/"zfs"
|
||||
install -dm755 "$modulesdir"
|
||||
install -m644 module/*/*.ko "$modulesdir"
|
||||
find "$pkgdir" -name '*.ko' -exec zstd --rm -10 {} +
|
||||
# sed -i -e "s/EXTRAMODULES='.*'/EXTRAMODULES='${pkgver}-${pkgbase}'/" "$startdir/zfs.install"
|
||||
}
|
||||
|
||||
pkgname=("${pkgbase}" "${pkgbase}-headers")
|
||||
if [ "$_build_zfs" = "y" ]; then
|
||||
pkgname+=("$pkgbase-zfs")
|
||||
fi
|
||||
for _p in "${pkgname[@]}"; do
|
||||
eval "package_$_p() {
|
||||
$(declare -f "_package${_p#$pkgbase}")
|
||||
|
|
Loading…
Reference in New Issue