Troubleshooting Problems Building and Running

Last modified by Pascal Robert on 2007/12/15 18:37

Introduction

If you are having problems building or running, here are some things to check. The examples are given for Windows as that seems to be the source of the most problems. The principles apply, though the paths are different, for OS X.

wobuild.properties

Many things will not work if this is missing, incorrect, or incomplete.

On Mac OS X, the location for this file is:
/Users/<user name>/Library/wobuild.properties

On Windows, the location for this file is:
C:\Documents and Settings\<user name>\Library\wobuild.properties

Here is an example from Windows:


#This file stores the wo specific properties #Sat Mar 29 11:33:34 PST 2003
wo.dir.root=U:/Apple
wo.dir.user.home.library.frameworks=C:/Temp
wo.woroot=U:/Apple
wo.dir.local=U:/Apple/Local
wo.wosystemroot=U:/Apple
#wo.dir.user.home.library=C:/Documents and Settings/Chuck Hill/Local/Library
wo.dir.user.home.library=C:/Temp
wo.dir.library=U:/Apple/Library
wo.dir.local.library=U:/Apple/Local/Library
wo.dir.library.frameworks=U:/Apple/Library/Frameworks
wo.dir.local.library.frameworks=U:/Apple/Local/Library/Frameworks
wo.wolocalroot=U:/Apple/Local
wo.dir.system=U:/Apple
eclipse.home=U:/Programs/eclipse

For the curious, here is an example from OS X:


#This file stores the wo specific properties
#Wed Oct 11 19:51:09 PDT 2006
wo.dir.root=/
wo.woroot=/System
wo.dir.user.home.library.frameworks=/Users/chuck/Library/Frameworks
wo.dir.local=/
wo.wosystemroot=/System
wo.dir.library=/System/Library
wo.dir.user.home.library=/Users/chuck/Library
wo.dir.local.library=/Library
wo.dir.library.frameworks=/System/Library/Frameworks
wo.dir.local.library.frameworks=/Library/Frameworks
wo.wolocalroot=/
wo.dir.system=/System
wo.dir.reference.api=/Developer/ADC%20Reference%20Library/documentation/WebObjects/Reference/API/
Information

Note that for MacOSX 10.5 installs the last line above must be changed to wo.dir.reference.api=/Developer/Documentation/DocSets/com.apple.ADC_Reference_Library.WebObjectsReference.docset/Contents/Resources/Documents/reference/

Environment Variables

WebObjects makes use of some environmental variables. I am not sure which ones need to be set with WOLips, but these are the likely candidates:


HOMEDRIVE=C:
HOMEPATH=\Documents and Settings\<USER NAME>
JAVA_HOME=U:\Sun\j2sdk1.4.2_05
JRE_HOME=U:\Sun\j2sdk1.4.2_05\jre
NEXT_ROOT=U:/Apple
NEXT_SYSTEM_ROOT=U:/Apple
OS=Windows_NT
SystemDrive=C:
SystemRoot=C:\WINNT
TEMP=C:\TEMP
TMP=C:\TEMP
WEBOBJECTS_JAVA_EXTENSIONS=U:\Sun\j2sdk1.4.2_05/JRE/lib/ext
WEBOBJECTS_JAVA_HOME=U:\Sun\j2sdk1.4.2_05
windir=C:\WINNT

Problem Running Applications

If wobuild.properties (see above) is not correct, the application won't be able to launch. The error will look like this:


[2007-01-23 20:09:33 PST] <main> Unable to initialize WOProperties for reason: Cannot find JavaWebObjects framework !
java.lang.NullPointerException
[2007-01-23 20:09:33 PST] <main> A fatal exception occurred: null: <WOApplication>: Cannot be initialized.
[2007-01-23 20:09:33 PST] <main> com.webobjects.foundation.NSForwardException for java.lang.NullPointerException
at com.webobjects.appserver._private.WOProperties.initUserDefaultsKeys (WOProperties.java:188)
at com.webobjects.appserver.WOApplication._initWOApp (WOApplication.java:5081)
at com.webobjects.appserver.WOApplication.<init>(WOApplication.java:551)