pmaports/device/testing/linux-htc-leo/APKBUILD
2020-11-02 16:17:08 +01:00

53 lines
1.8 KiB
Text

# Reference: <https://postmarketos.org/vendorkernel>
# Kernel config based on: arch/arm/configs/htcleo_defconfig
pkgname=linux-htc-leo
pkgver=3.0.4
pkgrel=0
pkgdesc="HTC HD2 kernel fork"
arch="armv7"
_carch="arm"
_flavor="htc-leo"
url="https://kernel.org"
license="GPL-2.0-only"
options="!strip !check !tracedeps pmb:cross-native"
makedepends="bash bc bison devicepkg-dev flex openssl-dev perl gcc4 gcc-armv7"
# Compiler: GCC4. Doesn't boot with newer versions of GCC
if [ "${CC:0:5}" != "gcc4-" ]; then
CC="gcc4-$CC"
HOSTCC="gcc4-gcc"
CROSS_COMPILE="gcc4-$CROSS_COMPILE"
fi
# Source
#_repository="android_kernel_htc_qsd8k"
#_commit="917cc470bb9c5ef1655ecb49357db4917eaa8957"
_repository="android_kernel_htc_htcleo"
_commit="fb2ba086ea96647f38539664ebf0aa6eca61d7bb"
_config="config-$_flavor.$arch"
source="
$pkgname-$_commit.tar.gz::https://github.com/qsd8k-legacy/$_repository/archive/$_commit.tar.gz
$_config
01-fix-compiler-path.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"
}
sha512sums="5f324b69ff30284c0aabf16f9580726470eb54ce7edf6066e22d41d92e8be05085f9fb38fddeceee9cec4fb30cd68dda51585ff73ffbd4d52b154956aa81603e linux-htc-leo-fb2ba086ea96647f38539664ebf0aa6eca61d7bb.tar.gz
b4e0b06f16c1a950e9b95296b647a234cba5edc55701cd74297dd92d12c309d7a8b681022edd8e8e2fed739412a2af1b81210ccfcaa90090c3a83f017e41f760 config-htc-leo.armv7
4166bdd725a00577c1319f1103ad802fc4699da3b5aae247c77b035880d21925d16c4faece72e93f59c933774dd912fc08082b07af03a90b664b7fa2865a61bc 01-fix-compiler-path.patch"