Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

linux-*: various fixes (initramfs, hooks, presets) #1962

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 0 additions & 11 deletions core/linux-aarch64-rc/60-linux.hook

This file was deleted.

11 changes: 0 additions & 11 deletions core/linux-aarch64-rc/90-linux.hook

This file was deleted.

31 changes: 4 additions & 27 deletions core/linux-aarch64-rc/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ _srcname=linux-${_rcver}-rc${_rcrel}
_kernelname=${pkgbase#linux}
_desc="AArch64 multi-platform (release candidate)"
pkgver=${_rcver}.rc${_rcrel}
pkgrel=1
pkgrel=2
arch=('aarch64')
url="http://www.kernel.org/"
license=('GPL2')
Expand All @@ -23,20 +23,14 @@ source=("https://git.kernel.org/torvalds/t/${_srcname}.tar.gz"
'config'
'generate_chromebook_its.sh'
'kernel.keyblock'
'kernel_data_key.vbprivk'
'linux.preset'
'60-linux.hook'
'90-linux.hook')
'kernel_data_key.vbprivk')
md5sums=('41d2f438d53dc25c998379d139ff0201'
'7b08a199a97e3e2288e5c03d8e8ded2d'
'c9d4e392555b77034e24e9f87c5ff0b3'
'6ae4bc41e5a5e8f3d2b831d36f44f673'
'7c97cf141750ad810235b1ad06eb9f75'
'61c5ff73c136ed07a7aadbf58db3d96a'
'584777ae88bce2c5659960151b64c7d8'
'41cb5fef62715ead2dd109dbea8413d6'
'0a5f16bfec6ad982a2f6782724cca8ba'
'3dc88030a8f2f5a5f97266d99b149f77')
'584777ae88bce2c5659960151b64c7d8')

