|
5 | 5 | <!--echo message="os.version = ${os.version}" /-->
|
6 | 6 |
|
7 | 7 | <!-- Sets properties for macosx/windows/linux depending on current system -->
|
8 |
| - <condition property="platform" value="macosx"> |
| 8 | + <condition property="platform" value="macosx-old"> |
9 | 9 | <and>
|
10 | 10 | <os family="mac" />
|
11 | 11 | <matches string="${os.version}" pattern="^10.[56]." />
|
12 | 12 | </and>
|
13 | 13 | </condition>
|
14 |
| - <condition property="platform" value="macosx-java-latest"><os family="mac" /></condition> |
| 14 | + <condition property="platform" value="macosx"><os family="mac" /></condition> |
15 | 15 | <condition property="platform" value="windows"><os family="windows" /></condition>
|
16 | 16 | <condition property="platform" value="linux32"><os family="unix" arch="i386" /></condition>
|
17 | 17 | <condition property="platform" value="linux64"><os family="unix" arch="amd64" /></condition>
|
18 | 18 |
|
| 19 | + <condition property="macosx"><equals arg1="${platform}" arg2="macosx-old" /></condition> |
19 | 20 | <condition property="macosx"><equals arg1="${platform}" arg2="macosx" /></condition>
|
20 |
| - <condition property="macosx"><equals arg1="${platform}" arg2="macosx-java-latest" /></condition> |
21 |
| - <condition property="macosx-java-latest"><equals arg1="${platform}" arg2="macosx-java-latest" /></condition> |
22 | 21 | <condition property="windows"><equals arg1="${platform}" arg2="windows" /></condition>
|
23 | 22 | <condition property="linux32"><equals arg1="${platform}" arg2="linux32" /></condition>
|
24 | 23 | <condition property="linux64"><equals arg1="${platform}" arg2="linux64" /></condition>
|
25 | 24 | <condition property="linux"><equals arg1="${platform}" arg2="linux32" /></condition>
|
26 | 25 | <condition property="linux"><equals arg1="${platform}" arg2="linux64" /></condition>
|
27 | 26 |
|
28 |
| - <condition property="staging_folder" value="macosx"><equals arg1="${platform}" arg2="macosx-java-latest" /></condition> |
29 | 27 | <condition property="staging_folder" value="macosx"><equals arg1="${platform}" arg2="macosx" /></condition>
|
| 28 | + <condition property="staging_folder" value="macosx"><equals arg1="${platform}" arg2="macosx-old" /></condition> |
30 | 29 | <condition property="staging_folder" value="windows"><equals arg1="${platform}" arg2="windows" /></condition>
|
31 | 30 | <condition property="staging_folder" value="linux"><equals arg1="${platform}" arg2="linux32" /></condition>
|
32 | 31 | <condition property="staging_folder" value="linux"><equals arg1="${platform}" arg2="linux64" /></condition>
|
33 | 32 |
|
34 |
| - <condition property="staging_hardware_folder" value="Arduino.app/Contents/Java/hardware"><equals arg1="${platform}" arg2="macosx-java-latest" /></condition> |
35 |
| - <condition property="staging_hardware_folder" value="Arduino.app/Contents/Resources/Java/hardware"><equals arg1="${platform}" arg2="macosx" /></condition> |
| 33 | + <condition property="staging_hardware_folder" value="Arduino.app/Contents/Java/hardware"><equals arg1="${platform}" arg2="macosx" /></condition> |
| 34 | + <condition property="staging_hardware_folder" value="Arduino.app/Contents/Resources/Java/hardware"><equals arg1="${platform}" arg2="macosx-old" /></condition> |
36 | 35 | <condition property="staging_hardware_folder" value="hardware"><equals arg1="${platform}" arg2="windows" /></condition>
|
37 | 36 | <condition property="staging_hardware_folder" value="hardware"><equals arg1="${platform}" arg2="linux32" /></condition>
|
38 | 37 | <condition property="staging_hardware_folder" value="hardware"><equals arg1="${platform}" arg2="linux64" /></condition>
|
|
195 | 194 | <!-- Mac OS X -->
|
196 | 195 | <!-- - - - - - - - -->
|
197 | 196 |
|
198 |
| - <target name="macosx-java-latest-clean" depends="macosx-clean" description="Clean Mac OS X build"/> |
| 197 | + <target name="macosx-clean" depends="macosx-old-clean" description="Clean Mac OS X build"/> |
199 | 198 |
|
200 |
| - <target name="macosx-clean" depends="subprojects-clean" description="Clean Mac OS X build"> |
| 199 | + <target name="macosx-old-clean" depends="subprojects-clean" description="Clean Mac OS X build"> |
201 | 200 | <delete dir="macosx/work" />
|
202 | 201 | <delete dir="macosx/working_dir" />
|
203 | 202 | <delete dir="macosx/working.dmg" />
|
|
218 | 217 | <fail message="wrong platform (${os.name})" />
|
219 | 218 | </target>
|
220 | 219 |
|
221 |
| - <target name="macosx-build" if="macosx" depends="revision-check, macosx-checkos, subprojects-build" description="Build Mac OS X version"> |
| 220 | + <target name="macosx-old-build" if="macosx" depends="revision-check, macosx-checkos, subprojects-build" description="Build Mac OS X version"> |
222 | 221 | <mkdir dir="macosx/work" />
|
223 | 222 |
|
224 | 223 | <!-- assemble the pde -->
|
|
246 | 245 |
|
247 | 246 | </target>
|
248 | 247 |
|
249 |
| - <target name="macosx-java-latest-build" if="macosx" depends="revision-check, macosx-checkos, subprojects-build" description="Build Mac OS X version"> |
| 248 | + <target name="macosx-build" if="macosx" depends="revision-check, macosx-checkos, subprojects-build" description="Build Mac OS X version"> |
| 249 | + <fail unless="MACOSX_BUNDLED_JVM" message="MacOSX requires MACOSX_BUNDLED_JVM property set"/> |
| 250 | + |
250 | 251 | <antcall target="unzip">
|
251 | 252 | <param name="archive_file" value="${staging_folder}/appbundler-1.0ea-upstream1.jar.zip" />
|
252 | 253 | <param name="archive_url" value="http://arduino.cc/download.php?f=/appbundler-1.0ea-upstream1.jar.zip" />
|
|
259 | 260 | <taskdef name="bundleapp" classname="com.oracle.appbundler.AppBundlerTask" classpath="${staging_folder}/appbundler-1.0ea-upstream1/appbundler-1.0ea-upstream1.jar"/>
|
260 | 261 |
|
261 | 262 | <bundleapp
|
262 |
| - jvmRequired="1.7" |
| 263 | + jvmRequired="1.8" |
263 | 264 | outputdirectory="${staging_folder}/work"
|
264 | 265 | name="Arduino"
|
265 | 266 | displayname="Arduino"
|
|
274 | 275 | minimumsystemversion="10.7"
|
275 | 276 | highresolutioncapable="true">
|
276 | 277 |
|
| 278 | + <runtime dir="${MACOSX_BUNDLED_JVM}"/> |
| 279 | + |
277 | 280 | <arch name="x86_64"/>
|
278 | 281 | <arch name="i386"/>
|
279 | 282 |
|
|
374 | 377 |
|
375 | 378 | </target>
|
376 | 379 |
|
377 |
| - <target name="macosx-run" depends="macosx-build" description="Run Mac OS X version"> |
| 380 | + <target name="macosx-old-run" depends="macosx-old-build" description="Run Mac OS X version"> |
378 | 381 | <antcall target="macosx-run-common"/>
|
379 | 382 | </target>
|
380 | 383 |
|
381 |
| - <target name="macosx-java-latest-run" depends="macosx-java-latest-build" description="Run Mac OS X version"> |
| 384 | + <target name="macosx-run" depends="macosx-build" description="Run Mac OS X version"> |
382 | 385 | <antcall target="macosx-run-common"/>
|
383 | 386 | </target>
|
384 | 387 |
|
385 |
| - <target name="macosx-debug" depends="macosx-build" description="Run Mac OS X version"> |
| 388 | + <target name="macosx-old-debug" depends="macosx-old-build" description="Run Mac OS X version"> |
386 | 389 | <antcall target="macosx-debug-common"/>
|
387 | 390 | </target>
|
388 | 391 |
|
389 |
| - <target name="macosx-java-latest-debug" depends="macosx-java-latest-build" description="Run Mac OS X version"> |
| 392 | + <target name="macosx-debug" depends="macosx-build" description="Run Mac OS X version"> |
390 | 393 | <antcall target="macosx-debug-common"/>
|
391 | 394 | </target>
|
392 | 395 |
|
|
457 | 460 | <!-- - - - - - - - - - - - - - - - - - - -->
|
458 | 461 | <!-- Build distribution file for MacOSX. -->
|
459 | 462 | <!-- - - - - - - - - - - - - - - - - - - -->
|
460 |
| - <target name="macosx-dist" if="macosx" depends="macosx-build" description="Create a downloadable .zip for the Mac OS X version"> |
| 463 | + <target name="macosx-old-dist" if="macosx" depends="macosx-old-build" description="Create a downloadable .zip for the Mac OS X version"> |
461 | 464 | <antcall target="macosx-dist-common"/>
|
462 | 465 | </target>
|
463 | 466 |
|
464 |
| - <target name="macosx-java-latest-dist" if="macosx" depends="macosx-java-latest-build" description="Create a downloadable .zip for the Mac OS X version"> |
| 467 | + <target name="macosx-dist" if="macosx" depends="macosx-build" description="Create a downloadable .zip for the Mac OS X version"> |
465 | 468 | <antcall target="macosx-dist-common"/>
|
466 | 469 | </target>
|
467 | 470 |
|
|
479 | 482 | </echo>
|
480 | 483 | </target>
|
481 | 484 |
|
482 |
| - <target name="macosx-dist-old" if="macosx" depends="macosx-build" description="Create a .dmg of the Mac OS X version"> |
483 |
| - <!-- now build the dmg --> |
484 |
| - <gunzip src="macosx/template.dmg.gz" dest="macosx/working.dmg" /> |
485 |
| - |
486 |
| - <mkdir dir="macosx/working_dir" /> |
487 |
| - <exec executable="hdiutil"> |
488 |
| - <arg line="attach macosx/working.dmg -noautoopen -mountpoint macosx/working_dir" /> |
489 |
| - <!--<arg line="attach macosx/working.dmg -noautoopen -quiet -mountpoint macosx/working_dir" />--> |
490 |
| - </exec> |
491 |
| - |
492 |
| - <copy todir="macosx/working_dir"> |
493 |
| - <fileset dir="macosx/work" /> |
494 |
| - </copy> |
495 |
| - |
496 |
| - <!-- The ant copy command does not preserve permissions. --> |
497 |
| - <chmod file="macosx/working_dir/Arduino.app/Contents/MacOS/JavaApplicationStub" perm="+x" /> |
498 |
| - <chmod perm="+x"> |
499 |
| - <fileset dir="macosx/working_dir/Arduino.app/Contents/Resources/Java/hardware/tools/avr/bin" includes="**/*" /> |
500 |
| - <fileset dir="macosx/working_dir/Arduino.app/Contents/Resources/Java/hardware/tools/avr/avr/bin" includes="**/*" /> |
501 |
| - <fileset dir="macosx/working_dir/Arduino.app/Contents/Resources/Java/hardware/tools/avr/avr-3/bin" includes="**/*" /> |
502 |
| - <fileset dir="macosx/working_dir/Arduino.app/Contents/Resources/Java/hardware/tools/avr/avr-4/bin" includes="**/*" /> |
503 |
| - <fileset dir="macosx/working_dir/Arduino.app/Contents/Resources/Java/hardware/tools/avr/libexec/gcc/avr/3.4.6/" includes="**/cc1*" /> |
504 |
| - <fileset dir="macosx/working_dir/Arduino.app/Contents/Resources/Java/hardware/tools/avr/libexec/gcc/avr/4.3.2/" includes="**/cc1*" /> |
505 |
| - </chmod> |
506 |
| - |
507 |
| - <!-- Pause briefly for the OS to catch up with the DMG changes. |
508 |
| - This prevents "hdiutil: couldn't eject "disk3" - Resource busy" |
509 |
| - errors when ejecting the disk in the next step. |
510 |
| - You may need to set this value higher for your system. --> |
511 |
| - <sleep seconds="3" /> |
512 |
| - |
513 |
| - <exec executable="hdiutil"> |
514 |
| - <!--<arg line="detach macosx/working_dir -quiet -force" />--> |
515 |
| - <arg line="detach macosx/working_dir" /> |
516 |
| - </exec> |
517 |
| - |
518 |
| - <delete file="macosx/arduino-*.dmg" /> |
519 |
| - <exec executable="hdiutil"> |
520 |
| - <arg line="convert macosx/working.dmg -quiet -format UDZO -imagekey zlib-level=9 -o macosx/arduino-${version}.dmg" /> |
521 |
| - </exec> |
522 |
| - |
523 |
| - <!-- Clean up the interim files. --> |
524 |
| - <delete file="macosx/working.dmg" /> |
525 |
| - <delete dir="macosx/working_dir" /> |
526 |
| - |
527 |
| - <echo> |
528 |
| - ======================================================= |
529 |
| - Arduino for Mac OS X was built. Grab the image from |
530 |
| - |
531 |
| - macosx/arduino-${version}.dmg |
532 |
| - ======================================================= |
533 |
| - </echo> |
534 |
| - </target> |
| 485 | + <!--<target name="macosx-dist-old" if="macosx" depends="macosx-build" description="Create a .dmg of the Mac OS X version">--> |
| 486 | + <!--<!– now build the dmg –>--> |
| 487 | + <!--<gunzip src="macosx/template.dmg.gz" dest="macosx/working.dmg" />--> |
| 488 | + |
| 489 | + <!--<mkdir dir="macosx/working_dir" />--> |
| 490 | + <!--<exec executable="hdiutil">--> |
| 491 | + <!--<arg line="attach macosx/working.dmg -noautoopen -mountpoint macosx/working_dir" />--> |
| 492 | + <!--<!–<arg line="attach macosx/working.dmg -noautoopen -quiet -mountpoint macosx/working_dir" />–>--> |
| 493 | + <!--</exec>--> |
| 494 | + |
| 495 | + <!--<copy todir="macosx/working_dir">--> |
| 496 | + <!--<fileset dir="macosx/work" />--> |
| 497 | + <!--</copy>--> |
| 498 | + |
| 499 | + <!--<!– The ant copy command does not preserve permissions. –>--> |
| 500 | + <!--<chmod file="macosx/working_dir/Arduino.app/Contents/MacOS/JavaApplicationStub" perm="+x" />--> |
| 501 | + <!--<chmod perm="+x">--> |
| 502 | + <!--<fileset dir="macosx/working_dir/Arduino.app/Contents/Resources/Java/hardware/tools/avr/bin" includes="**/*" />--> |
| 503 | + <!--<fileset dir="macosx/working_dir/Arduino.app/Contents/Resources/Java/hardware/tools/avr/avr/bin" includes="**/*" />--> |
| 504 | + <!--<fileset dir="macosx/working_dir/Arduino.app/Contents/Resources/Java/hardware/tools/avr/avr-3/bin" includes="**/*" />--> |
| 505 | + <!--<fileset dir="macosx/working_dir/Arduino.app/Contents/Resources/Java/hardware/tools/avr/avr-4/bin" includes="**/*" />--> |
| 506 | + <!--<fileset dir="macosx/working_dir/Arduino.app/Contents/Resources/Java/hardware/tools/avr/libexec/gcc/avr/3.4.6/" includes="**/cc1*" />--> |
| 507 | + <!--<fileset dir="macosx/working_dir/Arduino.app/Contents/Resources/Java/hardware/tools/avr/libexec/gcc/avr/4.3.2/" includes="**/cc1*" />--> |
| 508 | + <!--</chmod>--> |
| 509 | + |
| 510 | + <!--<!– Pause briefly for the OS to catch up with the DMG changes. --> |
| 511 | + <!--This prevents "hdiutil: couldn't eject "disk3" - Resource busy"--> |
| 512 | + <!--errors when ejecting the disk in the next step.--> |
| 513 | + <!--You may need to set this value higher for your system. –>--> |
| 514 | + <!--<sleep seconds="3" />--> |
| 515 | + |
| 516 | + <!--<exec executable="hdiutil">--> |
| 517 | + <!--<!–<arg line="detach macosx/working_dir -quiet -force" />–>--> |
| 518 | + <!--<arg line="detach macosx/working_dir" />--> |
| 519 | + <!--</exec>--> |
| 520 | + |
| 521 | + <!--<delete file="macosx/arduino-*.dmg" />--> |
| 522 | + <!--<exec executable="hdiutil">--> |
| 523 | + <!--<arg line="convert macosx/working.dmg -quiet -format UDZO -imagekey zlib-level=9 -o macosx/arduino-${version}.dmg" />--> |
| 524 | + <!--</exec>--> |
| 525 | + |
| 526 | + <!--<!– Clean up the interim files. –>--> |
| 527 | + <!--<delete file="macosx/working.dmg" />--> |
| 528 | + <!--<delete dir="macosx/working_dir" />--> |
| 529 | + |
| 530 | + <!--<echo>--> |
| 531 | + <!--=======================================================--> |
| 532 | + <!--Arduino for Mac OS X was built. Grab the image from--> |
| 533 | + |
| 534 | + <!--macosx/arduino-${version}.dmg--> |
| 535 | + <!--=======================================================--> |
| 536 | + <!--</echo>--> |
| 537 | + <!--</target>--> |
535 | 538 |
|
536 | 539 | <!-- - - - - - - - -->
|
537 | 540 | <!-- Linux -->
|
|
0 commit comments