db-derby-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Apache Wiki <wikidi...@apache.org>
Subject [Db-derby Wiki] Update of "BuildingDerby" by AndrewMcIntyre
Date Thu, 22 Feb 2007 04:12:38 GMT
Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Db-derby Wiki" for change notification.

The following page has been changed by AndrewMcIntyre:

The comment on the change is:
Add updated instructions for building with Eclipse that include Subclipse.

  Feel free to add your tips for building Derby below.
+ = Using Eclipse to Build Derby - Updated =
+ [[Anchor(UsingEclipseToBuildDerbyUpdated)]]
+  1. Install Subclipse if not already installed.
+    Go to Help -> Software Updates -> Find and Intall... and choose "Search for new
features to install" and click Next. At the next screen, click New Remote Site and enter Subclipse
for the name field and http://subclipse.tigris.org/update_1.2.x/ for the URL. This will add
the Subclipse update site to your list of update sites. Click Finish and Eclipse will search
for new features and updates to install. On the next screen, check the Subclipse box. If warned
that you do not have Mylar installed, expand the Subclipse box and uncheck the Mylar Integration
box. Click Next. You should be presented with the license terms for Subclipse. If you agree,
click the correct radio button to accept the license and click Next, then Finish, then Install
All to install/update Subclipse and related components. Right-click in the SVN Repository
frame and click New... to add a new repository location.
+  1. Check out the Derby codeline using Subclipse.
+    Open the SVN Repository Exploring perspective by going to Window -> Open Perspective
-> Other... and then double clicking on SVN Repository Exploring. Right-click in the SVN
Repository frame and choose New... and specify https://svn.apache.org/repos/asf/db/derby/code
as the Repository URL. Right-click on 'trunk' or expand the branches directory and right-click
on a branch name and choose Checkout.... Check out the project using the New Project Wizard,
so click Finish without changing anything. Select Java Project (usually the first option)
and click Next. Give the new project a name, and click Next. Add /classes to the Default Output
Folder so that the default is now '{projectname}/classes' and also click Remove project 'name'
from Build Path. We will configure the Build Path ourselves after checkout. Click Finish.
Subclipse will check out the Derby source files into a new project in your workspace.
+  1. Uncheck the Default builder.
+    Once the checkout is complete, right-click on the new project in the Package Explorer
and choose Properties. In the Properties window, select Builders. Uncheck the Java Builder.
Eclipse will pop up a dialog saying that unexpected things could occur. Click Ok.
+  1. Uncheck Build Automatically.
+    Go to the Project menu and make sure that Build Automatically is unchecked.
+  1. Follow the instructions in BUILDING.txt in the checkout regarding the placement of jars
and your ~/ant.properties.
+    If you follow the instructions correctly, you should be able to build the checked out
workspace from the command-line by running 'ant all'.
+  1. Add the source folders to the Java Build Path
+    Back in Eclipse, right-click on the new project in the Package Explorer and choose Properties.
In the Properties window, select Java Build Path. Select Add Folder... and then click the
checkbox for each of the folders in the java folder (build, client, drda, etc.) but NOT the
java folder itself. Click OK.
+  1. Add a new Ant Builder
+    While still in the Properties window, go to the Builders tab. Select New.... And choose
Ant Build. In the next screen, click Browse workspace... under Buildfile, and choose the top-level
build.xml. Go to the Targets tab, and in the Manual Build section, click the Set Targets...
button. Uncheck the default buildsource and select the all target. If you get an error that
com.sun.tools.javac could not be found and to check if your JAVA_HOME is set, you may need
to go to the Classpath tab and add tools.jar from your JDK 1.4.2 installation to the . 
+  1. Build 
+    Once your new Ant Builder is set up, ctrl-B (or cmd-B on the Mac) will start a Derby
+  1. JUnit Tests
+    Once a complete build has occurred, if you want to run JUnit tests, right-click on a
test class and select Run As... and then JUnit test. If it complains that there are errors
building, just ignore and select Run Anyway.
+ NOTE: Because some files are based on the JDBC 4.0 interfaces, there will be some files
marked as having errors by Eclipse, since they do not conform to the version of Java set as
your JRE System Library.
  = Using Eclipse to Build Derby =

View raw message