--- Makefile.in.orig 2006-05-16 22:41:42.000000000 -0700 +++ Makefile.in 2006-05-16 22:44:32.000000000 -0700 @@ -18,8 +18,8 @@ # testprog targets. See also changes and comments in configure.in # -CFITSIO_LIB = @CFITSIO_PREFIX@/lib -CFITSIO_INCLUDE = @CFITSIO_PREFIX@/include +CFITSIO_LIB = @CFITSIO_PREFIX@/${LIBDIR} +CFITSIO_INCLUDE = @CFITSIO_PREFIX@/${INCLUDEDIR} SHELL = /bin/sh RANLIB = @RANLIB@ @@ -142,4 +142,4 @@ objs: ${CORE_OBJECTS} ${CFITSIO_LIB} ${CFITSIO_INCLUDE}: - @if [ ! -d $@ ]; then mkdir $@; fi + @if [ ! -d $@ ]; then mkdir -p $@; fi --- configure.orig 2006-05-16 22:41:34.000000000 -0700 +++ configure 2006-05-16 22:46:39.000000000 -0700 @@ -1230,6 +1230,8 @@ ;; lnx) SHLIB_LD=":" + LD_FLAGS="-shared -Wl,-soname,libcfitsio.so.0" + SHLIB_SUFFIX=".so.0" ;; osf) SHLIB_LD="ld -shared -expect_unresolved '*'" @@ -1249,7 +1251,7 @@ # Darwin uses gcc (=cc), but needs different flags (see above) # if test "x$GCC" = xyes; then if test "x$GCC" = xyes && test "x$EXT" != xdarwin && test "x$EXT" != xcygwin; then - SHLIB_LD="$CC -shared" + SHLIB_LD="gcc -shared -Wl,-soname,libcfitsio.so.0" lhea_shlib_cflags='-fPIC' fi if test "x$lhea_shlib_cflags" != x; then