--- src/Makefile.am.orig	Sun Mar 27 12:53:08 2005
+++ src/Makefile.am	Wed Sep  7 19:25:03 2005
@@ -10,7 +10,7 @@
                 thread.h utf8.c zip.c zip.h properties.c direct.c interp.h \
                 interp-direct.h interp-indirect.h natives.h
 
-LDADD = -lpthread -ldl -lm @extra_libs@ os/@os@/@arch@/libnative.a
+LDADD = -lpthread @dlopen_lib@ -lm @extra_libs@ os/@os@/@arch@/libnative.a
 
 AM_CPPFLAGS = -DINSTALL_DIR=\"${prefix}\" -DCLASSPATH_INSTALL_DIR=\"${with_classpath_install_dir}\"
 
