--- /dev/null
+--- physfs-0.1.9/test/Makefile.am.orig 2002-06-28 05:48:33.000000000 +0200
++++ physfs-0.1.9/test/Makefile.am 2003-10-17 22:36:24.845016512 +0200
+@@ -4,7 +4,7 @@
+
+ INCLUDES = -I$(top_srcdir)
+
+-test_physfs_LDADD = ../libphysfs.la
++test_physfs_LDADD = ../libphysfs.la $(LIBREADLINE)
+ test_physfs_SOURCES = test_physfs.c
+
+ endif
+--- physfs-0.1.9/configure.in.orig 2003-09-13 04:25:09.000000000 +0200
++++ physfs-0.1.9/configure.in 2003-10-17 22:36:05.753918800 +0200
+@@ -219,7 +219,8 @@
+ if test x$have_readline_hdr = xyes -a x$have_readline_lib = xyes; then
+ if test x$have_history_hdr = xyes -a x$have_history_lib = xyes; then
+ AC_DEFINE([PHYSFS_HAVE_READLINE], 1, [define if we have readline])
+- LIBS="$LIBS -lreadline -lcurses"
++ LIBREADLINE="-lreadline -lcurses"
++ AC_SUBST(LIBREADLINE)
+ fi
+ fi
+ fi