Skip to content

Commit 7ec03fb

Browse files
committed
Drop service for resizing rootfs, update asound.state, enable bluetooth
1 parent 0bab47a commit 7ec03fb

File tree

6 files changed

+342
-41
lines changed

6 files changed

+342
-41
lines changed

make_empty_image.sh

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,11 @@ if [ -z "$IMAGE_NAME" ]; then
1414
exit 1
1515
fi
1616

17+
if [ "$(id -u)" -ne "0" ]; then
18+
echo "This script requires root (not really - but make_image.sh will fail later without root)"
19+
exit 1
20+
fi
21+
1722
fallocate -l $IMAGE_SIZE $IMAGE_NAME
1823

1924
cat << EOF | fdisk $IMAGE_NAME

make_rootfs.sh

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -100,16 +100,19 @@ killall -KILL gpg-agent
100100
pacman -Sy --noconfirm
101101
pacman -Rsn --noconfirm linux-aarch64
102102
pacman -S --noconfirm --needed dosfstools curl xz iw rfkill netctl dialog wpa_supplicant alsa-utils \
103-
pv linux-pine64 linux-pine64-headers networkmanager dkms-rtl8723cs uboot-pine64-git
103+
pv linux-pine64 linux-pine64-headers networkmanager dkms-rtl8723cs uboot-pine64-git \
104+
rtl8723bt-firmware
104105
105106
# Install XFCE
106107
pacman -S --noconfirm xfce4 xorg-server xf86-input-libinput lxdm ttf-dejavu ttf-liberation firefox \
107108
pulseaudio nm-connection-editor network-manager-applet \
108109
xfce4-pulseaudio-plugin \
110+
blueman pulseaudio-bluetooth \
109111
pulseaudio-alsa pavucontrol
110112
systemctl enable lxdm
111113
systemctl enable NetworkManager
112-
usermod -a -G network,video,audio,optical,storage,input,scanner,games,lp alarm
114+
systemctl enable bluetooth
115+
usermod -a -G network,video,audio,optical,storage,input,scanner,games,lp,rfkill alarm
113116
114117
sed -i 's|^#en_US.UTF-8|en_US.UTF-8|' /etc/locale.gen
115118
cd /usr/share/i18n/charmaps
@@ -130,11 +133,10 @@ rm "$DEST/usr/bin/qemu-arm-static"
130133
mv "$DEST/etc/resolv.conf.dist" "$DEST/etc/resolv.conf"
131134

132135
cp $OTHERDIR/asound.state $DEST/var/lib/alsa
133-
cp $OTHERDIR/pine64_first_boot.sh $DEST/usr/local/sbin/
134136
cp $OTHERDIR/resize_rootfs.sh $DEST/usr/local/sbin/
135-
cp $OTHERDIR/pine64-first-boot.service $DEST/etc/systemd/system/
136137
cp $OTHERDIR/modesetting.conf $DEST/etc/X11/xorg.conf.d/
137138
cp $OTHERDIR/sysrq.conf $DEST/etc/sysctl.d/
139+
cp $OTHERDIR/81-blueman.rules $DEST/etc/polkit-1/rules.d/
138140

139141
echo "Installed rootfs to $DEST"
140142

otherfiles/81-blueman.rules

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
polkit.addRule(function(action, subject) {
2+
if (action.id == "org.blueman.rfkill.setstate" && subject.local && subject.active && subject.isInGroup("wheel")) {
3+
return polkit.Result.YES;
4+
}
5+
if (action.id == "org.blueman.network.setup" && subject.local && subject.active && subject.isInGroup("wheel")) {
6+
return polkit.Result.YES;
7+
}
8+
});

0 commit comments

Comments
 (0)