Skip to content

Commit 6537c1c

Browse files
committed
[sam] added toolchain download for windows
1 parent 844f559 commit 6537c1c

File tree

3 files changed

+39
-0
lines changed

3 files changed

+39
-0
lines changed

build/build.xml

+38
Original file line numberDiff line numberDiff line change
@@ -600,6 +600,8 @@
600600
<chmod perm="755">
601601
<fileset dir="windows/work" includes="**/*.html, **/*.dll, **/*.exe" />
602602
</chmod>
603+
604+
<antcall target="get-arm-toolchain-help" />
603605
</target>
604606

605607
<target name="windows-run" depends="windows-build"
@@ -608,6 +610,42 @@
608610
dir="windows/work" spawn="true"/>
609611
</target>
610612

613+
<target name="windows-check-arm-toolchain-distfile">
614+
<available file="windows/dist/gcc-arm-none-eabi-4.4.1-2010q1-188-win32.tar.gz" property="arm_distfile_available" />
615+
</target>
616+
617+
<target name="windows-get-arm-toolchain" depends="windows-check-arm-toolchain-distfile" unless="arm_distfile_available">
618+
<!-- Retrieve ARM toolchain -->
619+
<get
620+
src="http://arduino.googlecode.com/files/gcc-arm-none-eabi-4.4.1-2010q1-188-win32.tar.gz"
621+
dest="windows/dist/gcc-arm-none-eabi-4.4.1-2010q1-188-win32.tar.gz"
622+
verbose="true" />
623+
</target>
624+
625+
<target name="windows-check-arm-toolchain">
626+
<available file="windows/work/hardware/tools/g++_arm_none_eabi" property="arm_available" />
627+
</target>
628+
629+
<target name="windows-unzip-arm-toolchain" depends="windows-get-arm-toolchain, windows-check-arm-toolchain" unless="arm_available">
630+
<checksum file="windows/dist/gcc-arm-none-eabi-4.4.1-2010q1-188-win32.tar.gz" algorithm="sha"
631+
fileext=".sha" verifyproperty="checksum.matches"/>
632+
<condition property="checksum.matches.fail">
633+
<equals arg1="${checksum.matches}" arg2="false"/>
634+
</condition>
635+
<fail if="checksum.matches.fail">Checksum failed.
636+
637+
File gcc-arm-none-eabi-4.4.1-2010q1-188-win32.tar.gz failed checksum.
638+
Please remove "windows/dist/gcc-arm-none-eabi-4.4.1-2010q1-188-win32.tar.gz" to download it again.
639+
</fail>
640+
641+
<!-- Unzip toolchain to the destination folder -->
642+
<exec executable="tar">
643+
<arg value="xfz"/>
644+
<arg value="windows/dist/gcc-arm-none-eabi-4.4.1-2010q1-188-win32.tar.gz"/>
645+
<arg value="--directory=windows/work/hardware/tools"/>
646+
</exec>
647+
</target>
648+
611649
<target name="windows-dist" depends="windows-build"
612650
description="Create .zip files of windows version">
613651

build/windows/CodeSourcery_arm.zip

-45.7 MB
Binary file not shown.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
f288affa058bfdd44f8b93800fc4cb01b2ebf1e5

0 commit comments

Comments
 (0)