prepare() {
cd $_srcname
Expand Down Expand Up @@ -69,12 +63,11 @@ build() {

_package() {
pkgdesc="The Linux Kernel and modules - ${_desc}"
depends=('coreutils' 'linux-firmware' 'kmod' 'mkinitcpio>=0.7')
depends=('coreutils' 'linux-firmware' 'kmod' 'initramfs')
optdepends=('crda: to set the correct wireless channels of your country')
provides=("linux=${pkgver}" "WIREGUARD-MODULE")
replaces=('linux-armv8-rc')
conflicts=('linux')
backup=("etc/mkinitcpio.d/${pkgbase}.preset")
install=${pkgname}.install

cd $_srcname
Expand All @@ -90,22 +83,6 @@ _package() {

# remove build and source links
rm "$modulesdir"/{source,build}

# sed expression for following substitutions
local _subst="
s|%PKGBASE%|${pkgbase}|g
s|%KERNVER%|${kernver}|g
"

# install mkinitcpio preset file
sed "${_subst}" ../linux.preset |
install -Dm644 /dev/stdin "${pkgdir}/etc/mkinitcpio.d/${pkgbase}.preset"

# install pacman hooks
sed "${_subst}" ../60-linux.hook |
install -Dm644 /dev/stdin "${pkgdir}/usr/share/libalpm/hooks/60-${pkgbase}.hook"
sed "${_subst}" ../90-linux.hook |
install -Dm644 /dev/stdin "${pkgdir}/usr/share/libalpm/hooks/90-${pkgbase}.hook"
}

_package-headers() {
Expand Down
14 changes: 0 additions & 14 deletions core/linux-aarch64-rc/linux.preset

This file was deleted.

11 changes: 0 additions & 11 deletions core/linux-aarch64/60-linux.hook

This file was deleted.

11 changes: 0 additions & 11 deletions core/linux-aarch64/90-linux.hook

This file was deleted.

31 changes: 4 additions & 27 deletions core/linux-aarch64/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ _srcname=linux-5.19
_kernelname=${pkgbase#linux}
_desc="AArch64 multi-platform"
pkgver=5.19.8
pkgrel=1
pkgrel=2
arch=('aarch64')
url="http://www.kernel.org/"
license=('GPL2')
Expand All @@ -21,21 +21,15 @@ source=("http://www.kernel.org/pub/linux/kernel/v5.x/${_srcname}.tar.xz"
'config'
'generate_chromebook_its.sh'
'kernel.keyblock'
'kernel_data_key.vbprivk'
'linux.preset'
'60-linux.hook'
'90-linux.hook')
'kernel_data_key.vbprivk')
md5sums=('f91bfe133d2cb1692f705947282e123a'
'702a69746536f24fd5ebde90eed26048'
'e0514a3e8f7383c1304faeff0121dfb5'
'965c9f68072084cdbf1e083779d2ef0e'
'417932cd6167ff0b47c6dc297e3eb3fb'
'7c97cf141750ad810235b1ad06eb9f75'
'61c5ff73c136ed07a7aadbf58db3d96a'
'584777ae88bce2c5659960151b64c7d8'
'41cb5fef62715ead2dd109dbea8413d6'
'0a5f16bfec6ad982a2f6782724cca8ba'
'3dc88030a8f2f5a5f97266d99b149f77')
'584777ae88bce2c5659960151b64c7d8')

prepare() {
cd $_srcname
Expand Down Expand Up @@ -71,11 +65,10 @@ build() {

_package() {
pkgdesc="The Linux Kernel and modules - ${_desc}"
depends=('coreutils' 'linux-firmware' 'kmod' 'mkinitcpio>=0.7')
depends=('coreutils' 'linux-firmware' 'kmod' 'initramfs')
optdepends=('wireless-regdb: to set the correct wireless channels of your country')
provides=("linux=${pkgver}" "WIREGUARD-MODULE")
conflicts=('linux')
backup=("etc/mkinitcpio.d/${pkgbase}.preset")
install=${pkgname}.install

cd $_srcname
Expand All @@ -91,22 +84,6 @@ _package() {

# remove build and source links
rm "$modulesdir"/{source,build}

# sed expression for following substitutions
local _subst="
s|%PKGBASE%|${pkgbase}|g
s|%KERNVER%|${kernver}|g
"

# install mkinitcpio preset file
sed "${_subst}" ../linux.preset |
install -Dm644 /dev/stdin "${pkgdir}/etc/mkinitcpio.d/${pkgbase}.preset"

# install pacman hooks
sed "${_subst}" ../60-linux.hook |
install -Dm644 /dev/stdin "${pkgdir}/usr/share/libalpm/hooks/60-${pkgbase}.hook"
sed "${_subst}" ../90-linux.hook |
install -Dm644 /dev/stdin "${pkgdir}/usr/share/libalpm/hooks/90-${pkgbase}.hook"
}

_package-headers() {
Expand Down
14 changes: 0 additions & 14 deletions core/linux-aarch64/linux.preset

This file was deleted.

11 changes: 0 additions & 11 deletions core/linux-am33x/99-linux.hook

This file was deleted.

24 changes: 4 additions & 20 deletions core/linux-am33x/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ _srcname=linux-5.19
_kernelname=${pkgbase#linux}
_desc="TI AM335x Beaglebone (Black)"
pkgver=5.19.8
pkgrel=1
pkgrel=2
rcnver=5.19.8
rcnrel=bone9
arch=('armv7h')
Expand All @@ -21,17 +21,13 @@ source=("https://www.kernel.org/pub/linux/kernel/v5.x/${_srcname}.tar.xz"
"https://rcn-ee.com/deb/sid-armhf/v${rcnver}-${rcnrel}/patch-${rcnver%.0}-${rcnrel}.diff.gz"
"git+https://github.com/RobertCNelson/bb.org-overlays.git"
'0001-add-lcd-cape-for-chiliboard.patch'
'config'
'linux.preset'
'99-linux.hook')
'config')
md5sums=('f91bfe133d2cb1692f705947282e123a'
'702a69746536f24fd5ebde90eed26048'
'b8b6fdc3eb628e0f6dd0e2bb5df4c1af'
'SKIP'
'ee16bcdbbf978e714455933ecd6dd8fe'
'd1889d23975bff4ea6eeb46741b7c653'
'78ccc998f27eec49a9d5490218b1b1ab'
'79fa396e3f9a09a85156d6d7c2d34b58')
'd1889d23975bff4ea6eeb46741b7c653')

prepare() {
cd "${srcdir}/${_srcname}"
Expand Down Expand Up @@ -90,9 +86,8 @@ build() {

_package() {
pkgdesc="The Linux Kernel and modules - ${_desc}"
depends=('coreutils' 'linux-firmware' 'kmod' 'mkinitcpio>=0.7')
depends=('coreutils' 'linux-firmware' 'kmod' 'initramfs')
optdepends=('crda: to set the correct wireless channels of your country')
backup=("etc/mkinitcpio.d/${pkgbase}.preset")
provides=("linux=${pkgver}" "WIREGUARD-MODULE")
conflicts=('linux')
replaces=('linux-ti')
Expand All @@ -118,17 +113,6 @@ _package() {
-e "s/KERNEL_VERSION=.*/KERNEL_VERSION=${_kernver}/g" \
-i "${startdir}/${pkgname}.install"

# install mkinitcpio preset file for kernel
install -D -m644 "${srcdir}/linux.preset" "${pkgdir}/etc/mkinitcpio.d/${pkgbase}.preset"
sed \
-e "1s|'linux.*'|'${pkgbase}'|" \
-e "s|ALL_kver=.*|ALL_kver=\"${_kernver}\"|" \
-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
Expand Down
10 changes: 0 additions & 10 deletions core/linux-am33x/linux.preset

This file was deleted.

11 changes: 0 additions & 11 deletions core/linux-armv7-rc/99-linux.hook

This file was deleted.

24 changes: 4 additions & 20 deletions core/linux-armv7-rc/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ _srcname=linux-${_rcver}-rc${_rcrel}
_kernelname=${pkgbase#linux}
_desc="ARMv7 multi-platform (release candidate)"
pkgver=${_rcver}.rc${_rcrel}
pkgrel=1
pkgrel=2
arch=('armv7h')
url="http://www.kernel.org/"
license=('GPL2')
Expand All @@ -31,9 +31,7 @@ source=("https://git.kernel.org/torvalds/t/${_srcname}.tar.gz"
'config'
'kernel.its'
'kernel.keyblock'
'kernel_data_key.vbprivk'
'linux.preset'
'99-linux.hook')
'kernel_data_key.vbprivk')
md5sums=('41d2f438d53dc25c998379d139ff0201'
'e4df378f94ef33e365ca47d78a6dafb9'
'9e9d3b4cde2e27afd79f8818eb86a493'
Expand All @@ -46,9 +44,7 @@ md5sums=('41d2f438d53dc25c998379d139ff0201'
'a42391b00a10269df8c80e58a4f69231'
'0963ff6490be16935370812fc75fa065'
'61c5ff73c136ed07a7aadbf58db3d96a'
'584777ae88bce2c5659960151b64c7d8'
'ae7ccb81e057c4d81401e725f102ee5f'
'79fa396e3f9a09a85156d6d7c2d34b58')
'584777ae88bce2c5659960151b64c7d8')

prepare() {
cd "${srcdir}/${_srcname}"
Expand Down Expand Up @@ -107,9 +103,8 @@ build() {

_package() {
pkgdesc="The Linux Kernel and modules - ${_desc}"
depends=('coreutils' 'linux-firmware' 'kmod' 'mkinitcpio>=0.7')
depends=('coreutils' 'linux-firmware' 'kmod' 'initramfs')
optdepends=('wireless-regdb: to set the correct wireless channels of your country')
backup=("etc/mkinitcpio.d/${pkgbase}.preset")
provides=("linux=${pkgver}" "WIREGUARD-MODULE")
conflicts=('linux')
replaces=('linux-mvebu')
Expand All @@ -135,17 +130,6 @@ _package() {
-e "s/KERNEL_VERSION=.*/KERNEL_VERSION=${_kernver}/g" \
-i "${startdir}/${pkgname}.install"

# install mkinitcpio preset file for kernel
install -D -m644 "${srcdir}/linux.preset" "${pkgdir}/etc/mkinitcpio.d/${pkgbase}.preset"
sed \
-e "1s|'linux.*'|'${pkgbase}'|" \
-e "s|ALL_kver=.*|ALL_kver=\"${_kernver}\"|" \
-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
Expand Down
10 changes: 0 additions & 10 deletions core/linux-armv7-rc/linux.preset

This file was deleted.

12 changes: 0 additions & 12 deletions core/linux-armv7/60-linux.hook

This file was deleted.

Loading