Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 23 Jan 2005 13:27:27 +0900 (JST)
From:      KIMURA Yasuhiro <yasu@utahime.org>
To:        freebsd-ports@freebsd.org
Subject:   maildrop 1.8.0 : How to get installed maildrop to find libcourierauth.so.0 ?
Message-ID:  <20050123.132727.74068960.yasu@utahime.org>

next in thread | raw e-mail | index | archive | help
Hello all.

I found latest version of maildrop is 1.8.0 and made patch below to
update mail/maildrop port. But it has one (at least, may be more)
known issue.

When build with WITH_AUTHLIB=yes, maildrop is linked with
libcourierauth.so.0 which is intalled by mail/courier-authlib port.
But installed maildrop binary doesn't find it.

yasu@sugar[21]% ls -l /usr/local/lib/courier-authlib/libcourierauth.so.0
-rwxr-xr-x  1 root  wheel  22608  1 23 02:13 /usr/local/lib/courier-authlib/libcourierauth.so.0*
yasu@sugar[22]% ldd /usr/local/bin/maildrop 
/usr/local/bin/maildrop:
        libcourierauth.so.0 => not found (0x0)
        libstdc++.so.3 => /usr/lib/libstdc++.so.3 (0x2808e000)
        libm.so.2 => /usr/lib/libm.so.2 (0x280d3000)
        libc.so.4 => /usr/lib/libc.so.4 (0x280ee000)
yasu@angel-vm-freebsd[23]% 

I know that this is because libcourierauth.so.0 is not installed in
the standard library path of dynamic linker and that solutions is to
add '-rpath /usr/local/lib/courier-authlib' to command line options
when maildrop is linked. Since I am not familiar with autoconf,
automake and libtool, however, I don't know where and how to patch
extracted source tree to get 'configure' script to create Makefile
which uses option above when maildrop is linked. 

Does anyone have suggestion, solution or patch for this issue?

Index: mail/maildrop/Makefile
===================================================================
RCS file: /net/cvsup/cvsroot/ports/mail/maildrop/Makefile,v
retrieving revision 1.32
diff -u -r1.32 Makefile
--- mail/maildrop/Makefile	4 Jul 2004 22:45:03 -0000	1.32
+++ mail/maildrop/Makefile	22 Jan 2005 18:34:41 -0000
@@ -7,11 +7,6 @@
 
 # The following compile-time options are available:
 # WITH_GDBM=yes		Enable database extensions using GDBM (default: off)
-# WITH_USERDB=yes	Enable optional userdb authentication
-# WITH_MAILDIRQUOTA=yes Enable optional support for maildir quotas
-# WITH_TRASHQUOTA=yes   Include deleted messages, and the Trash folder,
-#                       in the estimated quota usage for maildirs.
-#			Requires WITH_MAILDIRQUOTA.
 # MAILDROP_SUID=<uid>,
 # MAILDROP_SGID=<gid>	Maildrop will be installed with suid permissions for
 #			MAILDROP_SUID, and sgid permissions for MAILDROP_SGID.
@@ -20,12 +15,10 @@
 # MAILDROP_TRUSTED_USERS=<user> Specify users allowed to use the -d option
 # NO_MAILWRAPPER=yes	If defined, let configure guess which sendmail binary
 #			to use
-# WITH_LDAP=yes		Enable experimental virtual user LDAP support
-# WITH_MYSQL=yes	Enable experimental virtual user MySQL support
+# WITH_AUTHLIB=yes	Enable optional support for Courier Auth Library
 
 PORTNAME=	maildrop
-PORTVERSION=	1.6.3
-PORTREVISION=	1
+PORTVERSION=	1.8.0
 CATEGORIES=	mail
 MASTER_SITES=	${MASTER_SITE_SOURCEFORGE}
 MASTER_SITE_SUBDIR=	courier
@@ -35,13 +28,15 @@
 
 USE_BZIP2=	yes
 USE_PERL5=	yes
