2018-10-19 13:54:21 +00:00
|
|
|
# Reference: <https://postmarketos.org/vendorkernel>
|
2018-07-03 21:45:17 +00:00
|
|
|
# Kernel config based on: arch/arm/configs/lineageos_nicki_defconfig
|
|
|
|
|
|
|
|
pkgname="linux-sony-nicki"
|
|
|
|
pkgver=3.4.0
|
2018-11-30 16:51:42 +00:00
|
|
|
pkgrel=2
|
2018-07-03 21:45:17 +00:00
|
|
|
pkgdesc="Sony Xperia M kernel fork"
|
2019-01-12 12:26:44 +00:00
|
|
|
arch="armv7"
|
2018-07-03 21:45:17 +00:00
|
|
|
_carch="arm"
|
|
|
|
_flavor="sony-nicki"
|
|
|
|
url="https://kernel.org"
|
2018-10-19 13:54:21 +00:00
|
|
|
license="GPL-2.0-only"
|
2018-07-03 21:45:17 +00:00
|
|
|
options="!strip !check !tracedeps"
|
2018-10-19 13:54:21 +00:00
|
|
|
makedepends="perl sed installkernel bash gmp-dev bc linux-headers elfutils-dev devicepkg-dev"
|
2018-10-01 06:44:18 +00:00
|
|
|
|
2018-10-19 13:54:21 +00:00
|
|
|
# Compiler: latest GCC from Alpine
|
|
|
|
HOSTCC="${CC:-gcc}"
|
|
|
|
HOSTCC="${HOSTCC#${CROSS_COMPILE}}"
|
2018-07-03 21:45:17 +00:00
|
|
|
|
|
|
|
# Source
|
|
|
|
_repository="android_kernel_sony_msm8x27"
|
|
|
|
_commit="627687e4625d208248fe5fa40dcaaeb3363dfce7"
|
|
|
|
_config="config-${_flavor}.${arch}"
|
|
|
|
source="
|
|
|
|
$pkgname-$_commit.tar.gz::https://github.com/LineageOS/${_repository}/archive/${_commit}.tar.gz
|
|
|
|
$_config
|
|
|
|
00_fix_return_address.patch
|
|
|
|
01_fix_video_argb_setting.patch
|
|
|
|
02_mdss_fb_refresh_rate.patch
|
|
|
|
03_kgsl_iommu_sync_lock.patch
|
|
|
|
04_psmouse_base.patch
|
|
|
|
05_try_to_make_kgsl_work.patch
|
2018-10-19 13:54:21 +00:00
|
|
|
gcc7-give-up-on-ilog2-const-optimizations.patch
|
|
|
|
gcc8-fix-put-user.patch
|
2019-01-12 12:26:44 +00:00
|
|
|
kernel-use-the-gnu89-standard-explicitly.patch
|
2018-07-03 21:45:17 +00:00
|
|
|
"
|
|
|
|
builddir="$srcdir/${_repository}-${_commit}"
|
|
|
|
|
|
|
|
prepare() {
|
|
|
|
default_prepare
|
2018-10-19 13:54:21 +00:00
|
|
|
downstreamkernel_prepare "$srcdir" "$builddir" "$_config" "$_carch" "$HOSTCC"
|
2018-07-03 21:45:17 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
build() {
|
|
|
|
unset LDFLAGS
|
|
|
|
make ARCH="$_carch" CC="${CC:-gcc}" \
|
|
|
|
KBUILD_BUILD_VERSION="$((pkgrel + 1 ))-postmarketOS"
|
|
|
|
}
|
|
|
|
|
|
|
|
package() {
|
|
|
|
# kernel.release
|
|
|
|
install -D "$builddir/include/config/kernel.release" \
|
|
|
|
"$pkgdir/usr/share/kernel/$_flavor/kernel.release"
|
|
|
|
|
|
|
|
# zImage (find the right one)
|
|
|
|
cd "$builddir/arch/$_carch/boot"
|
|
|
|
_target="$pkgdir/boot/vmlinuz-$_flavor"
|
|
|
|
for _zimg in zImage-dtb Image.gz-dtb *zImage Image; do
|
|
|
|
[ -e "$_zimg" ] || continue
|
|
|
|
msg "zImage found: $_zimg"
|
|
|
|
install -Dm644 "$_zimg" "$_target"
|
|
|
|
break
|
|
|
|
done
|
|
|
|
if ! [ -e "$_target" ]; then
|
|
|
|
error "Could not find zImage in $PWD!"
|
|
|
|
return 1
|
|
|
|
fi
|
|
|
|
}
|
|
|
|
|
|
|
|
sha512sums="cb1132c1add4c87490889ca20924f92bc89d646b2efefe023802c22e0167a2cfd39fdcbf7316f957ba4c93fe7318079df8dea5657aac92710ddcd45bfa7977f8 linux-sony-nicki-627687e4625d208248fe5fa40dcaaeb3363dfce7.tar.gz
|
2019-01-12 12:26:44 +00:00
|
|
|
a8a5c8f8038ef82798bb6f8e5ef04198c4ef5ef04d4d25277f40eab874849a874ae66f9b7bb3935eaefef38124d4f26d9bdbcaef627f63c32cc948eeb6c5cdc9 config-sony-nicki.armv7
|
2018-07-03 21:45:17 +00:00
|
|
|
ea1d3b5a234fa565e3c1a792de48f4fc4e6023d281d303c8e319c7ef28edc5739ab0e4dea0139a41f0a5c7d03e27921ccaa214fd0ac5c72245a094ce60128864 00_fix_return_address.patch
|
|
|
|
e3083c260ed9c4fc0d83f43106700b6173876dbfae072f6e6696ac6785a4dc17771fbcb3e21601e04ed29a11bf0f7a2a09ad549375e0c34cea245c7f2e2bcbbd 01_fix_video_argb_setting.patch
|
|
|
|
a8c955bf718f155011e980f3d0948be98e1fee5649f418299a4851780543019daf7afa406aa7b0829375645107e4e6fbf241026b0cabe2b2ac895a47df83d2d8 02_mdss_fb_refresh_rate.patch
|
|
|
|
448bad436377a22c93ac401b9aecb504fe8e84b9511a3dd28f3cc125f3725cc1168ef03dee9f8f1085a9fbb7910b9e75cd25a382ccce626b427c8e27f7c17ffc 03_kgsl_iommu_sync_lock.patch
|
|
|
|
f7e31cfe422696922aec52002e56c58103183966edee3bb8e1995d33f8d37b07c32280a8ecc213874e358a6ff367418556a4542fba7e3c17e4b8e82e05c3a543 04_psmouse_base.patch
|
|
|
|
270aa134a7040409cf2ec5502939b8aa68470c47eeb2bef8f378aa2758a8b546b79018298a81625351f1c06241d8f76bf016793474f58b888db7871a5d745801 05_try_to_make_kgsl_work.patch
|
2018-10-19 13:54:21 +00:00
|
|
|
77eba606a71eafb36c32e9c5fe5e77f5e4746caac292440d9fb720763d766074a964db1c12bc76fe583c5d1a5c864219c59941f5e53adad182dbc70bf2bc14a7 gcc7-give-up-on-ilog2-const-optimizations.patch
|
2019-01-12 12:26:44 +00:00
|
|
|
197d40a214ada87fcb2dfc0ae4911704b9a93354b75179cd6b4aadbb627a37ec262cf516921c84a8b1806809b70a7b440cdc8310a4a55fca5d2c0baa988e3967 gcc8-fix-put-user.patch
|
|
|
|
ad0182a483791fc88e058838bc331b2f04a75ba291e763767babdb815efadfc3b4fda97e69e2e3f00a426cabea088e35297a92bd287592597d1e309be68ee92c kernel-use-the-gnu89-standard-explicitly.patch"
|