avr_setup.sh 842 B

1234567891011121314151617181920212223
  1. #!/usr/bin/env bash
  2. # This script will attempt to setup the Linux dependencies for compiling QMK/TMK
  3. # This could probably go much lower, but since we are including an Arch vagrant,
  4. # making it the first match makes sense
  5. if [[ -n "$(type -P pacman )" ]]; then
  6. # Arch linux and derivatives like Apricity
  7. pacman -S --needed --noconfirm base-devel avr-gcc avr-binutils avr-libc dfu-utils
  8. elif [[ -n "$(type -P apt-get)" ]]; then
  9. # Debian and derivatives
  10. apt-get install -y build-essential gcc unzip wget zip gcc-avr binutils-avr avr-libc
  11. elif [[ -n "$(type -P yum)" ]]; then
  12. # Fedora, CentOS or RHEL and derivatives
  13. yum -y install gcc glibc-headers kernel-devel kernel-headers make perl git wget
  14. elif [[ -n "$(type -P zypper)" ]]; then
  15. # openSUSE
  16. zypper --non-interactive install git make gcc kernel-devel patch wget
  17. fi