+USE_GMAKE=	yes
 GNU_CONFIGURE=	yes
 CONFIGURE_ENV=	CPPFLAGS="${CPPFLAGS}" LDFLAGS="${LDFLAGS}"
 CONFIGURE_ARGS=	--enable-syslog=1 \
-		--enable-use-flock \
+		--enable-use-flock=1 \
 		--with-etcdir="${PREFIX}/etc" \
 		--enable-maildrop-uid="${MAILDROP_SUID}" \
-		--enable-maildrop-gid="${MAILDROP_SGID}"
+		--enable-maildrop-gid="${MAILDROP_SGID}" \
+		--enable-maildirquota
 CONFIGURE_TARGET=	--build=${MACHINE_ARCH}-portbld-freebsd${OSREL}
 CPPFLAGS+=	-I${LOCALBASE}/include
 LDFLAGS+=	-L${LOCALBASE}/lib
@@ -55,29 +50,6 @@
 CONFIGURE_ARGS+=	--without-db
 .endif
 
-.if defined(WITH_USERDB)
-CONFIGURE_ARGS+=	--enable-userdb
-MAN1=		makedat.1
-MAN8=		makeuserdb.8 userdb.8 userdbpw.8
-MLINKS+=	makeuserdb.8 pw2userdb.8 \
-		makeuserdb.8 vchkpw2userdb.8
-EXTRA_TARGET+=	install-userdb install-makedat
-PLIST_SUB+=	USERDB=""
-.else
-PLIST_SUB+=	USERDB="@comment "
-.endif
-
-.if defined(WITH_MAILDIRQUOTA)
-CONFIGURE_ARGS+=	--enable-maildirquota
-.if defined(WITH_TRASHQUOTA)
-CONFIGURE_ARGS+=	--with-trashquota
-.endif
-EXTRA_TARGET+=	install-deliverquota
-PLIST_SUB+=	MAILDIRQUOTA=""
-.else
-PLIST_SUB+=	MAILDIRQUOTA="@comment "
-.endif
-
 .if !defined(NO_MAILWRAPPER)
 CONFIGURE_ARGS+=	--enable-sendmail=/usr/sbin/sendmail
 .endif
@@ -90,17 +62,11 @@
 CONFIGURE_ARGS+=	--enable-trusted-users="${MAILDROP_TRUSTED_USERS}"
 .endif
 
-.if defined(WITH_LDAP)
-USE_OPENLDAP=	yes
-CONFIGURE_ARGS+=	--enable-maildropldap \
-			--with-ldapconfig=${PREFIX}/etc/maildropldap.config
-.endif
-
-.if defined(WITH_MYSQL)
-USE_MYSQL=	yes
-CONFIGURE_ARGS+=	--enable-maildropmysql \
-			--with-mysqlconfig=${PREFIX}/etc/maildropmysql.config
-LDFLAGS+=		-L${LOCALBASE}/lib/mysql
+.if defined(WITH_AUTHLIB)
+BUILD_DEPENDS=	${LOCALBASE}/bin/courierauthconfig:${PORTSDIR}/mail/courier-authlib
+RUN_DEPENDS=	${LOCALBASE}/bin/courierauthconfig:${PORTSDIR}/mail/courier-authlib
+.else
+CONFIGURE_ARGS+=	--disable-authlib
 .endif
 
 MAILDROP_SUID?=	root
@@ -108,15 +74,15 @@
 
 .if defined(NOPORTDOCS)
 # Just install the binary and man pages, no extra documentation
-INSTALL_TARGET=	install-maildrop install-man ${EXTRA_TARGET}
+INSTALL_TARGET=	install-maildrop install-deliverquota install-man
 .else
 INSTALL_TARGET=	install-strip
 .endif
 
 MAN1+=	lockmail.1 mailbot.1 maildirmake.1 maildrop.1 makemime.1 \
 	reformail.1 reformime.1
