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 John Embretsen <Jo...@Sun.COM> on 2007/02/28 15:04:02 UTC

Building Derby in NetBeans

I just added a section on the "BuildingDerby" wiki page on how to checkout (from 
svn) and build Derby using NetBeans (version 5.5, primarily):

http://wiki.apache.org/db-derby/BuildingDerby#UsingNetBeansToBuildDerby

Feel free to try it out and fix or report errors/omissions.


Thanks,

-- 
John



Re: Building Derby in NetBeans

Posted by "John H. Embretsen" <Jo...@Sun.COM>.
Ravinder Reddy wrote:
> 
> Thank you for your valuable suggestions..!! The (Sun) java Downloads  
> page is  showing  that
> jdk1.3(http://java.sun.com/j2se/1.3/download.html) has completed it's 
> end of life(EOL) and Even
> there is no link for jdk1.3 in archive page..!! So how to install 1.3..!!

Yes, 1.3 has reached end of life as defined by Sun, but it is still 
being used by many people and organizations, and the Derby community has 
decided to support 1.3 up to and including the 10.2.x releases. 
Hopefully, JDK (J2SDK) 1.3 won't be required for Derby 10.3 or higher.

The 1.3.1 JDK (it was called SDK back then) is available for all 
platforms in the archives. From the page you linked to, click the link 
for DOWNLOAD (Archive Releases) in the SDK column. Then, under "Java 2 
Platform Standard Edition (J2SE)", you will find "J2SDK - 1.3", which is 
what you need. "1.3.1_20 + Documentation" is the latest one. The direct 
link is:

http://java.sun.com/products/archive/j2se/1.3.1_20/index.html

Make sure you download the SDK, not the JRE. Install the usual way :)

-- 
John



Re: Building Derby in NetBeans

