summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorJames Bunton2017-03-05 14:56:28 +1100
committerJames Bunton2017-03-05 14:56:28 +1100
commit4f73152e1158a02f3213894cfe781adc1e69ebff (patch)
treee8d011fbc6818ccfebf2a6f176d81592406d2e8c /PKGBUILD
parentd3bd8222101dd5cb0206c069382cdedabc4b106f (diff)
downloadaur-4f73152e1158a02f3213894cfe781adc1e69ebff.tar.gz
Use pacman hook for mkinitcpio
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD7
1 files changed, 7 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD
index 5ffd6c26ebe3..9040c99cc244 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -15,6 +15,8 @@ source=("https://www.kernel.org/pub/linux/kernel/v3.x/${_srcname}.tar.xz"
"https://www.kernel.org/pub/linux/kernel/v3.x/patch-${pkgver}.xz"
# the main kernel config files
'config' 'config.x86_64'
+ # pacman hook for initramfs regeneration
+ '99-linux.hook'
# standard config files for mkinitcpio ramdisk
'linux.preset'
'change-default-console-loglevel.patch'
@@ -23,6 +25,7 @@ sha256sums=('4813ad7927a7d92e5339a873ab16201b242b2748934f12cb5df9ba2cfe1d77a0'
'a6ada9d5678138a556d69b9f44c9d56ea274820b35990672ccb21607cd7ffa0f'
'3bce3e9adce8ae3f826eebab75e9784ca92a914e526ae352de61c1da93aab8d3'
'41ecf5fd8de0bc3dc4d5e20b1e0a28517dc77f96fc5ebdbf227126d85c503588'
+ '834bd254b56ab71d73f59b3221f056c72f559553c04718e350ab2a3e2991afe0'
'f0d90e756f14533ee67afda280500511a62465b4f76adcc5effa95a40045179c'
'1256b241cd477b265a3c2d64bdc19ffe3c9bbcee82ea3994c590c2c76e767d99')
@@ -118,6 +121,10 @@ _package() {
-e "s|fallback_image=.*|fallback_image=\"/boot/initramfs-${pkgbase}-fallback.img\"|" \
-i "${pkgdir}/etc/mkinitcpio.d/${pkgbase}.preset"
+ # install pacman hook for initramfs regeneration
+ sed "s|%PKGBASE%|${pkgbase}|g" "${srcdir}/99-linux.hook" |
+ install -D -m644 /dev/stdin "${pkgdir}/usr/share/libalpm/hooks/99-${pkgbase}.hook"
+
# remove build and source links
rm -f "${pkgdir}"/lib/modules/${_kernver}/{source,build}
# remove the firmware