Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / Tools / December 2006

Tip: Looking for answers? Try searching our database.

ANT - java doesn't support "srcdir" attribute

Thread view: 
d.s. - 27 Dec 2006 18:23 GMT
I'm trying to set up ANT for the first time, in order to use Hibernate.
I'm trying to create a working "build.xml" file.

I get the following error message:

java doesn't support the "srcdir" attribute

I'm using java 1.5.0_06

Here's my code:

<?xml version="1.0"?>
<project name="calendar" default="build">
    <property name="src.java.dir" location="src/java"/>
    <property name="build.classes.dir" location="build/classes" />
    <path id="project.classpath">
        <pathelement location="${build.classes.dir}" />
    </path>
    <target name="init" >
        <mkdir dir="${build.classes.dir}" />
    </target>
    <target name="compile" depends="init" >
        <javac srcdir="${src.java.dir}"
            destdir="${build.classes.dir}">
                <include name="**/EventCalendar.java" />
        </javac>
    </target>
    <target name="build" depends="compile" >
            <java srcdir="com.manning.hq.ch02.EventCalendar"
                failonerror = "true" >
                <classpath refid="project.classpath" />
            </java>
        <echo>If you see this, it works!!!</echo>
    </target>
   
</project>
d.s. - 27 Dec 2006 18:30 GMT
> I'm trying to set up ANT for the first time, in order to use Hibernate.
>  I'm trying to create a working "build.xml" file.
[quoted text clipped - 4 lines]
>
> I'm using java 1.5.0_06

Never mind.  Transcription error on my part.


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.