summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorJack Chen2020-11-19 11:30:49 +0800
committerJack Chen2020-11-19 11:50:56 +0800
commit721845ed4f0fcba07f75307c9274643c56b82cae (patch)
tree4e26bf02e966dddbc3a2cc1a052bd7076deedaa7
parent4d82ac3b4649ac257212012e3a164d293c76f902 (diff)
downloadaur-721845ed4f0fcba07f75307c9274643c56b82cae.tar.gz
update PKGBUILD
-rw-r--r--.SRCINFO25
-rw-r--r--59-linux-rockchip-remove.hook16
-rw-r--r--91-linux-rockchip-install.hook12
-rw-r--r--PKGBUILD22
-rw-r--r--linux-rockchip.preset4
5 files changed, 19 insertions, 60 deletions
diff --git a/.SRCINFO b/.SRCINFO
index aded2fcb1678..714893ccf912 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -4,44 +4,35 @@ pkgbase = linux-rockchip
url = https://apt.armbian.com
arch = armv7h
license = GPL2
- depends = coreutils
- depends = kmod
- depends = mkinitcpio
- depends = uboot-tools
- provides = linux
- provides = linux-rockchip
+ makedepends = coreutils
+ makedepends = curl
+ makedepends = grep
+ makedepends = sed
noextract = linux-rockchip.preset
- noextract = 59-linux-rockchip-remove.hook
- noextract = 91-linux-rockchip-install.hook
noextract = linux-dtb-current-rockchip_20.08.14_armhf.deb
noextract = linux-image-current-rockchip_20.08.14_armhf.deb
noextract = linux-headers-current-rockchip_20.08.14_armhf.deb
options = !strip
source = linux-rockchip.preset
- source = 59-linux-rockchip-remove.hook
- source = 91-linux-rockchip-install.hook
source = https://apt.armbian.com/pool/main/l/linux-5.8.16-rockchip/linux-dtb-current-rockchip_20.08.14_armhf.deb
source = https://apt.armbian.com/pool/main/l/linux-5.8.16-rockchip/linux-image-current-rockchip_20.08.14_armhf.deb
source = https://apt.armbian.com/pool/main/l/linux-5.8.16-rockchip/linux-headers-current-rockchip_20.08.14_armhf.deb
- sha512sums = c7a00e379d723d90c28c70069043a29800be40f120e36527b3aefe5b7acfbcd5680417c2cbf5ff2979c765456d4d5022ac10f01cfc65ab2e7cfb3a104bb670ce
- sha512sums = 91becd9ab8763914fb9b4e3eeb1fe2493535baa144f763dd59dd5f8e84a5151ed75548113ae31db86c38c60d8c81ac4d9a55162c6f35b3ca886747834fadc86d
- sha512sums = 6f3ebed8b3c570e04de85dee76ef39f542e79e14994808a7a367128cd820441d506663af75bca0267288677aaf9e6566b0f338aa2ef7111398ee5766e2098eee
+ sha512sums = 966a57dc6ea894b5b74b5f6c3ca0f8ee2ceb6ca8782f7cb0ae56a449f8f178d638ed455c022493fb339d1b685c282c06e30aec602078c3bb3302e1aa4bd810ea
sha512sums = 723c3acdc7e3f56b7bb071b0d0ac8f284ba1bc2cb13aa318f30d431c49e635171492cd6648d601272259ed4e61f1ab3ac2555e182da9259d53fc148d0b3436ea
sha512sums = 59cea050cb3ca50d6e4c59fd7b2686eaf2762dd8da4bfaae360fb4410f615a5e2107d7c0789e75944620603707a6a6e817619d713c901633277c1fba9e5611d5
sha512sums = 961b8f97ad773d8c5da6d7ab3c5cb1268eea1aaff9ebaf2dc692a31aadb451a9a3ac6300078d2dd704e31e5cedb32aa43c023e991f5b592fd4ae7f01056407da
pkgname = linux-rockchip
pkgdesc = Rockchip Linux kernel and modules from Armbian
- depends = coreutils
- depends = kmod
depends = mkinitcpio
- depends = uboot-tools
+ depends = grep
+ depends = gzip
+ depends = sed
provides = linux
provides = linux-rockchip
pkgname = linux-rockchip-headers
pkgdesc = Headers and scripts for building modules for the linux-rockchip kernel
- depends = linux-rockchip
provides = linux-headers
provides = linux-headers-rockchip
diff --git a/59-linux-rockchip-remove.hook b/59-linux-rockchip-remove.hook
deleted file mode 100644
index 3cbec24d9082..000000000000
--- a/59-linux-rockchip-remove.hook
+++ /dev/null
@@ -1,16 +0,0 @@
-[Trigger]
-Type = Path
-Operation = Remove
-Target = usr/lib/modules/*/vmlinuz
-
-[Trigger]
-Type = Package
-Operation = Remove
-Target = mkinitcpio
-Target = mkinitcpio-git
-
-[Action]
-Description = Removing u-boot ramdisk image...
-When = PreTransaction
-Exec = /usr/bin/rm -f /boot/uInitrd
-NeedsTargets
diff --git a/91-linux-rockchip-install.hook b/91-linux-rockchip-install.hook
deleted file mode 100644
index 2e5520d0c94e..000000000000
--- a/91-linux-rockchip-install.hook
+++ /dev/null
@@ -1,12 +0,0 @@
-[Trigger]
-Type = Path
-Operation = Install
-Operation = Upgrade
-Target = usr/lib/modules/*/vmlinuz
-Target = usr/lib/initcpio/*
-
-[Action]
-Description = Updating u-boot ramdisk image...
-When = PostTransaction
-Exec = /usr/bin/mkimage -C none -A arm -T ramdisk -d /boot/initramfs-linux-rockchip.img /boot/uInitrd
-NeedsTargets
diff --git a/PKGBUILD b/PKGBUILD
index 0da788a0ec93..8e512224cd90 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -7,8 +7,7 @@ pkgrel=1
arch=('armv7h')
url="https://apt.armbian.com"
license=('GPL2')
-depends=('coreutils' 'kmod' 'mkinitcpio' 'uboot-tools')
-provides=('linux' 'linux-rockchip')
+makedepends=('coreutils' 'curl' 'grep' 'sed')
options=('!strip')
_pkgfile=$(curl -s -L https://apt.armbian.com/dists/focal/main/binary-armhf/Packages -o Packages)
@@ -16,16 +15,12 @@ _kernver=$(cat Packages | grep 'linux-dtb-current-rockchip.*deb' | head -n 1 | s
source=(
"$pkgbase.preset"
- "59-$pkgbase-remove.hook"
- "91-$pkgbase-install.hook"
"$(cat Packages | grep 'linux-dtb-current-rockchip.*deb' | head -n 1 | sed -r 's#Filename: #https://apt.armbian.com/#')"
"$(cat Packages | grep 'linux-image-current-rockchip.*deb' | head -n 1 | sed -r 's#Filename: #https://apt.armbian.com/#')"
"$(cat Packages | grep 'linux-headers-current-rockchip.*deb' | head -n 1 | sed -r 's#Filename: #https://apt.armbian.com/#')"
)
sha512sums=(
- 'c7a00e379d723d90c28c70069043a29800be40f120e36527b3aefe5b7acfbcd5680417c2cbf5ff2979c765456d4d5022ac10f01cfc65ab2e7cfb3a104bb670ce'
- '91becd9ab8763914fb9b4e3eeb1fe2493535baa144f763dd59dd5f8e84a5151ed75548113ae31db86c38c60d8c81ac4d9a55162c6f35b3ca886747834fadc86d'
- '6f3ebed8b3c570e04de85dee76ef39f542e79e14994808a7a367128cd820441d506663af75bca0267288677aaf9e6566b0f338aa2ef7111398ee5766e2098eee'
+ '966a57dc6ea894b5b74b5f6c3ca0f8ee2ceb6ca8782f7cb0ae56a449f8f178d638ed455c022493fb339d1b685c282c06e30aec602078c3bb3302e1aa4bd810ea'
"$(cat Packages | grep 'linux-dtb-current-rockchip.*deb' -A 5 | grep SHA512 | head -n 1 | sed -r 's#SHA512: ##')"
"$(cat Packages | grep 'linux-image-current-rockchip.*deb' -A 5 | grep SHA512 | head -n 1 | sed -r 's#SHA512: ##')"
"$(cat Packages | grep 'linux-headers-current-rockchip.*deb' -A 5 | grep SHA512 | head -n 1 | sed -r 's#SHA512: ##')"
@@ -44,7 +39,7 @@ prepare() {
package_linux-rockchip() {
pkgdesc="Rockchip Linux kernel and modules from Armbian"
- depends=('coreutils' 'kmod' 'mkinitcpio' 'uboot-tools')
+ depends=('mkinitcpio' 'grep' 'gzip' 'sed')
provides=('linux' 'linux-rockchip')
cd "$srcdir"
@@ -59,31 +54,30 @@ package_linux-rockchip() {
mkdir -p "$pkgdir/boot"
mv "boot/dtb-$_kernver" "$pkgdir/boot/dtb"
- ln -s "vmlinuz-$pkgbase" "$pkgdir/boot/zImage"
echo "$pkgbase" > "$pkgdir/usr/lib/modules/$_kernver/pkgbase"
install -Dm644 "boot/vmlinuz-$_kernver" "$pkgdir/usr/lib/modules/$_kernver/vmlinuz"
- install -Dm644 "boot/config-$_kernver" "$pkgdir/usr/lib/modules/$_kernver/build/config"
- install -Dm644 "boot/System.map-$_kernver" "$pkgdir/usr/lib/modules/$_kernver/build/System.map"
install -Dm644 "$pkgbase.preset" "$pkgdir/etc/mkinitcpio.d/$pkgbase.preset"
- install -Dm644 "59-$pkgbase-remove.hook" "$pkgdir/usr/share/libalpm/hooks/59-$pkgbase-remove.hook"
- install -Dm644 "91-$pkgbase-install.hook" "$pkgdir/usr/share/libalpm/hooks/91-$pkgbase-install.hook"
}
package_linux-rockchip-headers() {
pkgdesc="Headers and scripts for building modules for the $pkgbase kernel"
- depends=('linux-rockchip')
provides=('linux-headers' 'linux-headers-rockchip')
cd "$srcdir"
+ ar x linux-image-current-rockchip_*.deb
+ tar -xf data.tar.xz
ar x linux-headers-current-rockchip_*.deb
tar -xf data.tar.xz
mkdir -p "$pkgdir/usr/lib/modules/$_kernver"
mv "usr/src/linux-headers-$_kernver" "$pkgdir/usr/lib/modules/$_kernver/build"
+ install -Dm644 "boot/config-$_kernver" "$pkgdir/usr/lib/modules/$_kernver/build/.config"
+ install -Dm644 "boot/System.map-$_kernver" "$pkgdir/usr/lib/modules/$_kernver/build/System.map"
+
mkdir -p "$pkgdir/usr/src"
ln -s "../lib/modules/$_kernver/build" "$pkgdir/usr/src/$pkgbase"
}
diff --git a/linux-rockchip.preset b/linux-rockchip.preset
index 7629cd16688f..e3e49ce72957 100644
--- a/linux-rockchip.preset
+++ b/linux-rockchip.preset
@@ -1,5 +1,7 @@
+# mkinitcpio preset file for the 'linux-rockchip' package
+
ALL_config="/etc/mkinitcpio.conf"
-ALL_kver="$(dd if=/boot/zImage skip=$(grep -a -b -o $'\x1f\x8b\x08\x00\x00\x00\x00\x00' /boot/zImage | head -n 1 | cut -d ':' -f 1) iflag=skip_bytes 2>&1 | zcat -q | grep -a 'Linux version [0-9]' | sed -r 's#.*([0-9]+.[0-9]+.[0-9]+-[a-zA-Z]+).*#\1#')"
+ALL_kver="$(dd if=/boot/vmlinuz-linux-rockchip skip=$(grep -a -b -o $'\x1f\x8b\x08\x00\x00\x00\x00\x00' /boot/vmlinuz-linux-rockchip | head -n 1 | cut -d ':' -f 1) iflag=skip_bytes 2>&1 | zcat -q | grep -a 'Linux version [0-9]' | sed -r 's#.*([0-9]+.[0-9]+.[0-9]+-[a-zA-Z]+).*#\1#')"
PRESETS=('default')