Hi, * Thomas Chojecki <[email protected]> [140710 01:00]: > Using libraries from the package repository can cause incompatibilities > between them. Because you will always get the latest version and not the > version the library like pdfbox need to be executed. > > >% echo $CLASSPATH > >/usr/share/java/pdfbox-1.8.6.jar:/usr/share/java/commons-logging-1.1.3.jar:/usr/share/java/fontbox-1.8.6.jar:/usr/share/java/jempbox-1.8.6.jar > > Looks good at the first look. pdfbox expect a commons-logging in the version > 1.1.1. but I think this would cause problems. > > >% java -cp /usr/share/java/pdfbox.jar org.apache.pdfbox.ExtractText > > With this call you will only add the pdfbox.jar into the classpath not the > other jars. Try something like this to test if it maybe work. > > % java -cp /usr/share/java/* org.apache.pdfbox.ExtractText
Just tried this and got: % java -cp /usr/share/java/* org.apache.pdfbox.ExtractText some_file.pdf Error: Could not find or load main class .usr.share.java.commons-logging-adapters-1.1.3.jar Also removed commons-logging-1.1.3 from my system, installed an older libcommons-logging-java_1.1.1-9_all.deb , changed CLASSPATH accordingly, but still get: Error: Could not find or load main class .usr.share.java.commons-logging-adapters-1.1.1.jar even added commons-logging-adapters-1.1.1.jar to the CLASSPATH (would that ever be necessary?): %echo $CLASSPATH /usr/share/java/pdfbox-1.8.6.jar:/usr/share/java/commons-logging-1.1.1.jar:/usr/share/java/fontbox-1.8.6.jar:/usr/share/java/jempbox-1.8.6.jar:/usr/share/java/commons-logging-adapters-1.1.1.jar still the same error... John -- John Magolske http://B79.net/contact

