device/device-xiaomi-santoni: tidy up device folder (!941)

This commit is contained in:
Danct12 2020-02-10 18:44:59 +07:00 committed by Alexey Min
parent a361dda9ee
commit 0d82bb48dd
No known key found for this signature in database
GPG key ID: 463F84201DACD7B9
11 changed files with 25 additions and 44 deletions

View file

@ -8,7 +8,7 @@
pkgname="device-xiaomi-santoni"
pkgdesc="Xiaomi Redmi 4X"
pkgver=0.5
pkgrel=3
pkgrel=4
url="https://postmarketos.org"
license="MIT"
arch="aarch64"
@ -19,18 +19,19 @@ subpackages="$pkgname-nonfree-firmware:nonfree_firmware
$pkgname-nonfree-userland:nonfree_userland
$pkgname-hybris:hybris
$pkgname-hybris-x11:hybris_x11"
source="deviceinfo
90-device-xiaomi-santoni-audio.rules
HiFi
fb.modes
source="
hybris/10-santoni-android-x11.conf
hybris/70-santoni-android.rules
hybris/fstab.android
misc/100-charging.rules
misc/charging.sh
misc/discharging.sh
ucm/90-device-xiaomi-santoni-audio.rules
ucm/HiFi
ucm/msm8920-sku7-snd-card.conf
deviceinfo
directfbrc
100-charging.rules
charging.sh
discharging.sh
msm8920-sku7-snd-card.conf
fstab.android
70-santoni-android.rules
10-santoni-android-x11.conf"
fb.modes"
build() {
devicepkg_build $startdir $pkgname
@ -70,7 +71,7 @@ nonfree_firmware() {
}
nonfree_userland() {
pkgdesc="Pulls libhybris (Android) hardware adaptation"
pkgdesc="Pulls libhybris (Android) hardware adaptation, see the device's wiki page for post-install."
depends="$pkgname-hybris"
mkdir "$subpkgdir"
}
@ -84,15 +85,15 @@ hybris() {
# Android mounts (needed for loading firmware and configs from android container)
# Appended to fstab in post-install script
install -Dm644 "$startdir"/fstab.android "$subpkgdir"/etc/fstab.android
install -Dm644 "$srcdir"/fstab.android "$subpkgdir"/etc/fstab.android
# Android udev rules, depend on android users and groups presence
install -Dm644 "$startdir"/70-santoni-android.rules \
install -Dm644 "$srcdir"/70-santoni-android.rules \
"$subpkgdir"/etc/udev/rules.d/70-santoni-android.rules
}
hybris_x11() {
pkgdesc="x11 modules for libhybris adaptation"
pkgdesc="X11 modules for libhybris adaptation"
depends="hybris-base-x11-caf"
install_if="$pkgname-hybris xorg-server"
@ -101,15 +102,15 @@ hybris_x11() {
"$subpkgdir"/etc/X11/xorg.conf.d/10-santoni-android-x11.conf
}
sha512sums="14fbe0d7a1e96c87c54df12450bfc03bae8e2e2ea681649a9ef258498d54b3c130b29cd02cec86906f1445d26139dd0ce5dbb559724540dc6d0f038533ef4a3f deviceinfo
dc4bf7871307e659f220aebc3c9f7d74b861f46e1f3df1be37d724af984e46d91e553dbd36c2bd4482aa17dbe4d76d28dabe214952638f00830907466b110146 90-device-xiaomi-santoni-audio.rules
1d2f98a9570212d3026c9565754337574ae046ad4de90265029b7e4a7cd4a2df473ca18ea41d1730f0a01046b40d343446fc88f5d70a1050e0dc578ad460f941 HiFi
b634d13cac1f10535a31c142c7391986ab402ae9910d8093989920f4c2dbd63722ee8595f11962bffd9d314e2835a1ead955a91355856f044911ddcf1e428427 fb.modes
3db3ec596e159be926ea2b5b2496c18e9bc7be24a64a232a56c89a0c9ee710aa2efb2b6fa9fc08efa34759e8242e6c629d08a4ce688ec8aa125830717c191515 directfbrc
sha512sums="dc68956408da82ac9775f23814fb6e1498e65a4c760ceda369a60a202cfc92ad27761d6da27f1802307042affc8a1925c576816a8acbf394dd6a15f32e3ea3c0 10-santoni-android-x11.conf
7c0cda58ddc36e8a6120ce969c1e7afc445817e20b38a4c33e986d3d584bcf0fbb4d82eeda4dab5abdf3429845621a4ffa155512f40e885be615042faf1de171 70-santoni-android.rules
8419c1c5d20bc7c7e4d8d72ec2848655526f99cabf9037ae1f7152f5df31363b70b724769225a88c1d614bea6ebe4ee24190702ea947229a843cc2884eac7175 fstab.android
7b1b138372cb173be38e820a1c386c3d30930d6753303478ae08c1362de3099d81c26eb2b833c5a0b340a82d821bd53309058ecb9b62e00c7ff323b632af2346 100-charging.rules
c4853babd5cd6371297e5e5d64364c064d540cd4beaba06d79b1001fe5c78fe3ee8bc5f6f4ba3e383743a09263028abc55f41bad45240b1c505e27ed087725c9 charging.sh
6012be4184af6c4f12f9b20a6f2d377ebd72b9b334df4fbb921ed9d8da865633631f77d19b02748ebee70442e2f3ffcb6af511ee5deaa40635bc53730c301076 discharging.sh
dc4bf7871307e659f220aebc3c9f7d74b861f46e1f3df1be37d724af984e46d91e553dbd36c2bd4482aa17dbe4d76d28dabe214952638f00830907466b110146 90-device-xiaomi-santoni-audio.rules
1d2f98a9570212d3026c9565754337574ae046ad4de90265029b7e4a7cd4a2df473ca18ea41d1730f0a01046b40d343446fc88f5d70a1050e0dc578ad460f941 HiFi
6cbe9079b6eb1fc889fbb13d8b3da620b39abde3e93e2301601e5416fda8b768aa11876238378af6571ddc3c4ce662dd49f1491cbe8b96153451ffdc7b761926 msm8920-sku7-snd-card.conf
8419c1c5d20bc7c7e4d8d72ec2848655526f99cabf9037ae1f7152f5df31363b70b724769225a88c1d614bea6ebe4ee24190702ea947229a843cc2884eac7175 fstab.android
7c0cda58ddc36e8a6120ce969c1e7afc445817e20b38a4c33e986d3d584bcf0fbb4d82eeda4dab5abdf3429845621a4ffa155512f40e885be615042faf1de171 70-santoni-android.rules
dc68956408da82ac9775f23814fb6e1498e65a4c760ceda369a60a202cfc92ad27761d6da27f1802307042affc8a1925c576816a8acbf394dd6a15f32e3ea3c0 10-santoni-android-x11.conf"
14fbe0d7a1e96c87c54df12450bfc03bae8e2e2ea681649a9ef258498d54b3c130b29cd02cec86906f1445d26139dd0ce5dbb559724540dc6d0f038533ef4a3f deviceinfo
3db3ec596e159be926ea2b5b2496c18e9bc7be24a64a232a56c89a0c9ee710aa2efb2b6fa9fc08efa34759e8242e6c629d08a4ce688ec8aa125830717c191515 directfbrc
b634d13cac1f10535a31c142c7391986ab402ae9910d8093989920f4c2dbd63722ee8595f11962bffd9d314e2835a1ead955a91355856f044911ddcf1e428427 fb.modes"

View file

@ -23,23 +23,3 @@ mkdir -p /firmware
# /vendor symlink (points to nowhere until /system is mounted)
ln -s /system/vendor /vendor
# Since Android audio HAL on this device doesn't like to be unloaded,
# we need to stop PA from exit too.
DEFAULT_PA=/etc/pulse/daemon.conf
L1="exit-idle-time = -1"
append_line() {
FN=$1
LINE=$2
if ! grep -q "${LINE}" "${FN}"; then
echo "Adding $LINE..."
echo "${LINE}" >> "${FN}"
else
echo "Not adding ${LINE}"
fi
}
if [ -f ${DEFAULT_PA} ]; then
append_line "${DEFAULT_PA}" "${L1}"
fi