Subject RE: [Firebird-Java] Compiling Type2 driver
Author Ryan Baldwin
Hi Luca,

I can only guess that not all the jars from the lib directory are on the
classpath when your attempting to build - and for this reason it cant load
net.sf.antcontrib.cpptasks.CCTask as perhaps it depends on some of these
other classes.

I'm not sure how exactly your trying to build the code - in case it helps -
I know these steps work for me under windows:

Through command line:
1) Open command prompt.
2) Move to root of client-java source tree.
3) Set the JAVA_HOME environment variable. This can be done by 'SET
JAVA_HOME=C:\jdks\j2sdk1.4.2' where you would replace C:\jdks\j2sdk1.4.2
with the path to the root directory of the JDK.
4) To build just the native code type 'build compile-native'. This runs the
build.bat file which as far as I'm aware puts all the jars in the lib
directory on the class path then executes the specified target in the ANT
script using the JDK specified earlier.

Through IDE(InteliJ Idea):
I can set up a class path to use when executing the ANT script - so onto
this I add all the jars from the lib directory. For the purpose of building
the native code I set a ANT property java_home to the root of the JDK. The
IDE supplies a macro for this which is set acording to the JDK selected for
the project.


I also copy cvs.exe to the root of client-java so the checkout stuff works -
maybe there is a better way to do this.


I hope some of this helps. If you continue to have problems building the
native code maybe you could detail the steps you are taking to build the
native code.

Thanks
Ryan



-----Original Message-----
From: Luca Lafranchi [mailto:luca.lafranchi@...]
Sent: 19 August 2003 11:50
To: Firebird-Java@yahoogroups.com
Subject: [Firebird-Java] Compiling Type2 driver


Hi :)

I eventually managed to get MSVC6 installed and so I'm trying to compile
the whole native part of the driver by myself using the ant script, but
something's wrong. I updated the sources and ran ant AS IS, but java
didn't find cpptasks.jar, so I put it in the ext directory of jre. So
far so good, ant starts does something, outputs "init","compile-native",
and then stops:
BUILD FAILED
file:C:/.../build_native.xml:31 taskdef class
net.sf.antcontrib.cpptasks.CCTask cannot be found

I put cpptasks.jar everywere (jdk/lib, ant/lib,...), edited the
CLASSPATH variable, but still I get the error. Looks like a <classpath>
directive is missing somewhere in the xml files, but I'm not an ant
expert :( so I don't exactly know where to look at.

Any hints?

Thanks
Luca



To unsubscribe from this group, send an email to:
Firebird-Java-unsubscribe@yahoogroups.com



Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/