-MAN5=	maildir.5 maildropex.5 maildropfilter.5 maildropgdbm.5
-MAN7=	maildirquota.7
+MAN5=	maildir.5
+MAN7=	maildirquota.7 maildropex.7 maildropfilter.7 maildropgdbm.7
 MAN8+=	deliverquota.8
 DOCS=	AUTHORS INSTALL INSTALL.html README README.html README.postfix \
 	UPGRADE UPGRADE.html maildroptips.txt maildir/README.*
Index: mail/maildrop/distinfo
===================================================================
RCS file: /net/cvsup/cvsroot/ports/mail/maildrop/distinfo,v
retrieving revision 1.15
diff -u -r1.15 distinfo
--- mail/maildrop/distinfo	30 Jan 2004 16:03:25 -0000	1.15
+++ mail/maildrop/distinfo	22 Jan 2005 11:23:30 -0000
@@ -1,2 +1,2 @@
-MD5 (maildrop-1.6.3.tar.bz2) = bfb3ac8e182285fb683631ddfebd26fb
-SIZE (maildrop-1.6.3.tar.bz2) = 658173
+MD5 (maildrop-1.8.0.tar.bz2) = caf59c78d6689b4cfba98d979af63407
+SIZE (maildrop-1.8.0.tar.bz2) = 2013203
Index: mail/maildrop/pkg-descr
===================================================================
RCS file: /net/cvsup/cvsroot/ports/mail/maildrop/pkg-descr,v
retrieving revision 1.6
diff -u -r1.6 pkg-descr
--- mail/maildrop/pkg-descr	23 Dec 2003 16:33:36 -0000	1.6
+++ mail/maildrop/pkg-descr	22 Jan 2005 11:15:03 -0000
@@ -12,4 +12,4 @@
 
 maildrop can be used with sendmail, qmail, and other MTAs.
 
-WWW:	http://www.flounder.net/~mrsam/maildrop/
+WWW:	http://www.courier-mta.org/maildrop/
Index: mail/maildrop/pkg-plist
===================================================================
RCS file: /net/cvsup/cvsroot/ports/mail/maildrop/pkg-plist,v
retrieving revision 1.7
diff -u -r1.7 pkg-plist
--- mail/maildrop/pkg-plist	23 Dec 2003 16:33:36 -0000	1.7
+++ mail/maildrop/pkg-plist	22 Jan 2005 15:27:07 -0000
@@ -1,24 +1,18 @@
 @comment $FreeBSD: ports/mail/maildrop/pkg-plist,v 1.7 2003/12/23 16:33:36 sergei Exp $
-%%MAILDIRQUOTA%%bin/deliverquota
+bin/deliverquota
 bin/lockmail
 bin/mailbot
 bin/maildirmake
 bin/maildrop
-%%USERDB%%bin/makedat
-%%USERDB%%bin/makedatprog
 bin/makemime
-%%USERDB%%bin/makeuserdb
-%%USERDB%%bin/pw2userdb
 bin/reformail
 bin/reformime
-%%USERDB%%bin/userdb
-%%USERDB%%bin/userdbpw
-%%USERDB%%bin/vchkpw2userdb
 %%PORTDOCS%%%%DOCSDIR%%/AUTHORS
 %%PORTDOCS%%%%DOCSDIR%%/INSTALL
 %%PORTDOCS%%%%DOCSDIR%%/INSTALL.html
 %%PORTDOCS%%%%DOCSDIR%%/README
 %%PORTDOCS%%%%DOCSDIR%%/README.html
+%%PORTDOCS%%%%DOCSDIR%%/README.imapkeywords.html
 %%PORTDOCS%%%%DOCSDIR%%/README.maildirfilter.html
 %%PORTDOCS%%%%DOCSDIR%%/README.maildirquota.html
 %%PORTDOCS%%%%DOCSDIR%%/README.maildirquota.txt
