Bug 187418 - mail/mutt: Build failure - Unknown `--is-lightweight' option
Summary: mail/mutt: Build failure - Unknown `--is-lightweight' option
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Ryan Steinmetz
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-03-10 12:50 UTC by Glen Barber
Modified: 2014-03-17 14:50 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Glen Barber freebsd_committer freebsd_triage 2014-03-10 12:50:00 UTC
The mail/mutt port fails to build.

root@nucleus:/usr/ports/mail/mutt # svnversion
347751
root@nucleus:/usr/ports/mail/mutt # make __MAKE_CONF=/dev/null rmconfig BATCH=1 clean build
===> No user-specified options configured for mutt-1.5.22
===>  Cleaning for mutt-1.5.22
===>   mutt-1.5.22 depends on file: /usr/local/sbin/pkg - found
===> Fetching all distfiles required by mutt-1.5.22 for building
===>  Extracting for mutt-1.5.22
=> SHA256 Checksum OK for mutt/mutt-1.5.22.tar.gz.
=> SHA256 Checksum OK for mutt/patch-1.5.22.rr.compressed.gz.
=> SHA256 Checksum OK for mutt/patch-1.5.22.vvv.initials.gz.
=> SHA256 Checksum OK for mutt/patch-1.5.22.vvv.quote.gz.
===>  Patching for mutt-1.5.22
===>  Applying distribution patches for mutt-1.5.22
===>  Applying FreeBSD patches for mutt-1.5.22
===>   mutt-1.5.22 depends on executable: xsltproc - found
===>   mutt-1.5.22 depends on file: /usr/local/share/xsl/docbook/html/docbook.xsl - found
===>   mutt-1.5.22 depends on executable: lynx - found
===>   mutt-1.5.22 depends on file: /usr/local/bin/automake-1.14 - found
===>   mutt-1.5.22 depends on file: /usr/local/bin/autoconf-2.69 - found
===>   mutt-1.5.22 depends on shared library: libintl.so - found
===>  Configuring for mutt-1.5.22
===>   FreeBSD 10 autotools fix applied to /usr/ports/mail/mutt/work/mutt-1.5.22/aclocal.m4
===>   FreeBSD 10 autotools fix applied to /usr/ports/mail/mutt/work/mutt-1.5.22/configure
configure.ac:16: installing './compile'
configure: loading site script /usr/ports/Templates/config.site
checking for a BSD-compatible install... /usr/bin/install -c -o root -g wheel
checking whether build environment is sane... yes
/usr/ports/mail/mutt/work/mutt-1.5.22/missing: Unknown `--is-lightweight' option
Try `/usr/ports/mail/mutt/work/mutt-1.5.22/missing --help' for more information
configure: WARNING: 'missing' script is too old or missing
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2014-03-10 12:50:07 UTC
Maintainer of mail/mutt,

Please note that PR ports/187418 has just been submitted.

If it contains a patch for an upgrade, an enhancement or a bug fix
you agree on, reply to this email stating that you approve the patch
and a committer will take care of it.

The full text of the PR can be found at:
    http://www.freebsd.org/cgi/query-pr.cgi?pr=ports/187418

-- 
Edwin Groothuis via the GNATS Auto Assign Tool
edwin@FreeBSD.org
Comment 2 Edwin Groothuis freebsd_committer freebsd_triage 2014-03-10 12:50:08 UTC
State Changed
From-To: open->feedback

Awaiting maintainers feedback (via the GNATS Auto Assign Tool)
Comment 3 Ryan Steinmetz freebsd_committer freebsd_triage 2014-03-14 12:07:18 UTC
You can resolve the build failure by removing references to -rpath in
LDFLAGS.

At present, this port fails to build under 11-CURRENT. config.log:

