apple-iphone7: new device (Apple iPhone 7/7+) (MR 2289)

Downstream kernel made by Corellium which enables the iPhone 7 to boot.

This is the continuation of my work for a PostmarketOS port based on
@MartijnBraam kernel and devices packages.

PogoOS by the Checkra1n team is used to boot the Linux kernel. Further
instructions will be available in the PostmarketOS Wiki page.

[ci:skip-build] already built successfully in CI
This commit is contained in:
Jonas Heinrich 2021-06-29 15:56:45 +02:00 committed by Clayton Craft
parent 4c666d67aa
commit e87d0ad2a6
No known key found for this signature in database
GPG key ID: 7A3461CA187CEA54
5 changed files with 4822 additions and 0 deletions

View file

@ -0,0 +1,25 @@
# Maintainer: Jonas Heinrich <onny@project-insanity.org>
# Reference: <https://postmarketos.org/devicepkg>
pkgname=device-apple-iphone7
pkgdesc="Apple iPhone 7"
pkgver=0.1
pkgrel=0
url="https://postmarketos.org"
license="MIT"
arch="aarch64"
options="!check !archcheck"
depends="postmarketos-base linux-apple-iphone7 mesa-dri-gallium"
makedepends="devicepkg-dev"
source="deviceinfo"
build() {
devicepkg_build $startdir $pkgname
}
package() {
devicepkg_package $startdir $pkgname
}
sha512sums="
9952d3ee16b580ea1bbf3faef7de0a284d49694bca3dedb44cf89403ff5753163192500ee0d48c83a46544870f4a5408d662d7fa1598e8e67f388ef1745143e2 deviceinfo
"

View file

@ -0,0 +1,22 @@
# Reference: <https://postmarketos.org/deviceinfo>
# Please use double quotes only. You can source this file in shell scripts.
deviceinfo_format_version="0"
deviceinfo_name="Apple iPhone 7"
deviceinfo_manufacturer="Apple"
deviceinfo_codename="apple-iphone7"
deviceinfo_year="2020"
deviceinfo_dtb=""
deviceinfo_modules_initfs=""
deviceinfo_arch="aarch64"
# Device related
deviceinfo_chassis="handset"
deviceinfo_keyboard="false"
deviceinfo_external_storage="false"
deviceinfo_screen_width="750"
deviceinfo_screen_height="1334"
# Bootloader related
deviceinfo_flash_method="none"

View file

@ -0,0 +1,47 @@
# Maintainer: Jonas Heinrich <onny@project-insanity.org>
# Reference: <https://postmarketos.org/vendorkernel>
# Kernel config based on: arch/arm64/configs/hx_h9p_defconfig
pkgname=linux-apple-iphone7
pkgver=5.4.14
pkgrel=0
pkgdesc="Apple iPhone 7 kernel fork"
arch="aarch64"
_carch="arm64"
_flavor="apple-iphone7"
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"
# Source
_commit="0c2f7dda13d67bb7e06123df516f8bdb1000a79b"
_config="config-$_flavor.$arch"
source="
$pkgname-$_commit.tar.gz::https://github.com/corellium/linux-sandcastle/archive/$_commit.tar.gz
$_config
linux4.17-gcc10-extern_YYLOC_global_declaration.patch
"
builddir="$srcdir/linux-sandcastle-$_commit"
prepare() {
default_prepare
REPLACE_GCCH=0 \
. 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="
ba1f1d6b9ab07f0791cfb11f9ff2a7f36f9b43e6eb29cc58d208e7c29237e783408146a460dc93ca514768e593c508d8cd0b04d9c948d98878f8cd15e1633f36 linux-apple-iphone7-0c2f7dda13d67bb7e06123df516f8bdb1000a79b.tar.gz
08df6ad5d3c356ee99fe857fc51e2b0f20fc17f74fe4f3b79783e0950d42850bc5134808456772bee84fbdce60a48983c8f1eeeef54605b1dd202d0575f40d7e config-apple-iphone7.aarch64
27827877040007fc1c4c719f7e2e19e5c272d44972415cfc53feba0313d87e4074f8204bdb13cbc5fe21ea61bf595314b68f10c081e7b7bac3c888b60f008acf linux4.17-gcc10-extern_YYLOC_global_declaration.patch
"

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1 @@
../../.shared-patches/linux/linux4.17-gcc10-extern_YYLOC_global_declaration.patch