Java Compiler not working

Please support our Java advertiser: Programming Forums - DaniWeb Sister Site
Reply

Join Date: Feb 2006
Posts: 118
Reputation: mesamb1 is an unknown quantity at this point 
Solved Threads: 2
mesamb1's Avatar
mesamb1 mesamb1 is offline Offline
Junior Poster

Java Compiler not working

 
0
  #1
Sep 23rd, 2006
I am brand new to the world of java and was working on a tutorial from the java website. I was feeling all cool writing my code and getting it and then when i tried to compile a bycycle program i got a error message reading:

[/Users/Sam/Bicycle/build.xml:29: Compile failed; see the compiler error output for details.]

so then i went to the Copiler error thingy and got alot og code :eek:

[<?xml version="1.0" encoding="UTF-8"?>
<project name="Bicycle" default="jar" basedir=".">
<property name="src" location="src"/>
<property name="bin" location="bin"/>
<property name="lib" location="lib"/>
<property name="dist" location="dist"/>
<property name="jarfile" location="${dist}/${ant.project.name}.jar"/>
<property name="compile.debug" value="true"/>

<fileset id="lib.jars" dir="${lib}">
<include name="**/*.jar"/>
</fileset>

<path id="lib.path">
<fileset refid="lib.jars"/>
</path>

<!-- Stub install target. Install should depend on the 'jar' target,
and copy the built objects to the 'dist' directory. -->
<target name="install" description="Install jar" depends="jar">
</target>

<target name="compile" description="Compile code">
<mkdir dir="${bin}"/>
<mkdir dir="${lib}"/>
<javac srcdir="${src}" destdir="${bin}"
source="1.3" target="1.3"
includeAntRuntime="no"
classpathref="lib.path" debug="${compile.debug}">
</javac>
</target>

<target name="jar" depends="compile" description="Build jar">
<mkdir dir="${dist}"/>
<jar jarfile="${jarfile}" basedir="${bin}" manifest="Manifest">
<!-- Merge library jars into final jar file -->
<zipgroupfileset refid="lib.jars"/>
</jar>
</target>

<target name="run" depends="jar" description="Run jar file">
<java jar="${jarfile}" fork="yes" failonerror="true"/>
</target>

<target name="clean" description="Remove build and dist directories">
<delete dir="${bin}"/>
<delete dir="${dist}"/>
</target>
</project>
]

being new to this this mines well be spanish
all i know for sure is that this line was highlighted:

[classpathref="lib.path" debug="${compile.debug}">]

and this is the link to the tutorial i was working on:
http://java.sun.com/docs/books/tutor...pts/class.html

and I am woriking on Xcode
so i am wondering is this due to bad progamming by me or something wrong with Xcode and can i fix it?
Reply With Quote Quick reply to this message  
Join Date: Aug 2005
Posts: 5,273
Reputation: iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold 
Solved Threads: 378
Featured Poster
iamthwee's Avatar
iamthwee iamthwee is offline Offline
Posting Expert

Re: Java Compiler not working

 
0
  #2
Sep 23rd, 2006
That bicycle program is very simple, from the looks of it.

Therefore I would guess your problem is that you haven't set the path to your compiler correctly or something similar.

It's something you invariably have to do at some point. So you might as well learn it now.

???
*Voted best profile in the world*
Reply With Quote Quick reply to this message  
Join Date: Feb 2006
Posts: 118
Reputation: mesamb1 is an unknown quantity at this point 
Solved Threads: 2
mesamb1's Avatar
mesamb1 mesamb1 is offline Offline
Junior Poster

Re: Java Compiler not working

 
0
  #3
Sep 23rd, 2006
I will look at and see if that helps at all
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:


Thread Tools Search this Thread



Tag cloud for Java
About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC