blob: ee333638d4c032cd17c8b422d07fa6fbb77554a3 (
plain)
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
|
# Maintainer: Jonas Schmid <aur at jonasschmid dot ch>
pkgname=gap-gnu-toolchain
pkgver=1.8
pkgrel=1
pkgdesc="GAP RISC-V Toolchain installer"
arch=('x86_64')
url="https://example.com"
license=('custom')
depends=()
source=("git+https://github.com/GreenWaves-Technologies/gap_gnu_toolchain.git")
md5sums=('SKIP')
# Custom installation directory
pkgdir_default="/opt/riscv"
install_dir=""
prepare() {
msg "Preparing package directory..."
install_dir="${pkgdir_default}"
}
build() {
msg "No compilation needed for this toolchain."
}
package() {
msg "Installing toolchain to the package directory..."
if [ -n "$install_dir" ]; then
install -d "$pkgdir/$install_dir"
else
install -d "$pkgdir/$pkgdir_default"
fi
rsync -av --delete --exclude ".git*" . "$pkgdir/$pkgdir_default"
# Adding a post-install message for .bashrc configuration
post_install_message
}
post_install_message() {
if [ "$install_dir" != "$pkgdir_default" ]; then
echo "Add to $HOME .bashrc or user-wide profile script"
echo "export GAP_RISCV_GCC_TOOLCHAIN=\"$DIR_TOOLCHAIN\""
fi
}
|