From e148650279c18e29787e863102b1de8f0674e4e7 Mon Sep 17 00:00:00 2001 From: Massimo Gaggero Date: Tue, 8 Oct 2024 20:46:38 +0200 Subject: [PATCH] Fixes #2092: provides support for riscv gcc installation on Alpine Linux. --- litex_setup.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/litex_setup.py b/litex_setup.py index 0c0679176..998d330ae 100755 --- a/litex_setup.py +++ b/litex_setup.py @@ -349,6 +349,9 @@ def riscv_gcc_install(): # Arch. elif "arch" in os_release: os.system("pacman -S riscv64-linux-gnu-gcc") + # Alpine. + elif "alpine" in os_release: + os.system("apk add gcc-cross-embedded") # Ubuntu. else: os.system("apt install gcc-riscv64-unknown-elf") @@ -377,6 +380,9 @@ def powerpc_gcc_install(): # Arch (AUR repository). elif "arch" in os_release: os.system("yay -S powerpc64le-linux-gnu-gcc") + # Alpine. + elif "alpine" in os_release: + os.system("apk add gcc binutils-ppc64le") # Ubuntu. else: os.system("apt install gcc-powerpc64le-linux-gnu binutils-multiarch") @@ -400,6 +406,9 @@ def openrisc_gcc_install(): # Arch. elif "arch" in os_release: os.system("pacman -S or1k-elf-gcc") + # Alpine. + elif "alpine" in os_release: + os.system("apk add gcc-cross-embedded") # Ubuntu. else: os.system("apt install gcc-or1k-elf")