patch for the configure-script for BSD-systems

[email protected] (Leich Tobias)
Newsgroups perl.sdl.devel
Message-ID <8461CBAAE7ADFE45B4E18F4B9AACF8FE06581310C4@TL01EXC01.TLTGES.local>
Hi, on BSD systems like OpenBSD, NetBSD, FreeBSD and Dragonfly you have to call 'ldconfig' with the option '-m'. Otherwise you overwrite its configured directory search path.

To reproduce this do:


1.       Get e.g. OpenBSD

2.       # ldconfig -r

/var/run/ld.so.hints:

        search directories: /usr/lib:/usr/X11R6/lib:/usr/local/lib

        0:-lm.5.2 => /usr/lib/libm.so.5.2

        1:-lmenu.4.0 => /usr/lib/libmenu.so.4.0

        ...

        150:-lXdmcp.10.0 => /usr/X11R6/lib/libXdmcp.so.10.0

3.       configure and make install of zlib

4.       # ldconfig -r

/var/run/ld.so.hints:

        search directories: /usr/lib

        0:-lm.5.2 => /usr/lib/libm.so.5.2

        1:-lmenu.4.0 => /usr/lib/libmenu.so.4.0

        ...

        40:-lz.4.1 => /usr/lib/libz.so.4.1

I have attached the patch for zlib-1.2.5. You can view it online here: http://bit.ly/9yYWz1

--
FROGGS


Scanned by MailDefender - managed email security from intY - www.maildefender.net
zlib-1.2.5-bsd-ldconfig.patch (application/octet-stream, 721 B)
--- zlib-1.2.5/configure       2010-04-20 06:15:19.000000000 +0200
+++ zlib-1.2.5/configure       2010-10-18 17:44:42.000000000 +0200
@@ -118,7 +118,10 @@
     uname=`(uname -s || echo unknown) 2>/dev/null`
   fi
   case "$uname" in
-  Linux* | linux* | GNU | GNU/* | *BSD | DragonFly) LDSHARED=${LDSHARED-"$cc -shared -Wl,-soname,libz.so.1,--version-script,zlib.map"} ;;
+  Linux* | linux* | GNU | GNU/*) LDSHARED=${LDSHARED-"$cc -shared -Wl,-soname,libz.so.1,--version-script,zlib.map"} ;;
+  *BSD | DragonFly)
+        LDSHARED=${LDSHARED-"$cc -shared -Wl,-soname,libz.so.1,--version-script,zlib.map"}
+        LDCONFIG="ldconfig -m" ;;
   CYGWIN* | Cygwin* | cygwin* | OS/2*)
         EXE='.exe' ;;
   MINGW*|mingw*)
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.