(1) JDK 1.3 does not support the Headless mode. Therefore setting the headless-flag has no effect there. (Headless mode was introduced in JDK 1.4)
To get something similiar to the Headless mode, you have to replace the AWT with something that does not try to use an X11-Server. Have a look at the Pure-Java-AWT, for instance.
(2) Your version of JCommon might be compiled with a JDK 1.4 compiler. If you get a ClassVersionError as original cause, then you will have to rebuild the jar using a JDK 1.3 compiler (or Jikes).