Posted by Ravinder Reddy <ra...@gmail.com>.
Thank you for your valuable suggestions..!! The (Sun) java Downloads  page
is  showing  that
jdk1.3(http://java.sun.com/j2se/1.3/download.html) has completed it's end of
life(EOL) and Even
there is no link for jdk1.3 in archive page..!! So how to install 1.3..!!

                                 Thank You

On 3/1/07, John Embretsen <Jo...@sun.com> wrote:
>
> Ravinder Reddy wrote:
> > No , I never tried to build Derby outside of Netbeans..!!. And I
> > installed jdk1.5
> > 2 months back and I downloaded the Derby Source from the latest Official
> > Release..!!
>
> OK, that may explain it... For building Derby, you need to have both JDK
> 1.3.1
> and JDK 1.4.2 installed (actually, JDK 1.5 is not used during the build
> process
> as far as I know). If you want to build the JDBC 4 functionality you need
> JDK 6
> as well.
>
> Then you need to specify the paths to these JDK installations in your
> ant.properties file, for example:
>
> j14lib=/usr/local/java/jdk1.4/jre/lib
> j13lib=/usr/local/java/jdk1.3/jre/lib
> jdk16=/usr/local/java/jdk1.6.0
> proceed=false
> sane=true
>
> This and other requirements for building Derby is described in
> BUILDING.txt,
> referenced in Step 4.VIII on the wiki page you were following. Here is a
> direct
> link to the 10.2 BUILDING.txt:
>
> http://svn.apache.org/repos/asf/db/derby/code/branches/10.2/BUILDING.txt
>
> I hope this helps...
>
>
> --
> John
>
>

Re: Building Derby in NetBeans

Posted by John Embretsen <Jo...@Sun.COM>.
Ravinder Reddy wrote:
> No , I never tried to build Derby outside of Netbeans..!!. And I 
> installed jdk1.5
> 2 months back and I downloaded the Derby Source from the latest Official 
> Release..!!

OK, that may explain it... For building Derby, you need to have both JDK 1.3.1 
and JDK 1.4.2 installed (actually, JDK 1.5 is not used during the build process 
as far as I know). If you want to build the JDBC 4 functionality you need JDK 6 
as well.

Then you need to specify the paths to these JDK installations in your 
ant.properties file, for example:

j14lib=/usr/local/java/jdk1.4/jre/lib
j13lib=/usr/local/java/jdk1.3/jre/lib
jdk16=/usr/local/java/jdk1.6.0
proceed=false
sane=true

This and other requirements for building Derby is described in BUILDING.txt, 
referenced in Step 4.VIII on the wiki page you were following. Here is a direct 
link to the 10.2 BUILDING.txt:

http://svn.apache.org/repos/asf/db/derby/code/branches/10.2/BUILDING.txt

I hope this helps...


-- 
John


Re: Building Derby in NetBeans

Posted by Ravinder Reddy <ra...@gmail.com>.
Sorry for spamming U r mail Box..!!!
This is the Exact Error that I am getting when I try to build Derby in
Netbeans

******************************************************************************
init:
Created dir: /root/db-derby-10.2.2.0-src/classes
ensuresanitystate:
evaluate.sane:
ensuresanitystate.sane:
sane:
Creating new property file: /root/db-derby-10.2.2.0-src
/java/engine/state.properties
ensuresanitystate.insane:
setissane:
showenv:

Ant environment:
  Base Directory: /root/db-derby-10.2.2.0-src
  Build output: /root/db-derby-10.2.2.0-src/classes
  Compiler: modern
  Sane = true
  Proceed = no

getstate:
state:
  Generating SanityState.java...
Copying 1 file to /root/db-derby-10.2.2.0-src
/java/shared/org/apache/derby/shared/common/sanity
Updating property file: /root/db-derby-10.2.2.0-src
/java/engine/state.properties
shared:
compile:
Compiling 11 source files to /root/db-derby-10.2.2.0-src/classes
Fatal Error: Unable to find package java.lang in classpath or bootclasspath
/root/db-derby-10.2.2.0-src/build.xml:347: The following error occurred
while executing this line:
/root/db-derby-10.2.2.0-src/java/shared/build.xml:67: Compile failed; see
the compiler error output for details.
BUILD FAILED (total time: 1 second)

*************************************************************************************


On 3/1/07, Ravinder Reddy <ra...@gmail.com> wrote:
>
> No , I never tried to build Derby outside of Netbeans..!!. And I installed
> jdk1.5
> 2 months back and I downloaded the Derby Source from the latest Official
> Release..!!
> Thank You..!!
>
> On 3/1/07, John Embretsen <Jo...@sun.com> wrote:
> >
> > Ravinder Reddy wrote:
> > >             I followed the instruction in the Article But I got the
> > > following error when I try to build derby in Netbeans.!!!
> > > Error.....!!!
> > >             Fatal Error: Unable to find package java.lang in classpath
> > > or bootclasspath
> > > plzz look into this and reply.. Thank You
> >
> > This tends to happen when there is something wrong with the Java (JDK)
> > setup/installation. Are you sure you followed the instructions in
> > BUILDING.txt
> > regarding installing JDKs and configuring your ant.properties file? I
> > guess the
> > question is: Have you successfully built Derby before (outside of
> > NetBeans)?
> >
> > Where in the build process does this happen (which ant target)?
> >
> >
> > --
> > John
> >
> >
>

Re: Building Derby in NetBeans

Posted by Knut Anders Hatlen <Kn...@Sun.COM>.
Ravinder Reddy <ra...@gmail.com> writes:

> No , I never tried to build Derby outside of Netbeans..!!. And I installed
> jdk1.5
> 2 months back and I downloaded the Derby Source from the latest Official
> Release..!!
> Thank You..!!

You also need to install JDK 1.3 and JDK 1.4 to build Derby. When you
have done so, put this in ~/ant.properties:

j13lib=<path-to-your-jdk13-installation>/jre/lib
j14lib=<path-to-your-jdk14-installation>/jre/lib

-- 
Knut Anders

Re: Building Derby in NetBeans

Posted by Ravinder Reddy <ra...@gmail.com>.
No , I never tried to build Derby outside of Netbeans..!!. And I installed
jdk1.5
2 months back and I downloaded the Derby Source from the latest Official
Release..!!
Thank You..!!

On 3/1/07, John Embretsen <Jo...@sun.com> wrote:
>
> Ravinder Reddy wrote:
> >             I followed the instruction in the Article But I got the
> > following error when I try to build derby in Netbeans.!!!
> > Error.....!!!
> >             Fatal Error: Unable to find package java.lang in classpath
> > or bootclasspath
> > plzz look into this and reply.. Thank You
>
> This tends to happen when there is something wrong with the Java (JDK)
> setup/installation. Are you sure you followed the instructions in
> BUILDING.txt
> regarding installing JDKs and configuring your ant.properties file? I
> guess the
> question is: Have you successfully built Derby before (outside of
> NetBeans)?
>
> Where in the build process does this happen (which ant target)?
>
>
> --
> John
>
>

Re: Building Derby in NetBeans

Posted by John Embretsen <Jo...@Sun.COM>.
Ravinder Reddy wrote:
>             I followed the instruction in the Article But I got the 
> following error when I try to build derby in Netbeans.!!!
> Error.....!!!
>             Fatal Error: Unable to find package java.lang in classpath 
> or bootclasspath
> plzz look into this and reply.. Thank You

This tends to happen when there is something wrong with the Java (JDK) 
setup/installation. Are you sure you followed the instructions in BUILDING.txt 
regarding installing JDKs and configuring your ant.properties file? I guess the 
question is: Have you successfully built Derby before (outside of NetBeans)?

Where in the build process does this happen (which ant target)?


-- 
John


Re: Building Derby in NetBeans

Posted by Ravinder Reddy <ra...@gmail.com>.
            I followed the instruction in the Article But I got the
following error when I try to build derby in Netbeans.!!!
Error.....!!!
            Fatal Error: Unable to find package java.lang in classpath or
bootclasspath
plzz look into this and reply.. Thank You
On 2/28/07, John Embretsen <Jo...@sun.com> wrote:
>
> I just added a section on the "BuildingDerby" wiki page on how to checkout
> (from
> svn) and build Derby using NetBeans (version 5.5, primarily):
>
> http://wiki.apache.org/db-derby/BuildingDerby#UsingNetBeansToBuildDerby
>
> Feel free to try it out and fix or report errors/omissions.
>
>
> Thanks,
>
> --
> John
>
>
>