What version of GCJ are you using? In recent releases of GCJ (or maybe the upcoming release -- I haven't been tracking this) GNU Crypto is a part of libgcj. Like Raif wrote in his reply, replacing "gnu.crypto" with "gnu.java.security" in your code will work in a newer GCJ release. Compiling Classpath itself with an existing GCJ will likely not do what you want. You *should* be able to compile the gnu-crypto Jar to an .so, however. The command line for that would be something like this: gcj -shared -o libgnu-crypto.so gnu-crypto.jar Then you should be able to link your program against libgnu-crypto.so. You may also find more help with GCJ on their mailing list: see <http://gcc.gnu.org/lists.html>, the GCJ mailing list is <java@xxxxxxxxxxx>.