Compare commits

...
Author SHA1 Message Date
Caleb Connolly aab8234d6b main/postmarketos-base-eink: new aport (MR 2910)
Add a base package to provide some e-ink specific opinionated defaults.
2022-09-20 14:34:59 +00:00
Caleb Connolly c7583c1474 main/devicepkg-dev: fail if the splash config can't be found (MR 2910) 2022-09-20 14:34:59 +00:00
Caleb Connolly a465114837 device/testing/device-pine64-pinenote: new aport (MR 2910) 2022-09-20 14:34:59 +00:00
Caleb Connolly c7762ec381 device/testing/firmware-pine64-pinenote: new aport (MR 2910) 2022-09-20 14:34:59 +00:00
Caleb Connolly a20092d533 device/testing/linux-pine64-pinenote: new aport (MR 2910) 2022-09-20 14:34:59 +00:00
Caleb Connolly 21bc3e7566 device/.shared-configs: introduce a shared configs dir (MR 2910)
Following the idea of .shared-patches, configs which are common to a lot
of devices can be put here and then symlinked to the device packages.

The first use-case is a custom splash config for e-ink devices.
2022-09-20 14:34:59 +00:00
15 changed files with 5833 additions and 2 deletions

No files matched your search

@@ -0,0 +1,19 @@
# This file isn't actually packaged, it's used at build-time
# to generate the splash screen for e-ink.
[background]
color=#fff
[name]
text=postmarketOS
font=/usr/share/fonts/ttf-droid/DroidSans.ttf
color=#000
[logo]
text=
font=/usr/share/fonts/ttf-pmos/pmos.ttf
color=#000
spacing=1
[text]
font=/usr/share/fonts/ttf-droid/DroidSans.ttf
color=#222
@@ -0,0 +1,52 @@
# Maintainer: Caleb Connolly <caleb@connolly.tech>
pkgname=device-pine64-pinenote
pkgdesc="Pine64 PineNote"
pkgver=1
pkgrel=0
url="https://postmarketos.org"
license="MIT"
arch="aarch64"
options="!check !archcheck"
depends="
linux-pine64-pinenote
mesa-dri-gallium
postmarketos-base
"
# jankily depend on the firmware package to overwrite
# the postmarketos-splash config
makedepends="devicepkg-dev"
source="deviceinfo
extlinux.conf
rootston.ini
"
subpackages="$pkgname-nonfree-firmware:nonfree_firmware $pkgname-phosh"
build() {
SPLASH_CONFIG="$startdir"/splash.ini devicepkg_build $startdir $pkgname
}
package() {
devicepkg_package $startdir $pkgname
install -Dm644 "$srcdir"/extlinux.conf "$pkgdir"/boot/extlinux.conf
}
nonfree_firmware() {
pkgdesc="WiFi, Bluetooth and display firmware"
depends="firmware-pine64-pinenote"
mkdir "$subpkgdir"
}
phosh() {
install_if="$pkgname=$pkgver-r$pkgrel phosh"
depends="postmarketos-theme"
install -Dm644 "$srcdir"/rootston.ini \
"$subpkgdir"/etc/phosh/rootston.ini
}
sha512sums="
3e1e22c875f52fb28282b1256f21cc2a83d52f5e2bdf74ec7b9ee0c746d2361b286843d21704ac1e2a4b1a32292535deb581b64c40f75d9d0ec6c66706acd190 deviceinfo
2aa3851b6a176cda5fd04a48e0ba2284c53e44f176cb3ee6dd382b590772d3decbf2eae8a87ed70f3f94caf11670a3ffdfa216381dbd37665cd81869af0cf5c9 extlinux.conf
20f50e7e786a35583ee1652ba3a0d250c169f7cc434adb679370593099362a956d6ee7bbc8c932c713eefd51a503c701ece19b536dc1cf56c2975595f049d153 rootston.ini
"
@@ -0,0 +1,30 @@
# Reference: <https://postmarketos.org/deviceinfo>
# Please use double quotes only. You can source this file in shell
# scripts.
deviceinfo_format_version="0"
deviceinfo_name="Pine64 PineNote"
deviceinfo_manufacturer="Pine64"
deviceinfo_codename="pine64-pinenote"
deviceinfo_year="2021"
deviceinfo_dtb="rockchip/rk3566-pinenote"
deviceinfo_arch="aarch64"
deviceinfo_gpu_accelerated="true"
# Device related
deviceinfo_chassis="tablet"
deviceinfo_keyboard="false"
deviceinfo_external_storage="false"
deviceinfo_screen_width="1872"
deviceinfo_screen_height="1404"
deviceinfo_getty="ttyS2;1500000"
# initfs
deviceinfo_modules_initfs="tps65185-regulator rockchip_ebc drm_kms_helper drm_shmem_helper pvi_waveform"
# Bootloader related
deviceinfo_flash_method="rkdeveloptool"
deviceinfo_flash_sparse="true"
deviceinfo_flash_rk_partition_kernel="cache"
deviceinfo_flash_rk_partition_system="userdata"
@@ -0,0 +1,9 @@
timeout 10
default postmarketOS
menu title boot prev kernel
label POSTMARKETOS
kernel /vmlinuz
fdt /rk3566-pinenote.dtb
initrd /initramfs
append earlycon console=tty0 console=ttyS2,1500000n8 PMOS_NO_OUTPUT_REDIRECT vt.default_red=0xFF,0xBC,0x4F,0xB4,0x56,0xBC,0x4F,0x00,0xA1,0xCF,0x84,0xCA,0x8D,0xB4,0x84,0x68 vt.default_grn=0xFF,0x55,0xBA,0xBA,0x4D,0x4D,0xB3,0x00,0xA0,0x8F,0xB3,0xCA,0x88,0x93,0xA4,0x68 vt.default_blu=0xFF,0x58,0x5F,0x58,0xC5,0xBD,0xC5,0x00,0xA8,0xBB,0xAB,0x97,0xBD,0xC7,0xC5,0x68 PMOS_FORCE_PARTITION_RESIZE
@@ -0,0 +1,6 @@
# /etc/phosh/rootston.ini
# Overwrites values set in /usr/share/phosh/phoc.ini
# e-ink is an "Unknown" display type for now in mainline
[output:Unknown-1]
scale = 2.0
+1
View File
@@ -0,0 +1 @@
../../.shared-configs/postmarketos-splash-eink.ini
@@ -0,0 +1 @@
/lib/firmware/waveform.bin
@@ -0,0 +1,30 @@
# Maintainer: Caleb Connolly <caleb@connolly.tech>
pkgname=firmware-pine64-pinenote
pkgver=1
pkgrel=0
pkgdesc="Firmware for OnePlus 5/5T"
url="https://gitlab.com/calebccff/firmware-pine64-pinenote"
arch="aarch64"
license="proprietary"
options="!check !archcheck !strip !tracedeps pmb:cross-native"
_commit="6676e4cabf5f68062da86ef528ac033507f02529"
source="https://gitlab.com/calebccff/firmware-pine64-pinenote/-/archive/$_commit/firmware-pine64-pinenote-$_commit.tar.gz
30-eink-waveform.files
"
package() {
install -Dm644 "$srcdir/30-eink-waveform.files" \
"$pkgdir/etc/postmarketos-mkinitfs/files/30-eink-waveform.files"
cd "$srcdir/$pkgname-$_commit/"
install -Dm644 waveform.bin "$pkgdir"/lib/firmware/waveform.bin
install -Dm644 brcm/BCM4345C0_cy.hcd "$pkgdir"/lib/firmware/brcm/BCM4345C0_cy.hcd
install -Dm644 brcm/BCM4345C0.hcd "$pkgdir"/lib/firmware/brcm/BCM4345C0.hcd
install -Dm644 brcm/fw_bcm43455c0_ag_cy.bin "$pkgdir"/lib/firmware/brcm/brcmfmac43455-sdio.bin
install -Dm644 brcm/nvram_ap6255_cy.txt "$pkgdir"/lib/firmware/brcm/brcmfmac43455-sdio.txt
}
sha512sums="
645df0df980a2595f6d7afc2a2477c1754a8e23f10a35f656c03410ad2e0e932d1501e648fcf8f1b22cf0c1e7b24b9a3eab3304780622701e343b89580ee1a54 firmware-pine64-pinenote-6676e4cabf5f68062da86ef528ac033507f02529.tar.gz
ac55feed7d5e719ef6aa0e04021e1a8f7d7f9bf87d9b1287f444f598e85d627c5f4b2dee83b0149f76ccdb5867003728675f72602972b01a215868a7abbfd526 30-eink-waveform.files
"
@@ -0,0 +1,58 @@
# Reference: <https://postmarketos.org/vendorkernel>
# Kernel config based on: arch/arm64/configs/pinenote_defconfig
pkgname=linux-pine64-pinenote
pkgver=5.17_rc7
pkgrel=0
pkgdesc="Pine64 PineNote close to mainline fork"
arch="aarch64"
_carch="arm64"
_flavor="pine64-pinenote"
url="https://kernel.org"
license="GPL-2.0-only"
options="!strip !check !tracedeps pmb:cross-native"
makedepends="bison findutils flex installkernel openssl-dev perl"
# Source
_repo="linux"
_commit="2d1ab1f1c2c01b45d22d78260c08c8da8ef396eb"
_config="config-$_flavor.$arch"
source="
$pkgname-$_commit.tar.gz::https://gitlab.com/pine64-org/$_repo/-/archive/$_commit/$_repo-$_commit.tar.gz
$_config
"
builddir="$srcdir/$_repo-$_commit"
prepare() {
default_prepare
cp "$srcdir/config-$_flavor.$arch" .config
}
build() {
unset LDFLAGS
make ARCH="$_carch" CC="${CC:-gcc}" \
KBUILD_BUILD_VERSION="$((pkgrel + 1 ))-$_flavor"
}
package() {
mkdir -p "$pkgdir"/boot
install -Dm644 "$builddir/arch/$_carch/boot/Image" \
"$pkgdir/boot/vmlinuz"
make modules_install dtbs_install \
ARCH="$_carch" \
INSTALL_PATH="$pkgdir"/boot/ \
INSTALL_MOD_PATH="$pkgdir" \
INSTALL_MOD_STRIP=1 \
INSTALL_DTBS_PATH="$pkgdir"/usr/share/dtb
rm -f "$pkgdir"/lib/modules/*/build "$pkgdir"/lib/modules/*/source
install -D "$builddir"/include/config/kernel.release \
"$pkgdir"/usr/share/kernel/$_flavor/kernel.release
}
sha512sums="
0061d6a4a7dcbf1ad5ad57d4691f24d78bf4372f278484be668484c4d82d0a10ce26c5ad8b21546fc196f2dc3864b11921af835ad49a50bc91aa8bc8816d2fda linux-pine64-pinenote-2d1ab1f1c2c01b45d22d78260c08c8da8ef396eb.tar.gz
7a7e3defa0d232c7b507cf9395fac33a0f2e8bde7341fb89c4f95f87e0d87f60c05cf48ee431a9170f14cdbeeee3685f6861dec992e2292fd7a7c13ebcfd32d3 config-pine64-pinenote.aarch64
"
File diff suppressed because it is too large. Load diff
+2 -2
View File
@@ -1,6 +1,6 @@
pkgname=devicepkg-dev
pkgver=0.13.2
pkgrel=0
pkgrel=1
pkgdesc="Provides default device package functions"
url="https://postmarketos.org"
arch="all"
@@ -62,7 +62,7 @@ package() {
}
sha512sums="
d69930dd790b00fb39760a37d95a10899f0d167e10e2804feb05d9ce04f94185dc32d36edc90214aba2ea2aa09bf18f7dab93f1d2eff23f67beb2cc83be30e7c compiler-gcc.h
77dcc7bc4f90bc11f99b7bb88be171f706f7d92921b694ce862d31ab858a4b8850c9e0bdb68299ffce9f934a3c8ab16eb307fd09534085e65f0101334bd68a9d devicepkg_build.sh
c47435bc1638bbe1c6e3f829fb1998c4938baef821ffb0dd1ef312cc8b53aede53a43db43b5027c6a3368d013a6ecc15a4a836be8a77aca966892f3296d92d39 devicepkg_build.sh
74c1b9b265a943604d5d538ca66d4b7bcad9adcf40710ab19d795b55aac39669bf1089f7f0ec81aa7a01b537784bef4310e4acc3d7a6ba1f282ab01652bdc4d4 devicepkg_package.sh
53aa129da5bd52376271bbd37ed7205f2dac971d442c5085260ed1c4a9b014a656cbe28ea45d242be60a2d0f8851611f3b8352c880c017995cda6ae093e5d324 downstreamkernel_prepare.sh
107242a3da38a574c46cb779e0c75afbeef4cfe659e1b85971973ac55843df06f70f53a5985ca623d4123f05f2984f5dace4a53a3509ecefd7dfdc3c8b705cfe downstreamkernel_package.sh
+5
View File
@@ -27,6 +27,11 @@ generate_splash_screens()
splash_width=${deviceinfo_screen_width:-720}
splash_height=${deviceinfo_screen_height:-1280}
if [ ! -f "$splash_config" ]; then
echo "ERROR: Can't find splash config \"$splash_config\""
exit 1
fi
# Overwrite $@ to easily iterate over the splash screens. Format:
# $1: splash_name
# $2: text
@@ -0,0 +1,2 @@
[org.gnome.desktop.interface]
gtk-theme='HighContrast'
+34
View File
@@ -0,0 +1,34 @@
# Maintainer: Caleb Connolly <caleb@connolly.tech>
pkgname=postmarketos-base-eink
pkgver=1
pkgrel=0
pkgdesc="Base package with some opinionated default for e-ink devices"
# It's worth emphasising the word "opinionated" here, e-ink has some
# obvious differences compared to regular displays, there are cases
# where it clearly makes sense to adjust default behaviour. However
# not everyone may agree with these. It should be easy for the user to
# override changes here easily, ideally without having to resort to a
# terminal.
url="https://postmarketos.org"
arch="noarch"
license="GPL-3.0-or-later"
options="!check"
source="
postmarketos-splash-eink.ini
001-eink-gschema.override
"
subpackages="$pkgname-phosh"
builddir="$srcdir/"
package() {
install -Dm644 "$srcdir/postmarketos-splash-eink.ini" \
-t "$pkgdir/etc/postmarketos/"
}
phosh() {
# For now phosh hardcodes some colors (like making the quick settings white)
# when using high contrast, so it's a better option than the postmarketOS-paper
# theme for now
install -Dm644 "$srcdir"/001-eink-gschema.override \
"$pkgdir"/usr/share/glib-2.0/schemas/001-eink.gschema.override
}
@@ -0,0 +1,17 @@
[background]
color=#fff
[name]
text=postmarketOS
font=/usr/share/fonts/ttf-droid/DroidSans.ttf
color=#000
[logo]
text=
font=/usr/share/fonts/ttf-pmos/pmos.ttf
color=#000
spacing=1
[text]
font=/usr/share/fonts/ttf-droid/DroidSans.ttf
color=#222