2019-01-10 03:47:19 +00:00
|
|
|
# Reference: <https://postmarketos.org/vendorkernel>
|
2020-06-24 08:13:56 +00:00
|
|
|
# Maintainer: Clayton Craft <clayton@craftyguy.net>
|
2022-12-09 12:13:27 +00:00
|
|
|
# Co-Maintainer: Alistair Francis <alistair@alistair23.me>
|
2020-04-25 09:51:42 +00:00
|
|
|
pkgname=linux-purism-librem5
|
2023-01-31 12:53:45 +00:00
|
|
|
pkgver=6.1.8
|
2023-02-06 14:08:22 +00:00
|
|
|
pkgrel=1
|
2021-11-16 19:58:06 +00:00
|
|
|
_purismrel=1
|
2020-06-24 08:13:56 +00:00
|
|
|
# <kernel ver>.<purism kernel release>
|
2021-02-18 00:21:50 +00:00
|
|
|
_purismver=${pkgver}pureos$_purismrel
|
2020-01-12 02:51:36 +00:00
|
|
|
pkgdesc="Purism Librem 5 phone kernel fork"
|
2019-01-10 03:47:19 +00:00
|
|
|
arch="aarch64"
|
|
|
|
_carch="arm64"
|
2020-01-12 02:51:36 +00:00
|
|
|
_flavor="purism-librem5"
|
2020-06-24 08:13:56 +00:00
|
|
|
url="https://source.puri.sm/Librem5/linux-next"
|
2019-01-10 03:47:19 +00:00
|
|
|
license="GPL-2.0-only"
|
2021-06-24 01:28:42 +00:00
|
|
|
options="!strip !check !tracedeps
|
2022-09-07 20:43:05 +00:00
|
|
|
pmb:cross-native
|
|
|
|
pmb:kconfigcheck-community
|
2021-06-24 01:28:42 +00:00
|
|
|
"
|
2020-12-05 04:29:54 +00:00
|
|
|
makedepends="
|
2022-10-02 03:13:47 +00:00
|
|
|
bash
|
2020-12-05 04:29:54 +00:00
|
|
|
bison
|
|
|
|
devicepkg-dev
|
|
|
|
findutils
|
|
|
|
flex
|
|
|
|
installkernel
|
|
|
|
openssl-dev
|
|
|
|
perl
|
2021-03-09 05:32:09 +00:00
|
|
|
rsync
|
|
|
|
xz
|
2020-12-05 04:29:54 +00:00
|
|
|
"
|
2021-03-24 18:52:19 +00:00
|
|
|
install="$pkgname.post-upgrade"
|
2019-01-10 03:47:19 +00:00
|
|
|
|
|
|
|
# Source
|
2022-02-28 09:58:48 +00:00
|
|
|
_repository="linux"
|
2020-02-02 20:16:38 +00:00
|
|
|
# kconfig generated with: ARCH=arm64 make defconfig KBUILD_DEFCONFIG=librem5_defconfig
|
2020-01-12 02:51:36 +00:00
|
|
|
_config="config-$_flavor.$arch"
|
2022-10-02 03:13:47 +00:00
|
|
|
|
|
|
|
|
2019-01-10 03:47:19 +00:00
|
|
|
source="
|
2022-02-28 09:58:48 +00:00
|
|
|
$pkgname-$_purismver.tar.gz::https://source.puri.sm/Librem5/linux/-/archive/pureos/$_purismver/linux-pureos-$_purismver.tar.gz
|
2019-01-10 03:47:19 +00:00
|
|
|
$_config
|
|
|
|
"
|
2020-03-14 20:34:08 +00:00
|
|
|
builddir="$srcdir/$_repository-pureos-$_purismver"
|
2019-01-10 03:47:19 +00:00
|
|
|
|
|
|
|
prepare() {
|
|
|
|
default_prepare
|
2019-01-29 08:50:55 +00:00
|
|
|
REPLACE_GCCH=0 \
|
2020-04-01 07:09:30 +00:00
|
|
|
. downstreamkernel_prepare
|
2022-10-02 03:13:47 +00:00
|
|
|
|
|
|
|
# NOTE: only for generating a config based on Purism's defconfig, for rebasing...
|
|
|
|
# make ARCH="$_carch" CC="${CC:-gcc}" \
|
|
|
|
# defconfig KBUILD_DEFCONFIG=librem5_defconfig
|
2019-01-10 03:47:19 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
build() {
|
|
|
|
unset LDFLAGS
|
|
|
|
make ARCH="$_carch" CC="${CC:-gcc}" \
|
2020-06-24 08:13:56 +00:00
|
|
|
KBUILD_BUILD_VERSION="$((pkgrel + 1 ))-postmarketOS" \
|
|
|
|
LOCALVERSION=".$_purismrel"
|
2019-01-10 03:47:19 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
package() {
|
2020-02-18 08:34:06 +00:00
|
|
|
downstreamkernel_package "$builddir" "$pkgdir" "$_carch" "$_flavor"
|
2019-01-10 03:47:19 +00:00
|
|
|
|
2020-06-16 02:16:01 +00:00
|
|
|
make modules_install dtbs_install \
|
2019-01-10 03:47:19 +00:00
|
|
|
ARCH="$_carch" \
|
|
|
|
INSTALL_MOD_PATH="$pkgdir" \
|
2022-07-30 18:11:01 +00:00
|
|
|
INSTALL_DTBS_PATH="$pkgdir/boot/dtbs"
|
2019-01-10 03:47:19 +00:00
|
|
|
|
|
|
|
}
|
2021-03-09 05:32:09 +00:00
|
|
|
|
2021-05-07 07:15:58 +00:00
|
|
|
sha512sums="
|
2023-01-31 12:53:45 +00:00
|
|
|
5f4510b859a59cb8e52280c8609c15ec8a14b857616ff55b0505b1492ad566845143997ce04bcab3011e04f06d4de5574673d62dbe8ce28b3b66a4a9321113bd linux-purism-librem5-6.1.8pureos1.tar.gz
|
2023-02-06 14:08:22 +00:00
|
|
|
c8a47bddfe5134d171efc4e7211667f3b554edb867f36232b2018afb5a0980cf35aaafb11b40ecaa0057dd23adccfc5992d2f0df9b018e206d2a9af70adc3533 config-purism-librem5.aarch64
|
2021-05-07 07:15:58 +00:00
|
|
|
"
|