pmaports/device/testing/linux-lg-d851/APKBUILD
Luca Weiss c57aa7b299
device/*/linux-*: enable CONFIG_TMPFS_POSIX_ACL (MR 1939)
This is required by some software, e.g. bluez/gnome to set some ACLs on
/dev/rfkill (see #904). While probably nobody will notice on the
downstream kernels (as we don't have any proper software there anyways)
it's definitely needed on mainline-ish kernels. Surprisingly only one
kernel has broken by enabling this option (linux-sony-tulip) which I've
patched up.

linux-postmarketos-qcom-sdm660 did not break by enabling this option,
but required linux4.17-gcc10-extern_YYLOC_global_declaration.patch to
build again, so this was fixed too.

[ci:skip-build] [ci:ignore-count]
2021-02-09 21:54:35 +01:00

58 lines
2.2 KiB
Text

# Reference: <https://postmarketos.org/vendorkernel>
# Kernel config based on: arch/arm/configs/lineageos_d851_defconfig
pkgname=linux-lg-d851
pkgver=3.4.113
pkgrel=1
pkgdesc="LG G3 (T-Mobile) kernel fork"
arch="armv7"
_carch="arm"
_flavor="lg-d851"
url="https://kernel.org"
license="GPL-2.0-only"
options="!strip !check !tracedeps pmb:cross-native"
makedepends="bash bc bison devicepkg-dev dtbtool elfutils-dev flex gmp-dev installkernel linux-headers openssl-dev perl sed xz gcc6"
# Compiler: GCC 6 (doesn't compile successfully with newer versions)
if [ "${CC:0:5}" != "gcc6-" ]; then
CC="gcc6-$CC"
HOSTCC="gcc6-gcc"
CROSS_COMPILE="gcc6-$CROSS_COMPILE"
fi
# Source
_repository="android_kernel_lge_g3"
_commit="e9173c6249c1a965b5e0c3a73c4b232f0d19b080"
_config="config-$_flavor.$arch"
source="
$pkgname-$_commit.tar.gz::https://github.com/LineageOS/$_repository/archive/$_commit.tar.gz
$_config
gcc10-extern_YYLOC_global_declaration.patch
02_gpu-msm-fix-gcc5-compile.patch
"
builddir="$srcdir/$_repository-$_commit"
_outdir="out"
prepare() {
default_prepare
. downstreamkernel_prepare
}
build() {
unset LDFLAGS
make O="$_outdir" ARCH="$_carch" CC="${CC:-gcc}" \
KBUILD_BUILD_VERSION="$((pkgrel + 1 ))-postmarketOS"
}
package() {
downstreamkernel_package "$builddir" "$pkgdir" "$_carch" "$_flavor" "$_outdir"
# Master DTB (deviceinfo_bootimg_qcdt)
dtbTool -p scripts/dtc/ -o "$_outdir/arch/$_carch/boot"/dt.img "$_outdir/arch/$_carch/boot/"
install -Dm644 "$_outdir/arch/$_carch/boot"/dt.img "$pkgdir"/boot/dt.img
}
sha512sums="ce7447b654bc3a50c7ebb2e97807b60ea738bca31ceef768804592134f6d313f999e203604b269664bacd46be585ff26131d4a9e12c2edef376cc0e825977d1f linux-lg-d851-e9173c6249c1a965b5e0c3a73c4b232f0d19b080.tar.gz
da566e1395639d5908bff1c7bbe31c6f1d8584c7169a718c2afbb6f6ec2d9925fe11c62606bbf2fd30e2f60dd9fd6fb9cc84cf8f2ca68d09978237e76d2314de config-lg-d851.armv7
2b48f1bf0e3f70703d2cdafc47d5e615cc7c56c70bec56b2e3297d3fa4a7a1321d649a8679614553dde8fe52ff1051dae38d5990e3744c9ca986d92187dcdbeb gcc10-extern_YYLOC_global_declaration.patch
7be03a9e78b7ac330a54b1f00509caa0621a95c0c55901878ad757f9dd69cc05ba2c8b5ea987063ae1224f92c4d090d515fa5d369e7755181a4871b0d0f82881 02_gpu-msm-fix-gcc5-compile.patch"