2019-06-06 13:57:43 +00:00
|
|
|
# Reference: <https://postmarketos.org/vendorkernel>
|
|
|
|
# Kernel config based on: arch/arm/configs/k2_ul_defconfig
|
|
|
|
|
2020-04-25 09:51:42 +00:00
|
|
|
pkgname=linux-htc-k2ul
|
2019-06-06 13:57:43 +00:00
|
|
|
pkgver=3.4.10
|
*/linux-*: enable CONFIG_CRYPTO_XTS (MR 1405)
Enable CONFIG_CRYPTO_XTS for each kernel, so we can switch to using
aes-xts-plain64 as default cipher for cryptsetup (override with
"pmbootstrap --cipher"), instead of aes-cbc-plain64 (pmbootstrap#1940).
I have executed "pmbootstrap kconfig edit" on each kernel, and manually
toggled the option. The diff is not always clean, because for some
kernels it is apparently the first time, that menuconfig was executed on
the configs like that. In a few instances, it turned out that
CONFIG_ANDROID_PARANOID_NETWORK needed to be disabled too (this is
already a requirement, but as the config was incomplete, it was not
visible that this option was enabled). Very few times, I had to enable
CONFIG_EXPERIMENTAL in order to see and enable CONFIG_CRYPTO_XTS.
It would be great if we could automate such mass kconfig edits in the
future, see pmbootstrap#1942.
[skip ci]: I have verified, that every single one of these kernels builds.
CI will likely run out of time while downloading source tarballs.
2020-07-11 13:24:19 +00:00
|
|
|
pkgrel=2
|
2019-06-06 13:57:43 +00:00
|
|
|
pkgdesc="HTC One SV kernel fork"
|
|
|
|
arch="armv7"
|
|
|
|
_carch="arm"
|
|
|
|
_flavor="htc-k2ul"
|
|
|
|
url="https://kernel.org"
|
|
|
|
license="GPL-2.0-only"
|
2020-04-21 01:24:27 +00:00
|
|
|
options="!strip !check !tracedeps pmb:cross-native"
|
2019-06-06 13:57:43 +00:00
|
|
|
makedepends="perl sed installkernel bash gmp-dev bc linux-headers elfutils-dev devicepkg-dev gcc4"
|
|
|
|
|
|
|
|
# Compiler: GCC 6 (doesn't boot when compiled with newer versions)
|
|
|
|
if [ "${CC:0:5}" != "gcc4-" ]; then
|
|
|
|
CC="gcc4-$CC"
|
|
|
|
HOSTCC="gcc4-gcc"
|
|
|
|
CROSS_COMPILE="gcc4-$CROSS_COMPILE"
|
|
|
|
fi
|
|
|
|
|
|
|
|
# Source
|
|
|
|
# How to get the original version:
|
|
|
|
# 1. Go to HTCDev.com, log in and go to the kernel source page
|
|
|
|
# 2. Select the One SV, EU region and the v4.1.2 Android version
|
|
|
|
# 3. Download the kernel with the 2.14.401.6 description
|
|
|
|
_repository="k2ul-jb-3.4.10-cl157896-2"
|
|
|
|
_commit="6ac3629384fac88beef65fd841f5135f9f832624"
|
2020-02-28 09:59:56 +00:00
|
|
|
_config="config-$_flavor.$arch"
|
2019-06-06 13:57:43 +00:00
|
|
|
source="
|
2020-02-28 09:59:56 +00:00
|
|
|
$pkgname-$_commit.tar.gz::https://github.com/Hacker1245/$_repository/archive/$_commit.tar.gz
|
2019-06-06 13:57:43 +00:00
|
|
|
$_config
|
|
|
|
gcc8-fix-put-user.patch
|
2020-11-09 10:06:09 +00:00
|
|
|
timeconst.pl-Eliminate-Perl-warning.patch
|
2019-06-06 13:57:43 +00:00
|
|
|
fix_return_address.patch
|
|
|
|
no-hardcoded-CROSS_COMPILE.patch
|
|
|
|
fix_otg_errors.patch
|
|
|
|
fix_kgsl_error.patch
|
|
|
|
"
|
2020-02-28 09:59:56 +00:00
|
|
|
builddir="$srcdir/$_repository-$_commit"
|
2019-06-06 13:57:43 +00:00
|
|
|
|
|
|
|
prepare() {
|
|
|
|
default_prepare
|
2020-04-01 07:09:30 +00:00
|
|
|
. downstreamkernel_prepare
|
2019-06-06 13:57:43 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
build() {
|
|
|
|
unset LDFLAGS
|
|
|
|
make ARCH="$_carch" CC="${CC:-gcc}" \
|
|
|
|
KBUILD_BUILD_VERSION="$((pkgrel + 1 ))-postmarketOS"
|
|
|
|
}
|
|
|
|
|
|
|
|
package() {
|
2020-02-18 08:34:06 +00:00
|
|
|
downstreamkernel_package "$builddir" "$pkgdir" "$_carch" "$_flavor"
|
2019-06-06 13:57:43 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
sha512sums="de02e36c7c19c886cc1f16b5a3a4464542a905e85cc3a531bd27b4944ee1ada01aad6e5fe8fd0346b991c923144154fbce8d86b17f69e69d05549440129b2fc9 linux-htc-k2ul-6ac3629384fac88beef65fd841f5135f9f832624.tar.gz
|
*/linux-*: enable CONFIG_CRYPTO_XTS (MR 1405)
Enable CONFIG_CRYPTO_XTS for each kernel, so we can switch to using
aes-xts-plain64 as default cipher for cryptsetup (override with
"pmbootstrap --cipher"), instead of aes-cbc-plain64 (pmbootstrap#1940).
I have executed "pmbootstrap kconfig edit" on each kernel, and manually
toggled the option. The diff is not always clean, because for some
kernels it is apparently the first time, that menuconfig was executed on
the configs like that. In a few instances, it turned out that
CONFIG_ANDROID_PARANOID_NETWORK needed to be disabled too (this is
already a requirement, but as the config was incomplete, it was not
visible that this option was enabled). Very few times, I had to enable
CONFIG_EXPERIMENTAL in order to see and enable CONFIG_CRYPTO_XTS.
It would be great if we could automate such mass kconfig edits in the
future, see pmbootstrap#1942.
[skip ci]: I have verified, that every single one of these kernels builds.
CI will likely run out of time while downloading source tarballs.
2020-07-11 13:24:19 +00:00
|
|
|
77f8544dcc2d796a723d107646f3336b18cb9b497698c5e5b1229b3970329f7730ea8be14feabc7c9e406d509341c7eed81a7a0e5227de50355594338d7abff1 config-htc-k2ul.armv7
|
2019-06-06 13:57:43 +00:00
|
|
|
197d40a214ada87fcb2dfc0ae4911704b9a93354b75179cd6b4aadbb627a37ec262cf516921c84a8b1806809b70a7b440cdc8310a4a55fca5d2c0baa988e3967 gcc8-fix-put-user.patch
|
2020-11-09 10:06:09 +00:00
|
|
|
1fcfb5f06a2bfdcc55d53054ca80d1b989599a39a5379d057a0724fc405187d74da4309a650e70b9c79d39444e81923cfc5c9199ed8c0a77c83dcd7998446bb7 timeconst.pl-Eliminate-Perl-warning.patch
|
2019-06-06 13:57:43 +00:00
|
|
|
b0a73e261b6dedfe6135a17d25e9e989958b4ae379ba31abbf9b0e05f50f3082c4f5d4ff4fb848e8d283acbf68c54014ac8cfcc57d4e1be2d456e715237b661c fix_return_address.patch
|
|
|
|
555033f2ef3e23d84a552e92a6307bf292f91146ee4d8a03b2485f9b5028c2aa3f7ced6ef268acaca7d12649f4bfa7f8fccca39394097f63a5ff2134b912e9e2 no-hardcoded-CROSS_COMPILE.patch
|
|
|
|
f6229e37304d127cd39bbbd6f0e11100ca8c6b44f1e66b125aba06d7d5ae96d380273e55a7a8fec46af324979523e032de9151d92e181da9242fb5aaf0dba769 fix_otg_errors.patch
|
|
|
|
c84d3eb75628ee37ad5d16f858bdbf7b9fc2ff1336e5d91559ecdc4d198127b25929c3b264a50f526fafd3722aa39fb2d87fedcfb3a134f2ddd355650a65a4bd fix_kgsl_error.patch"
|