Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

You'll need to configure your IDE such that you can compile the project using these JAXP jars.

Configuring the classpath

Here's the .classpath file I'm using locally. Notice that it does not declare the following .jars that are distributed in the /lib/ directory of uPortal:

...

Code Block
xml
xml
title.classpath
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
	<classpathentry kind="src" path="source"/>
	<classpathentry kind="src" path="tests"/>
	<classpathentry kind="lib" path="lib/activation.jar"/>
	<classpathentry kind="lib" path="lib/commons-logging.jar"/>
	<classpathentry kind="lib" path="lib/cos.jar"/>
	<classpathentry kind="lib" path="lib/hsqldb.jar"/>
	<classpathentry kind="lib" path="lib/jakarta-oro-2.0.8.jar"/>
	<classpathentry kind="lib" path="lib/junit.jar"/>
	<classpathentry kind="lib" path="lib/log4j-1.2.8.jar"/>
	<classpathentry kind="lib" path="lib/portlet-api-1.0.jar"/>
	<classpathentry kind="lib" path="lib/proxyportlet.jar"/>
	<classpathentry kind="lib" path="lib/servlet.jar"/>
	<classpathentry kind="lib" path="lib/tyrex-1.0.1.jar"/>
	<classpathentry kind="lib" path="lib/wsrp4j-consumer-0.3.jar"/>
	<classpathentry kind="lib" path="lib/wsrp4j-shared-0.3.jar"/>
	<classpathentry kind="lib" path="lib/commons-collections-3.1.jar"/>
	<classpathentry kind="lib" path="lib/commons-dbcp-1.2.1.jar"/>
	<classpathentry kind="lib" path="lib/commons-pool-1.2.jar"/>
	<classpathentry kind="lib" path="lib/spring.jar"/>
	<classpathentry kind="lib" path="lib/pluto-1.0.1-rc1.jar"/>
<!-- I've inserted a linebreak in the following entry to make it look nice in the Wiki -- you need to
  remove the linebreak between internal. and debug.ui... -->
	<classpathentry kind="con"
path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.
debug.ui.launcher.StandardVMType/jaxp13_1_4_2_04"/>
	<classpathentry kind="lib" path="lib/tidy.jar"/>
	<classpathentry kind="output" path="bin"/>
</classpath>

Configuring the JRE under which you build the project

The JRE under which you build the project needs to have the JAXP 1.3 jars installed and it needs to actually be using them.

Let's create a new JRE entry in Eclipse, so that we can continue to use a non-JAXP 1.3 JRE for other projects. We'll give this project its own JRE configuration.

In Window -> Preferences -> Java -> Installed JREs

Create a new JRE. Give it a name evocative of its use of JAXP 1.3, e.g. "jaxp13_1_4_2_04". The JRE home directory should be the directory of the JDK you've installed the JAXP 1.3 jars into, e.g. "C:\Copy of j2sdk1.4.2_04".

Uncheck "Use default system libraries". Click the now-activated "Add External Jars...". Navigate to the endorsed directory of the lib directory of the jre directory of that JDK. E.g,

"C:\Copy of j2sdk1.4.2_04\jre\lib\endorsed\"

Select the five .jars there: dom.jar, jaxp-api.jar, sax.jar, xalan.jar, and xercesImpl.jar, and add all of these.

Click "Ok" to exit "Edit JRE" and then click "Ok" to exit "Preferences".

Edit your project properties for the uPortal project (right click the project root folder and select "properties" from the contextual menu. Select "Java Build Path" from the left hand navigation pane. Click the "Libraries" tab. Select the JRE System Library and click the "Edit..." button. Choose from the alternate JRE pulldown the name of the alternate JRE you created above.

What to do if these instructions are insufficient

...