Subject: pkg/19001: Patches for cyrus-sasl 2.1.9
To: None <gnats-bugs@gnats.netbsd.org>
From: None <sdegler@degler.net>
List: netbsd-bugs
Date: 11/10/2002 02:33:46
>Number: 19001
>Category: pkg
>Synopsis: Patches for cyrus-sasl2 package
>Confidential: no
>Severity: serious
>Priority: high
>Responsible: pkg-manager
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Sat Nov 09 23:34:00 PST 2002
>Closed-Date:
>Last-Modified:
>Originator: Stephen Degler
>Release: NetBSD 1.6H
>Organization:
Very Little, At Best
>Environment:
System: NetBSD host-unknown 1.6H NetBSD 1.6H (HOST-UNKNOWN) #1: Sun Sep 8 18:03:33 EDT 2002 sdegler@host-unknown:/vol1/NetBSD/kernels/HOST-UNKNOWN i386
Architecture: i386
Machine: i386
>Description:
I encountered problems with dynamic loading of plugins. Further
investigation uncovered the following problems:
1) Wrong version of ltconfig invoked.
2) DO_DLOPEN not properly defined due to #1 above and to problems
with autoconf macro tests within configure.in.
3) Problems with auxprop plugins not having all symbols defined.
AFAICT, most of the fixes are due to problems with the cyrus distribution
itself.
>How-To-Repeat:
build cyrus-sasl2. see it not work for any plugin mechanisms.
The sample programs will fail to run.
>Fix:
Applying these patches yields working plugins for me.
I'm certainly not an autoconf/libtool expert, so someone who feels
they know that stuff should look these over.
I'm particularly unhappy with patch-ai, because it hardcodes the
location of libtool. Perhaps if LTCONFIG_OVERRIDE behaved
differently this would not be needed?
--- Makefile 2002/10/27 23:32:36 1.2
+++ Makefile 2002/11/10 07:18:45
@@ -15,6 +15,7 @@
GNU_CONFIGURE= YES
USE_LIBTOOL= YES
LTCONFIG_OVERRIDE= ${WRKSRC}/config/ltconfig
+LIBTOOL_OVERRIDE= ${WRKSRC}/libtool
.include "../../mk/bsd.prefs.mk"
--- distinfo 2002/10/27 15:08:59 1.1.1.1
+++ distinfo 2002/11/10 07:18:45
@@ -2,7 +2,7 @@
SHA1 (cyrus-sasl-2.1.9.tar.gz) = 6e920454702796c8e6c8482b74ee19f8280bc80b
Size (cyrus-sasl-2.1.9.tar.gz) = 1274451 bytes
-SHA1 (patch-aa) = 20199f558a1a1147440a40334ea1132bf9b966fd
+SHA1 (patch-aa) = 8526f93e7f125620e7723c307611150220fdedb3
SHA1 (patch-ab) = f60a2df79744832495cb93e97ca5dfd7b1167415
SHA1 (patch-ac) = 828b3129769ee3224af31dd44fe8c9d6205c4bfa
SHA1 (patch-ad) = 1811fd87ccee6de8a151e8e684344e6f3a7a8830
@@ -10,3 +10,5 @@
SHA1 (patch-af) = 3af5330d1b3e242345ce9a7483ce6c73ed55d629
SHA1 (patch-ag) = 43f1e4417d872d189716f7831f50b3c55d5cd7e3
SHA1 (patch-ah) = 9f9121b63e28f9b07dfd9da4f7a786ff15097b58
+SHA1 (patch-ai) = 87bb0c5b5ff37bff5b60e8c58c92c9dd41e479f4
+SHA1 (patch-aj) = 49409200e6379068555a2a0427454a30b1db3a40
patches/patch-aa
--- configure.in.orig Fri Oct 11 16:56:29 2002
+++ configure.in Fri Nov 8 23:50:54 2002
@@ -86,13 +86,13 @@
dnl xxx we should add -W at some point (but that might scare people)
CFLAGS="-Wall ${CFLAGS}"
GCC_VERSION=`gcc -v 2>&1 | sed -n -e '/version/s/.*version \([[0-9]]\)\..*/\1/p'`
- if test "$GCC_VERSION" != "3"; then
- CPPFLAGS="${CPPFLAGS} -I/usr/local/include"
- fi
-else
- CPPFLAGS="${CPPFLAGS} -I/usr/local/include"
fi
-CMU_ADD_LIBPATH("/usr/local/lib")
+
+AC_PATH_PROG(SED, sed, no)
+if test "$SED" = "no"; then
+ AC_ERROR([sed is required to build sasl-config])
+fi
+AC_SUBST(SED)
AM_DISABLE_STATIC
@@ -649,7 +649,9 @@
# simon finishes trying to do autoconf
###############################################################################
-if test "$ac_cv_can_build_shared" = yes; then
+AC_MSG_CHECKING(ac_cv_prog_cc_can_build_shared)
+AC_MSG_RESULT($ac_cv_prog_cc_can_build_shared)
+if test "$ac_cv_prog_cc_can_build_shared" = yes; then
AC_DEFINE(DO_DLOPEN)
fi
@@ -832,6 +834,9 @@
LTLIBOBJS=`echo "$LIBOBJS" | sed 's/\.o/.lo/g'`
AC_SUBST(LIBOBJS)
AC_SUBST(LTLIBOBJS)
+
+dnl Check for /dev/urandom
+AC_CHECK_FILE(/dev/urandom, AC_DEFINE_UNQUOTED(SASL_DEV_RANDOM, "/dev/urandom"))
AC_C_CONST
AC_C_INLINE
patches/patch-ai
--- aclocal.m4.orig Fri Oct 11 16:57:57 2002
+++ aclocal.m4 Sat Nov 9 03:45:33 2002
@@ -23,8 +23,8 @@
LD="$LD" LDFLAGS="$LDFLAGS" LIBS="$LIBS" \
LN_S="$LN_S" NM="$NM" RANLIB="$RANLIB" \
DLLTOOL="$DLLTOOL" AS="$AS" OBJDUMP="$OBJDUMP" \
-${CONFIG_SHELL-/bin/sh} $ac_aux_dir/ltconfig --no-reexec \
-$libtool_flags --no-verify $ac_aux_dir/ltmain.sh $lt_target \
+${CONFIG_SHELL-/bin/sh} /usr/pkg/share/libtool/ltconfig --no-reexec \
+$libtool_flags --no-verify /usr/pkg/share/libtool/ltmain.sh $lt_target \
|| AC_MSG_ERROR([libtool configure failed])
# Reload cache, that may have been modified by ltconfig
@@ -809,7 +809,7 @@
AC_MSG_RESULT($dblib)
SASL_DB_BACKEND="db_${dblib}.lo"
-SASL_DB_BACKEND_STATIC="../sasldb/db_${dblib}.o ../sasldb/allockey.o"
+SASL_DB_BACKEND_STATIC="../sasldb/libsasldb.la"
SASL_DB_UTILS="saslpasswd2 sasldblistusers2"
SASL_DB_MANS="saslpasswd2.8 sasldblistusers2.8"
patches/patch-aj
--- plugins/Makefile.am.orig Sat Nov 9 01:21:59 2002
+++ plugins/Makefile.am Sat Nov 9 01:20:37 2002
@@ -263,7 +263,7 @@
libsasldb_la_SOURCES = sasldb.c sasldb_init.c $(common_sources)
libsasldb_la_LDFLAGS = -version-info $(sasldb_version)
libsasldb_la_DEPENDENCIES = $(COMPAT_OBJS)
-libsasldb_la_LIBADD = $(SASL_DB_LIB) $(COMPAT_OBJS)
+libsasldb_la_LIBADD = $(SASL_DB_BACKEND_STATIC) $(SASL_DB_LIB) $(COMPAT_OBJS)
# Auxprop Plugins
libmysql_la_SOURCES = mysql.c mysql_init.c $(common_sources)
>Release-Note:
>Audit-Trail:
>Unformatted: