-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathrun_onchange_archlinux-install-packages.sh.tmpl
More file actions
44 lines (40 loc) · 1.16 KB
/
Copy pathrun_onchange_archlinux-install-packages.sh.tmpl
File metadata and controls
44 lines (40 loc) · 1.16 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
{{ if .isArch -}}
#!/bin/bash
sudo pacman -Syu --noconfirm
sudo pacman -S --needed --noconfirm base-devel
git clone https://aur.archlinux.org/paru.git ~/paru
cd ~/paru
cat << 'EOF' > paru.patch
diff --git a/PKGBUILD b/PKGBUILD
index f503694..6289b7e 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -9,6 +9,7 @@ backup=("etc/paru.conf")
arch=('i686' 'pentium4' 'x86_64' 'arm' 'armv7h' 'armv6h' 'aarch64')
license=('GPL-3.0-or-later')
makedepends=('cargo')
+makedepends_aarch64=('cargo' 'clang')
depends=('git' 'pacman' 'libalpm.so>=14')
optdepends=('bat: colored pkgbuild printing' 'devtools: build in chroot and downloading pkgbuilds')
sha256sums=('b9c67f1390caacc949c2eb2a254e8cf37778f382c3c6b8d057fa6feb6eaeb0f9')
@@ -29,6 +30,10 @@ build () {
export CARGO_PROFILE_RELEASE_LTO=off
fi
+ if [[ $CARCH = aarch64 ]]; then
+ _features+="generate,"
+ fi
+
cargo build --frozen --features "${_features:-}" --release --target-dir target
./scripts/mkmo locale/
}
EOF
git apply ./paru.patch
makepkg -si --noconfirm
cd ..
rm -rf paru
# Install the listed packages
paru -S --needed --noconfirm \
{{ range .packages.arch.pacman -}}
{{ . | quote }} \
{{ end -}}
{{ end -}}