From eec1a7c774123256ef5184d9ad362b0a70fe0d05 Mon Sep 17 00:00:00 2001 From: kevlo Date: Tue, 2 Mar 2004 04:46:43 +0000 Subject: [PATCH] fix stupid libtool. Pointed out by naddy@ and pval@ --- chinese/libtabe/Makefile | 3 +- chinese/libtabe/patches/patch-configure | 81 +++++++++++++++++++++++++ 2 files changed, 82 insertions(+), 2 deletions(-) create mode 100644 chinese/libtabe/patches/patch-configure diff --git a/chinese/libtabe/Makefile b/chinese/libtabe/Makefile index 8723bf8d743..7382d136b32 100644 --- a/chinese/libtabe/Makefile +++ b/chinese/libtabe/Makefile @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile,v 1.4 2004/02/19 06:19:25 kevlo Exp $ +# $OpenBSD: Makefile,v 1.5 2004/03/02 04:46:43 kevlo Exp $ COMMENT= "library for Chinese language processing" @@ -20,7 +20,6 @@ MASTER_SITES= ftp://xcin.linux.org.tw/pub/xcin/libtabe/devel/ LIB_DEPENDS= lib/db/db.3:db->3,<4:databases/db/v3 USE_X11= Yes -USE_LIBTOOL= Yes CONFIGURE_STYLE= gnu dest CONFIGURE_ARGS= --with-db-inc=${LOCALBASE}/include/db \ --with-db-lib=${LOCALBASE}/lib/db \ diff --git a/chinese/libtabe/patches/patch-configure b/chinese/libtabe/patches/patch-configure new file mode 100644 index 00000000000..2296c49f8d6 --- /dev/null +++ b/chinese/libtabe/patches/patch-configure @@ -0,0 +1,81 @@ +$OpenBSD: patch-configure,v 1.1 2004/03/02 04:46:46 kevlo Exp $ +--- configure.orig 2004-03-02 12:33:19.000000000 +0000 ++++ configure 2004-03-02 12:40:34.000000000 +0000 +@@ -2372,7 +2372,14 @@ old_postuninstall_cmds= + + if test -n "$RANLIB"; then + old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" +- old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds" ++ case "$host_os" in ++ openbsd*) ++ old_postinstall_cmds="\$RANLIB -t \$oldlib~$old_postinstall_cmds" ++ ;; ++ *) ++ old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds" ++ ;; ++ esac + fi + + # Allow CC to be a program name with arguments. +@@ -2895,7 +2902,9 @@ cygwin* | mingw* | pw32* ) + with_gnu_ld=no + fi + ;; +- ++openbsd*) ++ with_gnu_ld=no ++ ;; + esac + + ld_shlibs=yes +@@ -3299,10 +3308,21 @@ else + ;; + + openbsd*) +- archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' +- 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 $linker_flags' ++ hardcode_libdir_flag_spec='-R$libdir' ++ ;; ++ *) ++ archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $linker_flags' ++ hardcode_libdir_flag_spec='${wl}-rpath,$libdir' ++ if test "`echo __ELF__ | $CC -E - | grep __ELF__`" = "" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then ++ export_dynamic_flag_spec='${wl}-E' ++ fi ++ ;; ++ esac + ;; + + os2*) +@@ -3791,9 +3811,23 @@ newsos6) + + openbsd*) + version_type=sunos +- if test "$with_gnu_ld" = yes; then +- need_lib_prefix=no +- need_version=no ++ need_lib_prefix=no ++ need_version=no ++ file_magic_cmd=/usr/bin/file ++ file_magic_test_file=`echo /usr/lib/libc.so.*` ++ if test "`echo __ELF__ | $CC -E - | grep __ELF__`" = "" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then ++ deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB shared object' ++ case "$host_os" in ++ openbsd2.[89] | openbsd2.[89].*) ++ shlibpath_overrides_runpath=no ++ ;; ++ *) ++ shlibpath_overrides_runpath=yes ++ ;; ++ esac ++ else ++ deplibs_check_method='file_magic OpenBSD.* shared library' ++ shlibpath_overrides_runpath=yes + fi + library_names_spec='${libname}${release}.so$versuffix ${libname}.so$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'