@@ -27,14 +21,12 @@
 %%PORTDOCS%%%%DOCSDIR%%/README.sharedfolders.txt
 %%PORTDOCS%%%%DOCSDIR%%/UPGRADE
 %%PORTDOCS%%%%DOCSDIR%%/UPGRADE.html
-%%MAILDIRQUOTA%%%%PORTDOCS%%%%DOCSDIR%%/deliverquota.html
+%%PORTDOCS%%%%DOCSDIR%%/deliverquota.html
 %%PORTDOCS%%%%DOCSDIR%%/lockmail.html
-%%USERDB%%%%PORTDOCS%%%%DOCSDIR%%/makedat.html
-%%USERDB%%%%PORTDOCS%%%%DOCSDIR%%/makeuserdb.html
 %%PORTDOCS%%%%DOCSDIR%%/mailbot.html
 %%PORTDOCS%%%%DOCSDIR%%/maildir.html
 %%PORTDOCS%%%%DOCSDIR%%/maildirmake.html
-%%MAILDIRQUOTA%%%%PORTDOCS%%%%DOCSDIR%%/maildirquota.html
+%%PORTDOCS%%%%DOCSDIR%%/maildirquota.html
 %%PORTDOCS%%%%DOCSDIR%%/maildrop.html
 %%PORTDOCS%%%%DOCSDIR%%/maildropex.html
 %%PORTDOCS%%%%DOCSDIR%%/maildropfilter.html
@@ -46,6 +38,4 @@
 %%PORTDOCS%%%%DOCSDIR%%/reformime.html
 %%PORTDOCS%%%%DOCSDIR%%/rfc2045.html
 %%PORTDOCS%%%%DOCSDIR%%/rfc822.html
-%%USERDB%%%%PORTDOCS%%%%DOCSDIR%%/userdb.html
-%%USERDB%%%%PORTDOCS%%%%DOCSDIR%%/userdbpw.html
 %%PORTDOCS%%@dirrm %%DOCSDIR%%
Index: mail/maildrop/files/patch-Makefile.in
===================================================================
RCS file: /net/cvsup/cvsroot/ports/mail/maildrop/files/patch-Makefile.in,v
retrieving revision 1.4
diff -u -r1.4 patch-Makefile.in
--- mail/maildrop/files/patch-Makefile.in	23 Dec 2003 16:33:36 -0000	1.4
+++ mail/maildrop/files/patch-Makefile.in	22 Jan 2005 14:55:29 -0000
@@ -1,35 +1,11 @@
---- Makefile.in.orig	Thu Oct 30 03:24:52 2003
-+++ Makefile.in	Tue Dec 23 17:45:42 2003
-@@ -29,7 +29,7 @@
- bindir = @bindir@
- sbindir = @sbindir@
- libexecdir = @libexecdir@
--datadir = @datadir@
-+datadir = ${PREFIX}/share/doc
- sysconfdir = @sysconfdir@
- sharedstatedir = @sharedstatedir@
- localstatedir = @localstatedir@
-@@ -104,8 +104,8 @@
- 
- EXTRA_DIST = README.html INSTALL.html UPGRADE.html README.postfix maildroptips.txt maildropldap.config maildropmysql.config automake.fix COPYING.GPL manpage.css
- 
--scriptdir = $(pkgdatadir)/scripts
+--- Makefile.in.orig	Sat Jan 22 23:54:33 2005
++++ Makefile.in	Sat Jan 22 23:54:58 2005
+@@ -230,7 +230,7 @@
+ SUBDIRS = numlib liblock unicode rfc822 rfc2045 gdbmobj bdbobj maildir maildrop
+ EXTRA_DIST = README.html INSTALL.html UPGRADE.html README.postfix maildroptips.txt automake.fix COPYING.GPL manpage.css
+ scriptdir = $(pkgdatadir)/scripts
 -htmldir = $(pkgdatadir)/html
