You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-dev@db.apache.org by Daniel John Debrunner <dj...@apache.org> on 2006/02/07 22:02:23 UTC
Building JDK 1.6/JDBC 4.0 code
I couldn't find any instructions on how to setup to build the JDK
1.6/JDBC 4.0 specific targets in the BUILDING.txt file.
How can I build this code as part of an
ant all
?
Thanks,
Dan.
Re: Building JDK 1.6/JDBC 4.0 code
Posted by "David W. Van Couvering" <Da...@Sun.COM>.
I just wanted to make sure -- you *did* download the JDK, not the JRE.
$jdk16/bin contains javac?
David
Daniel John Debrunner wrote:
> Rick Hillegas wrote:
>
>
>>Hm. Does ${jdk16}/jre/lib hold rt.jar?
>
>
> Yes.
>
> derby:clean2:trunk>c:/_work/p4n/djdcs/jdk16/jre/bin/java -version
> java version "1.6.0-rc"
> Java(TM) 2 Runtime Environment, Standard Edition (build 1.6.0-rc-b62)
> Java HotSpot(TM) Client VM (build 1.6.0-rc-b62, mixed mode)
>
>
> derby:clean2:trunk>c:/_work/p4n/djdcs/jdk16/jre/bin/java -cp classes
> org.apache.derby.tools.sysinfo
> ------------------ Java Information ------------------
> Java Version: 1.6.0-rc
> Java Vendor: Sun Microsystems Inc.
> Java home: c:\_work\p4n\djdcs\jdk16\jre
> Java classpath: classes
> OS name: Windows XP
> OS architecture: x86
> OS version: 5.1
> Java user name: djd
> Java user home: C:\Documents and Settings\Administrator
> Java user dir: c:\_work\svn_clean3\trunk
> java.specification.name: Java Platform API Specification
> java.specification.version: 1.6
> --------- Derby Information --------
> JRE - JDBC: ?-?
> [C:\_work\svn_clean3\trunk\classes] 10.2.0.0 alpha - (1)
> ------------------------------------------------------
> ----------------- Locale Information -----------------
> Current Locale : [English/United States [en_US]]
> Found support for locale: [de_DE]
> version: 10.2.0.0 alpha - (1)
> Found support for locale: [es]
> version: 10.2.0.0 alpha - (1)
> Found support for locale: [fr]
> version: 10.2.0.0 alpha - (1)
> Found support for locale: [it]
> version: 10.2.0.0 alpha - (1)
> Found support for locale: [ja_JP]
> version: 10.2.0.0 alpha - (1)
> Found support for locale: [ko_KR]
> version: 10.2.0.0 alpha - (1)
> Found support for locale: [pt_BR]
> version: 10.2.0.0 alpha - (1)
> Found support for locale: [zh_CN]
> version: 10.2.0.0 alpha - (1)
> Found support for locale: [zh_TW]
> version: 10.2.0.0 alpha - (1)
> ------------------------------------------------------
Re: Building JDK 1.6/JDBC 4.0 code
Posted by Daniel John Debrunner <dj...@apache.org>.
David W. Van Couvering wrote:
> Oh, the java.lang not found in classpath error. I remember getting this
> when I first started working with Derby! Are you working on Windows?
> Make sure you use forward slashes in your ant.properties file:
Have all that.
The issue is that I don't have an ant.properties in my home directory, I
have separate ones in each svn tree. Then I compile using
ant -propertyfile ant.properties all
The jdk16 ant that is started by the main ant is not carrying the
original properties across, it is relying on there being a
ant.properties in the home directory.
Maybe the changes to DERBY-932 will fix this.
Thanks for the pointers,
Dan.
Re: Building JDK 1.6/JDBC 4.0 code
Posted by "David W. Van Couvering" <Da...@Sun.COM>.
Oh, the java.lang not found in classpath error. I remember getting this
when I first started working with Derby! Are you working on Windows?
Make sure you use forward slashes in your ant.properties file:
jdk16=c:/program files/Java/jdk1.6.0
NOT
jdk16=c:\program files\Java\jdk1.6.0
David
Re: Building JDK 1.6/JDBC 4.0 code
Posted by Daniel John Debrunner <dj...@apache.org>.
Rick Hillegas wrote:
> Hm. Does ${jdk16}/jre/lib hold rt.jar?
Yes.
derby:clean2:trunk>c:/_work/p4n/djdcs/jdk16/jre/bin/java -version
java version "1.6.0-rc"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.6.0-rc-b62)
Java HotSpot(TM) Client VM (build 1.6.0-rc-b62, mixed mode)
derby:clean2:trunk>c:/_work/p4n/djdcs/jdk16/jre/bin/java -cp classes
org.apache.derby.tools.sysinfo
------------------ Java Information ------------------
Java Version: 1.6.0-rc
Java Vendor: Sun Microsystems Inc.
Java home: c:\_work\p4n\djdcs\jdk16\jre
Java classpath: classes
OS name: Windows XP
OS architecture: x86
OS version: 5.1
Java user name: djd
Java user home: C:\Documents and Settings\Administrator
Java user dir: c:\_work\svn_clean3\trunk
java.specification.name: Java Platform API Specification
java.specification.version: 1.6
--------- Derby Information --------
JRE - JDBC: ?-?
[C:\_work\svn_clean3\trunk\classes] 10.2.0.0 alpha - (1)
------------------------------------------------------
----------------- Locale Information -----------------
Current Locale : [English/United States [en_US]]
Found support for locale: [de_DE]
version: 10.2.0.0 alpha - (1)
Found support for locale: [es]
version: 10.2.0.0 alpha - (1)
Found support for locale: [fr]
version: 10.2.0.0 alpha - (1)
Found support for locale: [it]
version: 10.2.0.0 alpha - (1)
Found support for locale: [ja_JP]
version: 10.2.0.0 alpha - (1)
Found support for locale: [ko_KR]
version: 10.2.0.0 alpha - (1)
Found support for locale: [pt_BR]
version: 10.2.0.0 alpha - (1)
Found support for locale: [zh_CN]
version: 10.2.0.0 alpha - (1)
Found support for locale: [zh_TW]
version: 10.2.0.0 alpha - (1)
------------------------------------------------------
Re: Building JDK 1.6/JDBC 4.0 code
Posted by Rick Hillegas <Ri...@Sun.COM>.
Hm. Does ${jdk16}/jre/lib hold rt.jar?
-Rick
Daniel John Debrunner wrote:
>Rick Hillegas wrote:
>
>
>
>>Hi Dan,
>>
>>Does your 1.6 installation have a compiler or does it only hold the jre?
>>
>>
>
>Doh, it held nothing, the command that I thought had copied it there did
>nothing!
>
>Next error :-)
>
>compile_jdbc4_target:
> [echo] [javac] Fatal Error: Unable to find package java.lang in
>classpa
>th or bootclasspath
> [echo]
> [echo] BUILD FAILED
> [echo] C:\_work\svn_clean3\trunk\java\client\build.xml:67: Compile
>failed;
>see the compiler error output for details.
> [echo]
> [echo] Total time: 1 second
>
>
>Dan.
>
>
>
>
Re: Building JDK 1.6/JDBC 4.0 code
Posted by Daniel John Debrunner <dj...@apache.org>.
Rick Hillegas wrote:
> Hi Dan,
>
> Does your 1.6 installation have a compiler or does it only hold the jre?
Doh, it held nothing, the command that I thought had copied it there did
nothing!
Next error :-)
compile_jdbc4_target:
[echo] [javac] Fatal Error: Unable to find package java.lang in
classpa
th or bootclasspath
[echo]
[echo] BUILD FAILED
[echo] C:\_work\svn_clean3\trunk\java\client\build.xml:67: Compile
failed;
see the compiler error output for details.
[echo]
[echo] Total time: 1 second
Dan.
Re: Building JDK 1.6/JDBC 4.0 code
Posted by Rick Hillegas <Ri...@Sun.COM>.
Hi Dan,
Does your 1.6 installation have a compiler or does it only hold the jre?
In my ant.properties, I have the following assignment:
jdk16=c:/cygwin/home/rh161140/sw/java/jdk-6_0-70
That directory, in turn, contains a bin subdirectory (which holds the
1.6 compiler) and a jre subdirectory. Hope this helps.
Regards,
-Rick
Daniel John Debrunner wrote:
>Andrew McIntyre wrote:
>
>
>
>>On Feb 7, 2006, at 1:02 PM, Daniel John Debrunner wrote:
>>
>>
>>
>>>I couldn't find any instructions on how to setup to build the JDK
>>>1.6/JDBC 4.0 specific targets in the BUILDING.txt file.
>>>
>>>How can I build this code as part of an
>>>
>>>ant all
>>>
>>>
>>Set jdk16 in your ant.properties to the JAVA_HOME for a 1.6 vm. The
>>bin, jre, and lib dirs should be in that directory.
>>
>>e.g.:
>>...
>>jdk16=c:/workspace/jdk16
>>
>>
>
>Thanks (to Rick as well), hit the next problem below. I know there was
>some e-mail about these targets failing, has that been addressed?
>
>Dan.
>
>compile_jdbc4_target:
> [echo] Unable to locate tools.jar. Expected to find it in
>C:\Program Files\
>IBM\Java142\lib\tools.jar
> [echo]
> [echo] BUILD FAILED
> [echo]
>C:\_work\svn_clean3\trunk\java\engine\org\apache\derby\impl\jdbc\bui
>ld.xml:150: Unable to find a javac compiler;
> [echo] com.sun.tools.javac.Main is not on the classpath.
> [echo] Perhaps JAVA_HOME does not point to the JDK
> [echo]
> [echo] Total time: 1 second
>
>
Re: Building JDK 1.6/JDBC 4.0 code
Posted by Daniel John Debrunner <dj...@apache.org>.
Andrew McIntyre wrote:
>
> On Feb 7, 2006, at 1:02 PM, Daniel John Debrunner wrote:
>
>> I couldn't find any instructions on how to setup to build the JDK
>> 1.6/JDBC 4.0 specific targets in the BUILDING.txt file.
>>
>> How can I build this code as part of an
>>
>> ant all
>
>
> Set jdk16 in your ant.properties to the JAVA_HOME for a 1.6 vm. The
> bin, jre, and lib dirs should be in that directory.
>
> e.g.:
> ...
> jdk16=c:/workspace/jdk16
Thanks (to Rick as well), hit the next problem below. I know there was
some e-mail about these targets failing, has that been addressed?
Dan.
compile_jdbc4_target:
[echo] Unable to locate tools.jar. Expected to find it in
C:\Program Files\
IBM\Java142\lib\tools.jar
[echo]
[echo] BUILD FAILED
[echo]
C:\_work\svn_clean3\trunk\java\engine\org\apache\derby\impl\jdbc\bui
ld.xml:150: Unable to find a javac compiler;
[echo] com.sun.tools.javac.Main is not on the classpath.
[echo] Perhaps JAVA_HOME does not point to the JDK
[echo]
[echo] Total time: 1 second
Re: Building JDK 1.6/JDBC 4.0 code
Posted by Andrew McIntyre <mc...@gmail.com>.
On Feb 7, 2006, at 1:02 PM, Daniel John Debrunner wrote:
> I couldn't find any instructions on how to setup to build the JDK
> 1.6/JDBC 4.0 specific targets in the BUILDING.txt file.
>
> How can I build this code as part of an
>
> ant all
Set jdk16 in your ant.properties to the JAVA_HOME for a 1.6 vm. The
bin, jre, and lib dirs should be in that directory.
e.g.:
...
jdk16=c:/workspace/jdk16
...
then run 'ant all' (or just ant), and it will build the JDBC 4.0 code
by forking Ant to run with the jdk16 JRE, thus compiling the code
with the 1.6 javac .
And yes, this information should definitely be added to BUILDING.txt.
andrew
Re: Building JDK 1.6/JDBC 4.0 code
Posted by "David W. Van Couvering" <Da...@Sun.COM>.
I'll fix BUILDING.txt as part of the fix I'm making to the build
environment to work better for JDK 1.6 folks.
David
Rick Hillegas wrote:
> Hi Dan,
>
> This information needs to make it's way into BUILDING.txt. Currently,
> it's only documented in jdbc4.0.sxw attached to JIRA 587. In a nutshell,
> you need to put a new property (jdk16) in your ant.properties. This
> property points at the location of your jdk1.6 installation (the
> mustang JAVA_HOME).
>
> Regards,
> -Rick
>
> Daniel John Debrunner wrote:
>
>> I couldn't find any instructions on how to setup to build the JDK
>> 1.6/JDBC 4.0 specific targets in the BUILDING.txt file.
>>
>> How can I build this code as part of an
>>
>> ant all
>>
>> ?
>>
>> Thanks,
>> Dan.
>>
>>
>
Re: Building JDK 1.6/JDBC 4.0 code
Posted by Rick Hillegas <Ri...@Sun.COM>.
Hi Dan,
This information needs to make it's way into BUILDING.txt. Currently,
it's only documented in jdbc4.0.sxw attached to JIRA 587. In a nutshell,
you need to put a new property (jdk16) in your ant.properties. This
property points at the location of your jdk1.6 installation (the
mustang JAVA_HOME).
Regards,
-Rick
Daniel John Debrunner wrote:
>I couldn't find any instructions on how to setup to build the JDK
>1.6/JDBC 4.0 specific targets in the BUILDING.txt file.
>
>How can I build this code as part of an
>
>ant all
>
>?
>
>Thanks,
>Dan.
>
>