<project name="foo" default="compile">
<property name="ant.build.javac.target" value="1.5"/>
<target name="compile">
<javac srcdir="."/>
</target>
</project>
Martin
______________________________________________
Verzicht und Vertraulichkeitanmerkung / Disclaimer and confidentiality note
Diese Nachricht ist vertraulich. Sollten Sie nicht der vorgesehene Empfaenger
sein, so bitten wir hoeflich um eine Mitteilung. Jede unbefugte Weiterleitung
oder Fertigung einer Kopie ist unzulaessig. Diese Nachricht dient lediglich dem
Austausch von Informationen und entfaltet keine rechtliche Bindungswirkung.
Aufgrund der leichten Manipulierbarkeit von E-Mails koennen wir keine Haftung
fuer den Inhalt uebernehmen.
This message is confidential and may be privileged. If you are not the intended
recipient, we kindly ask you to please inform the sender. Any unauthorised
dissemination or copying hereof is prohibited. This message serves for
information purposes only and shall not have any legally binding effect. Given
that e-mails can easily be subject to manipulation, we can not accept any
liability for the content provided.
> Date: Thu, 19 Mar 2009 14:46:47 -0700
> From: [email protected]
> To: [email protected]
> Subject: Ant Javac Target Attribute Issue
>
>
> I am using:
> jdk 1.6.0_11
> ant 1.7.1
>
> And I want to target 1.5.
>
> However, using the target attribute below in my build file still generates
> "1.6 version" classes.
>
> <javac target="1.5" ...>
>
> I've tried adding the source="1.5" and the bootclasspath="" to the 1.5 jar
> files and forking the 1.6 javac just in case.
>
> The only thing that works is installing the 1.5 jdk and using that or fork
> the 1.5 javac executable with the 1.5 bootclasspath jars. (rt.jar, jsse.jar,
> jce.jar, charsets.jar,...)
>
> I don't know how to properly target 1.5 with 1.6 in ant. Nothing seems to
> work. I know I must be doing something stupid, but I can't figure it out.
>
> Any help would be extremely appreciated.
>
> Regards,
> Jason
>
> --
> View this message in context:
> http://www.nabble.com/Ant-Javac-Target-Attribute-Issue-tp22608438p22608438.html
> Sent from the Ant - Users mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
_________________________________________________________________
Windows Live⢠Groups: Create an online spot for your favorite groups to meet.
http://windowslive.com/online/groups?ocid=TXT_TAGLM_WL_groups_032009