|
91 | 91 | <property name="LIBLISTSERIAL-VERSION" value="1.4.0" />
|
92 | 92 | <property name="AVRGCC-VERSION" value="4.9.2-atmel3.5.4-arduino2" />
|
93 | 93 | <property name="AVRDUDE-VERSION" value="6.3.0-arduino9" />
|
| 94 | + <property name="AVRCORE-VERSION" value="1.6.20" /> |
94 | 95 | <property name="arduinoOTA-VERSION" value="1.2.1" />
|
95 | 96 |
|
96 | 97 | <!-- Libraries required for running arduino -->
|
|
263 | 264 |
|
264 | 265 | <!-- copy hardware folder -->
|
265 | 266 | <target name="assemble-hardware" unless="light_bundle">
|
266 |
| - <copy todir="${target.path}/hardware"> |
267 |
| - <fileset dir="../hardware"> |
268 |
| - <exclude name="arduino/sam/**"/> |
269 |
| - </fileset> |
270 |
| - </copy> |
| 267 | + <mkdir dir="${target.path}/hardware/arduino" /> |
| 268 | + <antcall target="untar"> |
| 269 | + <param name="archive_file" value="avr-${AVRCORE-VERSION}.tar.bz2"/> |
| 270 | + <param name="archive_url" value="https://downloads.arduino.cc/cores/avr-${AVRCORE-VERSION}.tar.bz2"/> |
| 271 | + <param name="final_folder" value="${target.path}/hardware/arduino/avr"/> |
| 272 | + <param name="dest_folder" value="${target.path}/hardware/arduino"/> |
| 273 | + </antcall> |
271 | 274 | </target>
|
272 | 275 |
|
273 | 276 | <!-- - - - - - - - - -->
|
274 | 277 | <!-- Revision check -->
|
275 | 278 | <!-- - - - - - - - - -->
|
276 | 279 | <target name="revision-check">
|
277 | 280 |
|
278 |
| - <!-- figure out the AVR core version number in platform.txt --> |
279 |
| - <loadfile srcfile="../hardware/arduino/avr/platform.txt" property="revision.avr.platform"> |
280 |
| - <filterchain> |
281 |
| - <tokenfilter> |
282 |
| - <linetokenizer /> |
283 |
| - <containsregex pattern="version="/> |
284 |
| - <replaceregex pattern="version=(.*)" flags="g" replace="\1"/> |
285 |
| - </tokenfilter> |
286 |
| - </filterchain> |
287 |
| - </loadfile> |
288 |
| - |
289 | 281 | <!-- figure out the latest AVR core version number in package_index.json -->
|
290 | 282 | <loadfile srcfile="../hardware/package_index_bundled.json" property="revision.avr.index">
|
291 | 283 | <filterchain>
|
|
298 | 290 | </filterchain>
|
299 | 291 | </loadfile>
|
300 | 292 |
|
301 |
| - <echo message="AVR Arduino core version in platform.txt is: ${revision.avr.platform}" /> |
| 293 | + <echo message="AVR Arduino core version in build.xml is: ${AVRCORE-VERSION}" /> |
302 | 294 | <echo message=" latest in package_index_bundled.json is: ${revision.avr.index}" />
|
303 | 295 | <condition property="revision.avr.ok">
|
304 | 296 | <or>
|
305 | 297 | <!-- fail build if -Drevision.check=enforce is set -->
|
306 | 298 | <not><equals arg1="${revision.check}" arg2="enforce"/></not>
|
307 |
| - <equals arg1="${revision.avr.index}" arg2="${revision.avr.platform}"/> |
| 299 | + <equals arg1="${revision.avr.index}" arg2="${AVRCORE-VERSION}"/> |
308 | 300 | </or>
|
309 | 301 | </condition>
|
310 | 302 | <fail unless="revision.avr.ok">
|
311 | 303 | Mismatching versions for bundled AVR core and package_index_bundled.json.
|
312 |
| - Please check your platform.txt and package_index_bundled.json. |
| 304 | + Please check your package_index_bundled.json. |
313 | 305 | </fail>
|
314 | 306 |
|
315 | 307 | <!-- figure out the IDE version number -->
|
|
0 commit comments