nixpkgs/pkgs/development/arduino/arduino-core/default.nix

43 lines
1,015 B
Nix
Raw Normal View History

2012-11-28 02:55:24 +01:00
{ stdenv, fetchurl, jdk, jre, ant, coreutils, gnugrep }:
stdenv.mkDerivation rec {
version = "1.0.2";
name = "arduino-core";
src = fetchurl {
url = "http://arduino.googlecode.com/files/arduino-${version}-src.tar.gz";
sha256 = "0nszl2hdjjgxk87gyk0xi0ww9grbq83hch3iqmpaf9yp4y9bra0x";
};
buildInputs = [ jdk ant ];
phases = "unpackPhase patchPhase buildPhase installPhase";
patchPhase = ''
#
'';
buildPhase = ''
cd ./core && ant
cd ../build && ant
cd ..
'';
installPhase = ''
mkdir -p $out/share/arduino
cp -r ./build/linux/work/hardware/ $out/share/arduino
cp -r ./build/linux/work/libraries/ $out/share/arduino
cp -r ./build/linux/work/tools/ $out/share/arduino
cp -r ./build/linux/work/lib/ $out/share/arduino
echo ${version} > $out/share/arduino/lib/version.txt
'';
meta = {
description = "Arduino libraries";
homepage = http://arduino.cc/;
license = "GPL";
2012-11-28 15:37:11 +01:00
maintainers = [ stdenv.lib.maintainers.antono ];
2012-11-28 02:55:24 +01:00
};
}