From b9907e361c3e27aff5cc27225df1b6737b5febb5 Mon Sep 17 00:00:00 2001 From: brad Date: Fri, 19 Jan 2001 18:26:06 +0000 Subject: [PATCH] - FAKE_FLAGS is not needed anymore - use "cc -shared" on 2.8 and up to create shared libraries. - don't try to link shared libraries with libc. --- devel/pth/Makefile | 6 ++-- devel/pth/patches/patch-ltconfig | 47 +++++++++++++++++++++++++++++-- devel/pth/patches/patch-ltmain.sh | 25 ++++++++-------- 3 files changed, 59 insertions(+), 19 deletions(-) diff --git a/devel/pth/Makefile b/devel/pth/Makefile index a20b98b3279..73aa36f963b 100644 --- a/devel/pth/Makefile +++ b/devel/pth/Makefile @@ -1,8 +1,8 @@ -# $OpenBSD: Makefile,v 1.3 2000/09/24 07:04:04 brad Exp $ +# $OpenBSD: Makefile,v 1.4 2001/01/19 18:26:06 brad Exp $ DISTNAME= pth-1.3.7 CATEGORIES= devel -NEED_VERSION= 1.330 +NEED_VERSION= 1.336 MASTER_SITES= ${MASTER_SITE_GNU} MASTER_SITE_SUBDIR= pth @@ -15,8 +15,6 @@ PERMIT_PACKAGE_FTP= Yes PERMIT_DISTFILES_CDROM= Yes PERMIT_DISTFILES_FTP= Yes -FAKE_FLAGS= MFLAGS="DESTDIR=\"${WRKINST}\"" - CONFIGURE_STYLE= gnu CONFIGURE_ARGS+= ${CONFIGURE_SHARED} CONFIGURE_ARGS+= --enable-static --enable-pthread --enable-syscall-soft \ diff --git a/devel/pth/patches/patch-ltconfig b/devel/pth/patches/patch-ltconfig index 25f79ba2386..23ace4580d1 100644 --- a/devel/pth/patches/patch-ltconfig +++ b/devel/pth/patches/patch-ltconfig @@ -1,6 +1,47 @@ ---- ltconfig.orig Fri Jul 28 05:24:57 2000 -+++ ltconfig Fri Jul 28 05:25:26 2000 -@@ -2028,6 +2028,7 @@ +--- ltconfig.orig Sat May 27 07:15:00 2000 ++++ ltconfig Fri Jan 19 12:57:33 2001 +@@ -1105,6 +1105,9 @@ + with_gnu_ld=no + fi + ;; ++openbsd*) ++ with_gnu_ld=no ++ ;; + + esac + +@@ -1402,10 +1405,21 @@ + ;; + + openbsd*) +- archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linkopts' +- hardcode_libdir_flag_spec='-R$libdir' + hardcode_direct=yes + hardcode_shlibpath_var=no ++ case "$host_os" in ++ openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) ++ archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linkopts' ++ hardcode_libdir_flag_spec='-R$libdir' ++ ;; ++ *) ++ archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $linkopts' ++ hardcode_libdir_flag_spec='${wl}-rpath,$libdir' ++ if [ "`/usr/bin/file /usr/lib/libc.so.* | grep ELF`" != "" ]; then ++ export_dynamic_flag_spec='${wl}-E' ++ fi ++ ;; ++ esac + ;; + + os2*) +@@ -2021,13 +2035,10 @@ + + openbsd*) + version_type=sunos +- if test "$with_gnu_ld" = yes; then +- need_lib_prefix=no +- need_version=no +- fi library_names_spec='${libname}${release}.so$versuffix ${libname}.so$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' shlibpath_var=LD_LIBRARY_PATH diff --git a/devel/pth/patches/patch-ltmain.sh b/devel/pth/patches/patch-ltmain.sh index c2f9781613c..ca3277b0241 100644 --- a/devel/pth/patches/patch-ltmain.sh +++ b/devel/pth/patches/patch-ltmain.sh @@ -1,15 +1,16 @@ ---- ltmain.sh.orig Fri Jul 28 05:25:44 2000 -+++ ltmain.sh Fri Jul 28 05:25:55 2000 -@@ -2623,7 +2623,7 @@ - # linked before any other PIC object. But we must not use - # pic_flag when linking with -static. The problem exists in - # FreeBSD 2.2.6 and is fixed in FreeBSD 3.1. -- *-*-freebsd2*|*-*-freebsd3.0*|*-*-freebsdelf3.0*) -+ *-*-freebsd2*|*-*-freebsd3.0*|*-*-freebsdelf3.0*) - case "$compile_command " in - *" -static "*) ;; - *) pic_flag_for_symtable=" $pic_flag -DPIC -DFREEBSD_WORKAROUND";; -@@ -3567,40 +3567,6 @@ +--- ltmain.sh.orig Sat Oct 21 13:54:20 2000 ++++ ltmain.sh Sat Oct 21 13:54:11 2000 +@@ -1799,6 +1799,9 @@ + # rhapsody is a little odd... + deplibs="$deplibs -framework System" + ;; ++ *-*-openbsd*) ++ # do not include libc due to us having libc/libc_r. ++ ;; + *) + # Add libc to deplibs on all other systems. + deplibs="$deplibs -lc" +@@ -3567,40 +3570,6 @@ # Exit here if they wanted silent mode. test "$show" = : && exit 0