configure:3635: cc -I/usr/local/include -O2 -pipe  -fno-strict-aliasing
-L/usr/local/lib -rpath=/usr/local/lib:/usr/lib -ltinfow
-Wl,-rpath,/usr/lib:/usr/local/lib -Wl,-rpath=/usr/lib
cc: error: unknown argument: '-rpath=/usr/local/lib:/usr/lib'
...
configure:3682: error: in `/usr/ports/mail/mutt/work/mutt-1.5.23':
configure:3685: error: C compiler cannot create executables

-r
Comment 4 Udo.Schweigert 2014-03-16 20:34:46 UTC
OK, this is a problem related to clang as the new default compiler which
needs "-Wl," as prefix for linker options.

As I am on it: fix harmless warnings by removing an ancient autotools file
from the distributed source.


Here is a patch:

diff -ru  /usr/ports/mail/mutt/Makefile ./Makefile
--- /usr/ports/mail/mutt/Makefile	2014-03-15 06:06:48.000000000 +0100
+++ ./Makefile	2014-03-16 20:19:00.910638000 +0100
@@ -52,7 +52,7 @@
 .endif
 
 USE_AUTOTOOLS=	automake autoconf
-AUTOMAKE_ARGS=	--add-missing
+AUTOMAKE_ARGS=	--add-missing --foreign
 USE_OPENSSL=	yes
 
 .if defined (MUTT_LITE)
@@ -267,18 +267,18 @@
 .elif exists(${KRB5_HOME}/bin/krb5-config)
 LIB_DEPENDS+=		libgssapi_krb5.so:${PORTSDIR}/security/krb5
 CONFIGURE_ARGS+=	--with-gss=${KRB5_HOME}
-LDFLAGS+=		-L${KRB5_HOME}/lib -rpath=${KRB5_HOME}/lib -ltinfow
+LDFLAGS+=		-L${KRB5_HOME}/lib -Wl,-rpath=${KRB5_HOME}/lib -ltinfow
 .elif exists(${HEIMDAL_HOME}/bin/krb5-config)
 LIB_DEPENDS+=		libgssapi_krb5.so:${PORTSDIR}/security/krb5
 CONFIGURE_ARGS+=	--with-gss=${HEIMDAL_HOME}
-LDFLAGS+=		-L${HEIMDAL_HOME}/lib -rpath=${HEIMDAL_HOME}/lib -ltinfow
+LDFLAGS+=		-L${HEIMDAL_HOME}/lib -Wl,-rpath=${HEIMDAL_HOME}/lib -ltinfow
 .elif (defined(MAKE_KERBEROS5)) || exists(/usr/lib/libkrb5.a)
 CONFIGURE_ARGS+=	--with-gss
 WITH_KRB5_SYS=YES
 .endif
 .endif
 
-LDFLAGS+=		-L${LOCALBASE}/lib -rpath=${LOCALBASE}/lib:/usr/lib -ltinfow
+LDFLAGS+=		-L${LOCALBASE}/lib -Wl,-rpath=${LOCALBASE}/lib:/usr/lib -ltinfow
 CFLAGS+=		${CFLAGS_ADD}
 LDFLAGS+=		${LDFLAGS_ADD}
 
@@ -371,6 +371,7 @@
 
 pre-configure::
 	@(cd ${WRKSRC}; ${SETENV} ${AUTOMAKE_ENV} ${ACLOCAL} -I m4)
+	@${RM} -f ${WRKSRC}/missing
 .if defined(WITH_KRB5_SYS)
 	@${ECHO_CMD} "#define HAVE_HEIMDAL" >> ${WRKSRC}/config.h.in
 	@${REINPLACE_CMD} -e 's|<gssapi/gssapi\.h>|<gssapi.h>|' \
diff -ru  /usr/ports/mail/mutt/files/patch-Makefile.am ./files/patch-Makefile.am
--- /usr/ports/mail/mutt/files/patch-Makefile.am	2014-01-24 06:10:52.000000000 +0100
+++ ./files/patch-Makefile.am	2014-03-16 20:19:00.910638000 +0100
@@ -1,6 +1,15 @@
---- Makefile.am.orig	2008-05-19 19:00:44.000000000 +0200
-+++ Makefile.am	2008-05-19 19:03:20.000000000 +0200
-@@ -136,10 +136,6 @@
+--- Makefile.am.orig	2014-03-12 17:03:44.000000000 +0100
++++ Makefile.am	2014-03-16 17:22:07.000000000 +0100
+@@ -97,7 +97,7 @@
+ 
+ # If this fails, we will fall back to the implementation in txt2c.sh
+ txt2c: txt2c.c
+-	-$${NATIVECC-$(CC)} -o $@ $<
++	-$(CC) -o $@ $<
+ 
+ conststrings.c: txt2c config.status
+ 	( \
+@@ -162,10 +162,6 @@
  
  install-data-local:
  	$(srcdir)/mkinstalldirs $(DESTDIR)$(sysconfdir)
Comment 5 Ryan Steinmetz freebsd_committer freebsd_triage 2014-03-17 12:20:54 UTC
Responsible Changed
From-To: freebsd-ports-bugs->zi

I'll take it.
Comment 6 dfilter service freebsd_committer freebsd_triage 2014-03-17 14:48:55 UTC
Author: zi
Date: Mon Mar 17 14:48:52 2014
New Revision: 348479
URL: http://svnweb.freebsd.org/changeset/ports/348479
QAT: https://qat.redports.org/buildarchive/r348479/

Log:
  - Fix build with clang
  
  PR:		ports/187418
  Submitted by:	"Schweigert, Udo" <Udo.Schweigert@siemens.com> (maintainer)

Modified:
  head/mail/mutt/Makefile
  head/mail/mutt/files/patch-Makefile.am

Modified: head/mail/mutt/Makefile
==============================================================================
--- head/mail/mutt/Makefile	Mon Mar 17 14:46:53 2014	(r348478)
+++ head/mail/mutt/Makefile	Mon Mar 17 14:48:52 2014	(r348479)
@@ -52,7 +52,7 @@ CONFIGURE_ARGS+=	${MUTT_CONFIGURE_ARGS}
 .endif
 
 USE_AUTOTOOLS=	automake autoconf
-AUTOMAKE_ARGS=	--add-missing
+AUTOMAKE_ARGS=	--add-missing --foreign
 USE_OPENSSL=	yes
 
 .if defined (MUTT_LITE)
@@ -267,18 +267,18 @@ CONFIGURE_ARGS+=	--with-gss=${LOCALBASE}
 .elif exists(${KRB5_HOME}/bin/krb5-config)
 LIB_DEPENDS+=		libgssapi_krb5.so:${PORTSDIR}/security/krb5
 CONFIGURE_ARGS+=	--with-gss=${KRB5_HOME}
-LDFLAGS+=		-L${KRB5_HOME}/lib -rpath=${KRB5_HOME}/lib -ltinfow
+LDFLAGS+=		-L${KRB5_HOME}/lib -Wl,-rpath=${KRB5_HOME}/lib -ltinfow
 .elif exists(${HEIMDAL_HOME}/bin/krb5-config)
 LIB_DEPENDS+=		libgssapi_krb5.so:${PORTSDIR}/security/krb5
 CONFIGURE_ARGS+=	--with-gss=${HEIMDAL_HOME}
-LDFLAGS+=		-L${HEIMDAL_HOME}/lib -rpath=${HEIMDAL_HOME}/lib -ltinfow
+LDFLAGS+=		-L${HEIMDAL_HOME}/lib -Wl,-rpath=${HEIMDAL_HOME}/lib -ltinfow
 .elif (defined(MAKE_KERBEROS5)) || exists(/usr/lib/libkrb5.a)
 CONFIGURE_ARGS+=	--with-gss
 WITH_KRB5_SYS=YES
 .endif
 .endif
 
-LDFLAGS+=		-L${LOCALBASE}/lib -rpath=${LOCALBASE}/lib:/usr/lib -ltinfow
+LDFLAGS+=		-L${LOCALBASE}/lib -Wl,-rpath=${LOCALBASE}/lib:/usr/lib -ltinfow
 CFLAGS+=		${CFLAGS_ADD}
 LDFLAGS+=		${LDFLAGS_ADD}
 
@@ -371,6 +371,7 @@ post-patch::
 
 pre-configure::
 	@(cd ${WRKSRC}; ${SETENV} ${AUTOMAKE_ENV} ${ACLOCAL} -I m4)
+	@${RM} -f ${WRKSRC}/missing
 .if defined(WITH_KRB5_SYS)
 	@${ECHO_CMD} "#define HAVE_HEIMDAL" >> ${WRKSRC}/config.h.in
 	@${REINPLACE_CMD} -e 's|<gssapi/gssapi\.h>|<gssapi.h>|' \

Modified: head/mail/mutt/files/patch-Makefile.am
==============================================================================
--- head/mail/mutt/files/patch-Makefile.am	Mon Mar 17 14:46:53 2014	(r348478)
+++ head/mail/mutt/files/patch-Makefile.am	Mon Mar 17 14:48:52 2014	(r348479)
@@ -1,6 +1,15 @@
---- Makefile.am.orig	2008-05-19 19:00:44.000000000 +0200
-+++ Makefile.am	2008-05-19 19:03:20.000000000 +0200
-@@ -136,10 +136,6 @@
+--- Makefile.am.orig	2014-03-12 17:03:44.000000000 +0100
++++ Makefile.am	2014-03-16 17:22:07.000000000 +0100
+@@ -97,7 +97,7 @@
+ 
+ # If this fails, we will fall back to the implementation in txt2c.sh
+ txt2c: txt2c.c
+-	-$${NATIVECC-$(CC)} -o $@ $<
++	-$(CC) -o $@ $<
+ 
+ conststrings.c: txt2c config.status
+ 	( \
+@@ -162,10 +162,6 @@
  
  install-data-local:
  	$(srcdir)/mkinstalldirs $(DESTDIR)$(sysconfdir)
_______________________________________________
svn-ports-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-ports-all
To unsubscribe, send any mail to "svn-ports-all-unsubscribe@freebsd.org"
Comment 7 Ryan Steinmetz freebsd_committer freebsd_triage 2014-03-17 14:49:11 UTC
State Changed
From-To: feedback->closed

Fixed with latest commit.