summaryrefslogtreecommitdiff
path: root/mail
diff options
context:
space:
mode:
authorTijl Coosemans <tijl@FreeBSD.org>2014-06-11 14:49:59 +0000
committerTijl Coosemans <tijl@FreeBSD.org>2014-06-11 14:49:59 +0000
commit9f8b4bcde30c0ca3bf6cead5f48aa102536e0e92 (patch)
treec4f78cbaf45ab044db3e157be708afd711a4e841 /mail
parentForgot libreoffice itself in previous commit (diff)
Support LIBS like LDFLAGS.
- Add LIBS="${LIBS}" to MAKE_ENV and CONFIGURE_ENV. - Add an option helper for LIBS. - Adjust all ports that already use LIBS. Also remove references to PTHREAD_CFLAGS and PTHREAD_LIBS while here. - Some ports did not support having a LIBS environment variable and required additional patches. Somewhat simplified a linker command line looks like: ${CC} ${src_LDFLAGS} ${LDFLAGS} ${src_LIBS} ${LIBS} where src_LDFLAGS and src_LIBS are controlled by upstream and LDFLAGS and LIBS can be controlled by us. If possible -L and -l flags need to be added to LIBS to make sure they appear after any -L and -l flags set by upstream. Many ports currently add -L${LOCALBASE}/lib to LDFLAGS but this may appear too early on the command line causing installed libraries to be linked in instead of freshly built ones. Additional changes: benchmarks/netio: Replace WITH_IPV6 with an IPV6 option. comms/gnokii: Replace some patches with USES=pathfix. Also remove -fPIC. graphics/gimageview: USES=libtool and install desktop file in DESKTOPDIR. graphics/visionworkbench: Remove FreeBSD 7 support. multimedia/libmovtar: New LIB_DEPENDS syntax. multimedia/opencinematools: Use standard do-build. net/siproxd: USES=libtool:keepla (port actually needs .la files for plugins) net-mgmt/nagios: Remove -fPIC. net-mgmt/nagios4: Remove -fPIC. print/cups-base: Only add -lssp_nonshared on i386 and OSVERSION < 1000036. security/p11-kit: Replace PTHREAD_LIBS in CONFIGURE_ENV with ac_cv_func_pthread_mutexattr_init=no in CONFIGURE_ARGS. This skips a test in configure that falsely detects pthread_mutexattr_init in our libc. sysutils/dar: Fix iconv detection. x11/rxvt-unicode: Remove -lstdc++ and patch configure to remove a FreeBSD hack and use $CXX as linker as on other platforms. PR: 190592 Exp-run by: antoine Approved by: portmgr (antoine)
Notes
Notes: svn path=/head/; revision=357486
Diffstat (limited to 'mail')
-rw-r--r--mail/bogofilter/Makefile5
-rw-r--r--mail/crm114/Makefile12
-rw-r--r--mail/cyrus-imapd23/Makefile2
-rw-r--r--mail/cyrus-imapd24/Makefile2
-rw-r--r--mail/dspam-devel/Makefile5
-rw-r--r--mail/dspam/Makefile2
-rw-r--r--mail/gbuffy/Makefile2
-rw-r--r--mail/gmime2/Makefile2
-rw-r--r--mail/gmime24/Makefile2
-rw-r--r--mail/lmtp2nntp/files/patch-configure14
-rw-r--r--mail/mboxgrep/Makefile4
-rw-r--r--mail/milter-greylist-devel/Makefile1
-rw-r--r--mail/milter-greylist/Makefile1
-rw-r--r--mail/mmr/Makefile4
-rw-r--r--mail/popper/Makefile6
-rw-r--r--mail/popular/Makefile2
-rw-r--r--mail/qmailadmin/Makefile3
-rw-r--r--mail/qpopper/Makefile4
-rw-r--r--mail/smtpmail/Makefile2
-rw-r--r--mail/sylpheed/Makefile4
20 files changed, 37 insertions, 42 deletions
diff --git a/mail/bogofilter/Makefile b/mail/bogofilter/Makefile
index 6425eb4b7748..592294fc0f86 100644
--- a/mail/bogofilter/Makefile
+++ b/mail/bogofilter/Makefile
@@ -46,9 +46,8 @@ CONFIGURE_ARGS+= --sysconfdir=${PREFIX}/etc
BF_LIBS+= ${ICONV_LIB}
.endif
CPPFLAGS+= ${BF_CPPFLAGS}
-CONFIGURE_ENV+= LIBS="${BF_LIBS}" \
- PERL="${PERL}"
-LDFLAGS+= -L${LOCALBASE}/lib
+LIBS+= -L${LOCALBASE}/lib ${BF_LIBS}
+CONFIGURE_ENV+= PERL="${PERL}"
INSTALL_TARGET= install-strip prefix=${PREFIX} mandir=${MANPREFIX}/man
post-patch:
diff --git a/mail/crm114/Makefile b/mail/crm114/Makefile
index 23378507e445..c26265fa5627 100644
--- a/mail/crm114/Makefile
+++ b/mail/crm114/Makefile
@@ -30,11 +30,10 @@ OPTIONS_DEFINE= NORMALIZEMIME
NORMALIZEMIME_DESC= Normalize MIME encoding
MAKE_ARGS= CC="${CC}" prefix="${STAGEDIR}${PREFIX}" \
- LIBS="${LIBS}" \
+ CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" LIBS="${LIBS}" \
INSTALL_PROGRAM="${INSTALL_PROGRAM}"
CFLAGS+= -I${LOCALBASE}/include
-LDFLAGS+= -I${LOCALBASE}/include
LDFLAGS+= -L${LOCALBASE}/lib
LIBS+= -L${LOCALBASE}/lib ${ICONV_LIB} -lintl
@@ -51,13 +50,10 @@ CRM_FILES= mailfilter.crm mailfilter.cf mailreaver.crm mailtrainer.crm \
.include <bsd.port.options.mk>
-MAKE_ARGS+= CFLAGS="${CFLAGS}" \
- LDFLAGS="${LDFLAGS}"
-
post-patch:
- @${REINPLACE_CMD} -Ee \
- 's,^((LD|C)FLAGS),#\1,;;s,^(prefix=),#\1,;;s,^(.*-install),#\1,' \
- ${WRKSRC}/Makefile
+ @${REINPLACE_CMD} -E \
+ -e 's,^((LD|C)FLAGS),#\1,;;s,^(prefix=),#\1,;;s,^(.*-install),#\1,' \
+ -e 's,crmregex_tre.c,crmregex_tre.o,' ${WRKSRC}/Makefile
# Peter Jeremy recommended the use of b64decode and md5 20040302
post-install:
diff --git a/mail/cyrus-imapd23/Makefile b/mail/cyrus-imapd23/Makefile
index 7d4146aab5dd..61518bf04a4a 100644
--- a/mail/cyrus-imapd23/Makefile
+++ b/mail/cyrus-imapd23/Makefile
@@ -35,8 +35,8 @@ CONFIGURE_ARGS= --sysconfdir=${PREFIX}/etc \
--with-com_err \
--with-openssl=${OPENSSLBASE} \
--with-perl=${PERL5}
-CONFIGURE_ENV+= LIBS="-L${LOCALBASE}/lib"
CPPFLAGS+= -I${LOCALBASE}/include
+LIBS+= -L${LOCALBASE}/lib
MAKE_JOBS_UNSAFE= yes
OPTIONS_DEFINE= AUTOCREATE AUTOSIEVE BDB DRAC IDLED \
diff --git a/mail/cyrus-imapd24/Makefile b/mail/cyrus-imapd24/Makefile
index 10d6022e4fe0..cb5bcb2458b2 100644
--- a/mail/cyrus-imapd24/Makefile
+++ b/mail/cyrus-imapd24/Makefile
@@ -35,8 +35,8 @@ CONFIGURE_ARGS= --sysconfdir=${PREFIX}/etc \
--with-com_err \
--with-openssl=${OPENSSLBASE} \
--with-perl=${PERL5}
-CONFIGURE_ENV+= LIBS="-L${LOCALBASE}/lib"
CPPFLAGS+= -I${LOCALBASE}/include
+LIBS+= -L${LOCALBASE}/lib
MAKE_JOBS_UNSAFE= yes
OPTIONS_DEFINE= AUTOCREATE AUTOSIEVE BDB DRAC IDLED LDAP \
diff --git a/mail/dspam-devel/Makefile b/mail/dspam-devel/Makefile
index 95acf8c1f80d..4f4918d49e5c 100644
--- a/mail/dspam-devel/Makefile
+++ b/mail/dspam-devel/Makefile
@@ -93,11 +93,6 @@ USE_AUTOTOOLS+= autoconf:env automake
.endif
USE_LDCONFIG= yes
GNU_CONFIGURE= yes
-#CONFIGURE_ENV= LDFLAGS="-L${LOCALBASE}/lib"
-#CONFIGURE_ENV= CFLAGS="${CFLAGS} ${PTHREAD_CFLAGS}" \
-# CPPFLAGS="${CPPFLAGS} -I${LOCALBASE}/include" \
-# LDFLAGS="-L${LOCALBASE}/lib" \
-# LIBS="-L${LOCALBASE}/lib ${PTHREAD_LIBS}"
.ifdef(GDBS)
CFLAGS+= -g -DDEBUG
diff --git a/mail/dspam/Makefile b/mail/dspam/Makefile
index 64e9e0e8a294..6d2ee1b52455 100644
--- a/mail/dspam/Makefile
+++ b/mail/dspam/Makefile
@@ -76,10 +76,8 @@ MAKE_JOBS_UNSAFE= yes
USES= perl5 libtool shebangfix
USE_LDCONFIG= yes
GNU_CONFIGURE= yes
-CONFIGURE_ENV= LIBS="-L${LOCALBASE}/lib ${PTHREAD_LIBS}"
CPPFLAGS+= -I${LOCALBASE}/include
LDFLAGS+= -L${LOCALBASE}/lib
-CFLAGS+= ${PTHREAD_CFLAGS}
SHEBANG_FILES= src/tools/dspam_logrotate \
src/tools/dspam_notify.pl \
diff --git a/mail/gbuffy/Makefile b/mail/gbuffy/Makefile
index 3949e56919b0..66a267787349 100644
--- a/mail/gbuffy/Makefile
+++ b/mail/gbuffy/Makefile
@@ -16,7 +16,7 @@ LIB_DEPENDS= libPropList.so:${PORTSDIR}/devel/libPropList \
PLIST_FILES= bin/gbuffy
USE_GNOME= gtk12
GNU_CONFIGURE= yes
-CONFIGURE_ENV= LIBS="-L${LOCALBASE}/lib"
+LIBS+= -L${LOCALBASE}/lib
post-patch:
@${REINPLACE_CMD} -e 's|bindir)|DESTDIR)$$(&|' \
diff --git a/mail/gmime2/Makefile b/mail/gmime2/Makefile
index b3cdc4429f81..a7a91732ccfb 100644
--- a/mail/gmime2/Makefile
+++ b/mail/gmime2/Makefile
@@ -27,8 +27,8 @@ CONFIGURE_ARGS?= ${ICONV_CONFIGURE_BASE} \
--with-html-dir=${PREFIX}/share/doc \
--enable-mono=no \
--program-transform-name="s/uuencode/gmime-uuencode/;s/uudecode/gmime-uudecode/;"
-CONFIGURE_ENV= LIBS="-L${LOCALBASE}/lib"
CPPFLAGS+= -I${LOCALBASE}/include
+LIBS+= -L${LOCALBASE}/lib
OPTIONS_DEFINE= DOCS
diff --git a/mail/gmime24/Makefile b/mail/gmime24/Makefile
index 2f23ba7ef54f..7738b4e52068 100644
--- a/mail/gmime24/Makefile
+++ b/mail/gmime24/Makefile
@@ -28,8 +28,8 @@ GNU_CONFIGURE= yes
CONFIGURE_ARGS?=--with-html-dir=${PREFIX}/share/doc \
--enable-mono=no \
--program-transform-name="s/uuencode/gmime-uuencode/;s/uudecode/gmime-uudecode/;"
-CONFIGURE_ENV= LIBS="-L${LOCALBASE}/lib"
CPPFLAGS+= -I${LOCALBASE}/include
+LIBS+= -L${LOCALBASE}/lib
OPTIONS_DEFINE= DOCS
diff --git a/mail/lmtp2nntp/files/patch-configure b/mail/lmtp2nntp/files/patch-configure
index 94dc2ec1cb13..0fd480d02db1 100644
--- a/mail/lmtp2nntp/files/patch-configure
+++ b/mail/lmtp2nntp/files/patch-configure
@@ -1,6 +1,6 @@
--- configure.orig Thu Feb 13 11:01:47 2003
+++ configure Tue Apr 13 20:58:41 2004
-@@ -5845,9 +5845,9 @@
+@@ -6204,9 +6204,9 @@
SUBDIR_POPT=""
else
SUBDIR_POPT="lib_popt"
@@ -13,3 +13,15 @@
LIBS_EXTRA="$LIBS_EXTRA -lpopt"
fi
echo "$as_me:$LINENO: result: $with_popt" >&5
+@@ -6904,8 +6904,9 @@
+ echo "$as_me:$LINENO: result: $with_dmalloc" >&5
+ echo "${ECHO_T}$with_dmalloc" >&6
+
+-
+-LIBS="$LIBS_EXTRA $LIBS"
++LIBS_EXTRA="$LIBS_EXTRA $LIBS"
++unset LIBS
++LIBS="$LIBS_EXTRA"
+
+ enable_shared=no
+ export enable_shared
diff --git a/mail/mboxgrep/Makefile b/mail/mboxgrep/Makefile
index 61e0822c63c8..e28657e4387f 100644
--- a/mail/mboxgrep/Makefile
+++ b/mail/mboxgrep/Makefile
@@ -16,8 +16,8 @@ LIB_DEPENDS= pcre.3:${PORTSDIR}/devel/pcre
USES= uidfix
GNU_CONFIGURE= yes
-CONFIGURE_ENV+= LIBS="-L${LOCALBASE}/lib"
-CFLAGS+= -I${LOCALBASE}/include
+CPPFLAGS+= -I${LOCALBASE}/include
+LIBS+= -L${LOCALBASE}/lib
USE_OPENSSL= yes
INFO= mboxgrep
diff --git a/mail/milter-greylist-devel/Makefile b/mail/milter-greylist-devel/Makefile
index 339443da1601..d24ea0ee6f27 100644
--- a/mail/milter-greylist-devel/Makefile
+++ b/mail/milter-greylist-devel/Makefile
@@ -73,7 +73,6 @@ LIBS+= ${PTHREAD_LIBS}
GNU_CONFIGURE= yes
CONFIGURE_ARGS+= --with-user=mailnull --with-libmilter=${MILTERBASE} \
--enable-dnsrbl --with-thread-safe-resolver
-CONFIGURE_ENV+= LIBS="${LIBS} "
ALL_TARGET= milter-greylist
SUB_FILES+= pkg-message
diff --git a/mail/milter-greylist/Makefile b/mail/milter-greylist/Makefile
index 32e2fd25b8e2..e644777e74f7 100644
--- a/mail/milter-greylist/Makefile
+++ b/mail/milter-greylist/Makefile
@@ -77,7 +77,6 @@ GNU_CONFIGURE= yes
CONFIGURE_ARGS+= --with-user=mailnull --with-libmilter=${MILTERBASE} \
--enable-dnsrbl --with-thread-safe-resolver \
--with-dumpfile=/var/milter-greylist/greylist.db
-CONFIGURE_ENV+= LIBS="${LIBS}"
ALL_TARGET= milter-greylist
SUB_FILES+= pkg-message
diff --git a/mail/mmr/Makefile b/mail/mmr/Makefile
index 5f3a975889fc..522b6a8d5063 100644
--- a/mail/mmr/Makefile
+++ b/mail/mmr/Makefile
@@ -14,7 +14,7 @@ LICENSE= GPLv2
LICENSE_FILE= ${WRKSRC}/COPYING
USES= iconv
-MAKE_ARGS= LIBS='${LDFLAGS}' CXX='${CXX}' CXXFLAGS='${CXXFLAGS}'
+MAKE_ARGS= LIBS='${LIBS}' CXX='${CXX}' CXXFLAGS='${CXXFLAGS}'
ALL_TARGET= ${PORTNAME}
PORTDOCS= BUGS CHANGES Features README TODO
@@ -25,7 +25,7 @@ CXXFLAGS+= -DTHREADMAIL \
-DMAILPATH=\"/var/mail\" \
-DMAILER=\"/usr/sbin/sendmail\ -t\" \
-I${LOCALBASE}/include
-LDFLAGS+= -L${LOCALBASE}/lib ${ICONV_LIB} -lcurses -lmd
+LIBS+= -L${LOCALBASE}/lib ${ICONV_LIB} -lcurses -lmd
OPTIONS_DEFINE= DOCS EXAMPLES
diff --git a/mail/popper/Makefile b/mail/popper/Makefile
index 89f671a32078..7a15c56c3a88 100644
--- a/mail/popper/Makefile
+++ b/mail/popper/Makefile
@@ -26,7 +26,7 @@ O_DEFS= -DSETPROCTITLE -DKEEP_TEMP_DROP -DBSD44_DBM -DBIND43 \
-DBULLDB -DNONAUTHFILE='\"/etc/ftpusers\"'
.if !defined(WITH_POPPER_APOP_ONLY)
-P_LIBS= -lopie
+LIBS+= -lopie
O_DEFS+= -DOPIE
.else
O_DEFS+= -DAPOP_ONLY
@@ -36,7 +36,7 @@ O_DEFS+= -DAPOP_ONLY
O_DEFS+= -DYOUBIN -DCALLED_FROM_POPD
.endif
-P_LIBS+= -lmd -lutil
+LIBS+= -lmd -lutil
GNU_CONFIGURE= yes
CONFIGURE_ARGS= --enable-apop=${PREFIX}/etc/popper/pop.auth \
@@ -44,7 +44,7 @@ CONFIGURE_ARGS= --enable-apop=${PREFIX}/etc/popper/pop.auth \
.if defined(WITH_POPPER_DEBUG)
CONFIGURE_ARGS+= --enable-debugging
.endif
-CONFIGURE_ENV= LIBS="${P_LIBS}" O_DEFS="${O_DEFS}"
+CONFIGURE_ENV= O_DEFS="${O_DEFS}"
MAN8= popauth.8 popper.8
PLIST_FILES= bin/popauth libexec/popper
diff --git a/mail/popular/Makefile b/mail/popular/Makefile
index ef075b4ae8fe..f5731737fcbc 100644
--- a/mail/popular/Makefile
+++ b/mail/popular/Makefile
@@ -20,8 +20,8 @@ USE_OPENSSL= yes
PDM_MODULES= any master
CONFIGURE_ARGS= --without-bdb --disable-docbook --with-confdir=${PREFIX}/etc/popular \
--enable-ssl --with-pdm="${PDM_MODULES}"
-CONFIGURE_ENV= LIBS="-L${LOCALBASE}/lib"
CPPFLAGS+= -I${LOCALBASE}/include
+LIBS+= -L${LOCALBASE}/lib
USE_RC_SUBR= pcheckd pproxy pserv 0ringd
diff --git a/mail/qmailadmin/Makefile b/mail/qmailadmin/Makefile
index b055e9317a1a..741fc69bcd8f 100644
--- a/mail/qmailadmin/Makefile
+++ b/mail/qmailadmin/Makefile
@@ -93,8 +93,7 @@ EXTRA_PATCHES+= ${FILESDIR}/cracklib.patch
BUILD_DEPENDS+= ${LOCALBASE}/include/crack.h:${PORTSDIR}/security/cracklib
CONFIGURE_ARGS+= --enable-cracklib=${LOCALBASE}/libdata/cracklib/pw_dict
CFLAGS+= -I${LOCALBASE}/include
-LDFLAGS+= -L${LOCALBASE}/lib
-CONFIGURE_ENV+= LIBS="-lcrack"
+LIBS+= -L${LOCALBASE}/lib -lcrack
.endif
# vpopmail installation directory
diff --git a/mail/qpopper/Makefile b/mail/qpopper/Makefile
index bb310a3cb985..bfd0554e5107 100644
--- a/mail/qpopper/Makefile
+++ b/mail/qpopper/Makefile
@@ -14,11 +14,11 @@ COMMENT= Berkeley POP 3 server (now maintained by Qualcomm)
USE_GCC= any # -freg-struct-return only in GCC and clang-head
USE_AUTOTOOLS= autoconf
-CONFIGURE_ENV= LIBS="-lcrypt -lmd -lutil -L${LOCALBASE}/lib" \
- OS_DEFS="-DSETPROCTITLE ${OS_DEFS}"
+CONFIGURE_ENV= OS_DEFS="-DSETPROCTITLE ${OS_DEFS}"
CONFIGURE_ARGS= --enable-nonauth-file=${POPUSERS_FILE} \
--without-gdbm \
--enable-keep-temp-drop
+LIBS+= -L${LOCALBASE}/lib -lcrypt -lmd -lutil
PLIST_SUB= EPOPPASSD=${EPOPPASSD} \
USERS=${USERS} \
diff --git a/mail/smtpmail/Makefile b/mail/smtpmail/Makefile
index 4d92fbdef5bd..1d11c23bb380 100644
--- a/mail/smtpmail/Makefile
+++ b/mail/smtpmail/Makefile
@@ -11,8 +11,8 @@ MAINTAINER= ports@FreeBSD.org
COMMENT= Tool to send e-mail via a remote smtp server
GNU_CONFIGURE= yes
-CONFIGURE_ENV= LIBS="-L${LOCALBASE}/lib"
CPPFLAGS+= -I${LOCALBASE}/include
+LIBS+= -L${LOCALBASE}/lib
PLIST_FILES= bin/smtpmail
diff --git a/mail/sylpheed/Makefile b/mail/sylpheed/Makefile
index a720c4ed29d0..f931d833d9c7 100644
--- a/mail/sylpheed/Makefile
+++ b/mail/sylpheed/Makefile
@@ -21,10 +21,8 @@ USE_GNOME= gtk20
GNU_CONFIGURE= yes
USE_LDCONFIG= yes
-# Sylpheed needs pthread if GnomeVFS is installed (GtkFileChooser uses it)
-CONFIGURE_ENV= LIBS="-L${LOCALBASE}/lib ${PTHREAD_LIBS}"
CPPFLAGS+= -I${LOCALBASE}/include
-CFLAGS+= ${PTHREAD_CFLAGS}
+LIBS+= -L${LOCALBASE}/lib
CONFIGURE_ARGS= --enable-ipv6 \
--prefix=${PREFIX} \
--with-libintl-prefix=${LOCALBASE} \