-+scriptdir = $(bindir)
-+htmldir = $(pkgdatadir)
- 
- @INSTALL_USERDB_TRUE@USERDBHTML = userdb.html makeuserdb.html userdbpw.html
- @INSTALL_USERDB_FALSE@USERDBHTML = 
-@@ -854,12 +854,6 @@
- @INSTALL_USERDB_TRUE@	$(INSTALL_SCRIPT) userdb/pw2userdb $(DESTDIR)$(scriptdir)/pw2userdb
- @INSTALL_USERDB_TRUE@	$(INSTALL_SCRIPT) userdb/userdbpw $(DESTDIR)$(scriptdir)/userdbpw
- @INSTALL_USERDB_TRUE@	$(INSTALL_SCRIPT) userdb/vchkpw2userdb $(DESTDIR)$(scriptdir)/vchkpw2userdb
--@INSTALL_USERDB_TRUE@	rm -f $(DESTDIR)$(bindir)/userdb $(DESTDIR)$(bindir)/maildrop.userdb
--@INSTALL_USERDB_TRUE@	rm -f $(DESTDIR)$(bindir)/makeuserdb $(DESTDIR)$(bindir)/maildrop.makeuserdb
--@INSTALL_USERDB_TRUE@	rm -f $(DESTDIR)$(bindir)/pw2userdb $(DESTDIR)$(bindir)/maildrop.pw2userdb
--@INSTALL_USERDB_TRUE@	for f in userdb userdbpw makeuserdb pw2userdb vchkpw2userdb ; do \
--@INSTALL_USERDB_TRUE@		rm -f $(DESTDIR)$(bindir)/$$f ; \
--@INSTALL_USERDB_TRUE@		$(LN_S) $(scriptdir)/$$f $(DESTDIR)$(bindir)/$$f ; done
- @INSTALL_USERDB_TRUE@	cd $(DESTDIR)$(man8dir); rm -f pw2userdb.8 vchkpw2userdb.8 ; \
- @INSTALL_USERDB_TRUE@		$(LN_S) makeuserdb.8 pw2userdb.8 ; \
- @INSTALL_USERDB_TRUE@		$(LN_S) makeuserdb.8 vchkpw2userdb.8
++htmldir = $(datadir)/doc/@PACKAGE@
+ DELIVERQUOTAHTMLSOURCE = maildirquota.html deliverquota.html
+ @INSTALL_DELIVERQUOTA_FALSE@DELIVERQUOTAHTML = 
+ @INSTALL_DELIVERQUOTA_TRUE@DELIVERQUOTAHTML = $(DELIVERQUOTAHTMLSOURCE)
Index: mail/maildrop/files/patch-maildrop_configure
===================================================================
RCS file: mail/maildrop/files/patch-maildrop_configure
diff -N mail/maildrop/files/patch-maildrop_configure
--- mail/maildrop/files/patch-maildrop_configure	23 Dec 2003 16:33:36 -0000	1.1
+++ /dev/null	1 Jan 1970 00:00:00 -0000
@@ -1,20 +0,0 @@
---- maildrop/configure.orig	Thu Oct 30 03:25:02 2003
-+++ maildrop/configure	Mon Dec 22 20:03:49 2003
-@@ -7409,15 +7409,8 @@
- _ACEOF
- 
- 	use_mysql=1
--	LIBMYSQL="`mysql_config --libs`"
--
--	if test "$?" != 0
--	then
--		{ { echo "$as_me:$LINENO: error: Unable to run mysql_config" >&5
--echo "$as_me: error: Unable to run mysql_config" >&2;}
--   { (exit 1); exit 1; }; }
--	fi
--	CPPFLAGS="`mysql_config --cflags` $CPPFLAGS"
-+	LIBMYSQL="-lmysqlclient"
-+	CPPFLAGS="$CPPFLAGS"
-         ;;
- *)
-   	use_mysql=0


---
KIMURA Yasuhiro
Mail: yasu@utahime.org
WWW:  http://www.utahime.org/



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20050123.132727.74068960.yasu>