gcc-arm-embedded: add darwin support
This commit is contained in:
@@ -5,16 +5,17 @@ stdenv.mkDerivation rec {
|
||||
version = "6-2017-q2-update";
|
||||
subdir = "6-2017q2";
|
||||
|
||||
platformString =
|
||||
if stdenv.isLinux then "linux"
|
||||
else if stdenv.isDarwin then "mac"
|
||||
else throw "unsupported platform";
|
||||
|
||||
urlString = "https://developer.arm.com/-/media/Files/downloads/gnu-rm/${subdir}/gcc-arm-none-eabi-${version}-${platformString}.tar.bz2";
|
||||
|
||||
src =
|
||||
if stdenv.isLinux then fetchurl { url=urlString; sha256="1hvwi02mx34al525sngnl0cm7dkmzxfkb1brq9kvbv28wcplp3p6"; }
|
||||
else if stdenv.isDarwin then fetchurl { url=urlString; sha256="0019ylpq4inq7p5gydpmc9m8ni72fz2csrjlqmgx1698998q0c3x"; }
|
||||
if stdenv.isLinux then
|
||||
fetchurl {
|
||||
url = "https://developer.arm.com/-/media/Files/downloads/gnu-rm/${subdir}/gcc-arm-none-eabi-${version}-linux.tar.bz2";
|
||||
sha256="1hvwi02mx34al525sngnl0cm7dkmzxfkb1brq9kvbv28wcplp3p6";
|
||||
}
|
||||
else if stdenv.isDarwin then
|
||||
fetchurl {
|
||||
url = "https://developer.arm.com/-/media/Files/downloads/gnu-rm/${subdir}/gcc-arm-none-eabi-${version}-mac.tar.bz2";
|
||||
sha256="0019ylpq4inq7p5gydpmc9m8ni72fz2csrjlqmgx1698998q0c3x";
|
||||
}
|
||||
else throw "unsupported platform";
|
||||
|
||||
phases = [ "unpackPhase" "installPhase" "fixupPhase" ];
|
||||
|
||||
Reference in New Issue
Block a user