ports/127509: [PATCH] ports mail/mutt-devel and news/tin install conflicting manual pages

N.J. Mann njm at njm.me.uk
Sat Sep 20 16:40:04 UTC 2008


>Number:         127509
>Category:       ports
>Synopsis:       [PATCH] ports mail/mutt-devel and news/tin install conflicting manual pages
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sat Sep 20 16:40:03 UTC 2008
>Closed-Date:
>Last-Modified:
>Originator:     N.J. Mann
>Release:        FreeBSD 7.1-PRERELEASE i386
>Organization:
>Environment:
System: FreeBSD oberon.njm.f2s.com 7.1-PRERELEASE FreeBSD 7.1-PRERELEASE #3: Mon Sep 15 13:57:57 BST 2008 njm at oberon.njm.f2s.com:/usr/obj/usr/src7/sys/Oberon i386

	Up-to-date ports system (mine is updated nightly at 4 am UTC).

>Description:
	The ports mail/mutt-devel and news/tin both install the manual pages
mbox(5) and mmdf(5), although the content of both is different between the
two ports.  If one installs both ports and then de-installs one of them
these manual pages will be removed, which may not be what the user expects.
Also, during upgrades if the older of the two is being upgraded the MD5
checks will fail causing a warning to be printed, which may cause confusion
to the user.

It could be argued that news/tin should not be installing mbox(5) and
mmdf(5) manual pages by default since it is primarily a news client.
However, some users do use it for email.  Because of that I offer a patch
for both ports which makes the installation of these two manual pages
optional.

>How-To-Repeat:
	Install news/tin and then mail/mutt-devel.  The latter installation
process will over-write the files installed by the installation of the
former.
>Fix:
	The patches included below offer user options to not install the
manual pages mbox(5) and mmdf(5).  The user may then choose which port (if
any) should install and "own" these manual pages.

--- mutt-devel.patch.txt begins here ---
diff -ruN mail/mutt-devel~/Makefile mail/mutt-devel/Makefile
--- mail/mutt-devel~/Makefile	2008-08-20 01:56:56.000000000 +0100
+++ mail/mutt-devel/Makefile	2008-09-19 18:51:34.000000000 +0100
@@ -463,9 +463,15 @@
 
 WRKSRC=		${WRKDIR}/${DISTNAME:S/i$//}
 MAN1=		mutt.1 mutt_dotlock.1 flea.1 muttbug.1
-MAN5=		muttrc.5 mbox.5 mmdf.5
+MAN5=		muttrc.5
+.if !defined(WITHOUT_MUTT_MAILBOX_MANPAGES)
+MAN5+=		mbox.5 mmdf.5
+.endif
 
 post-patch::
+.if defined(WITHOUT_MUTT_MAILBOX_MANPAGES)
+	@${PATCH} ${PATCH_ARGS} < ${PATCHDIR}/extra-patch-no-mbox-manpage
+.endif
 	@${REINPLACE_CMD} -e 's,/usr/bin/gpg,${LOCALBASE}/bin/gpg,g' \
 		${WRKSRC}/contrib/gpg.rc
 	@${REINPLACE_CMD} -e 's,pgp6,pgp,g' \
diff -ruN mail/mutt-devel~/files/extra-patch-no-mbox-manpage mail/mutt-devel/files/extra-patch-no-mbox-manpage
--- mail/mutt-devel~/files/extra-patch-no-mbox-manpage	1970-01-01 01:00:00.000000000 +0100
+++ mail/mutt-devel/files/extra-patch-no-mbox-manpage	2008-09-19 18:56:17.000000000 +0100
@@ -0,0 +1,29 @@
+--- doc/Makefile.am~	2008-05-30 08:00:04.000000000 +0100
++++ doc/Makefile.am	2008-09-19 18:55:55.000000000 +0100
+@@ -18,8 +18,6 @@
+ 	gen-map-doc			\
+ 	muttrc.man.head			\
+ 	muttrc.man.tail			\
+-	mbox.man			\
+-	mmdf.man			\
+ 	manual.xml.head			\
+ 	manual.xml.tail			\
+ 	instdoc.sh.in			\
+@@ -57,8 +55,6 @@
+ 	test x at DOTLOCK_TARGET@ = x || ./instdoc $(srcdir)/dotlock.man \
+ 		$(DESTDIR)$(mandir)/man1/mutt_dotlock.1
+ 	./instdoc muttrc.man $(DESTDIR)$(mandir)/man5/muttrc.5
+-	./instdoc $(srcdir)/mbox.man $(DESTDIR)$(mandir)/man5/mbox.5
+-	./instdoc $(srcdir)/mmdf.man $(DESTDIR)$(mandir)/man5/mmdf.5
+ 	$(top_srcdir)/mkinstalldirs $(DESTDIR)$(docdir)
+ 	for f in $(topsrcdir_DOCFILES) ; do \
+ 		$(INSTALL) -m 644 $(top_srcdir)/$$f $(DESTDIR)$(docdir) ; \
+@@ -83,7 +79,7 @@
+ 	for f in mutt.1 mutt_dotlock.1 flea.1 muttbug.1 ; do \
+ 		rm -f $(DESTDIR)$(mandir)/man1/$$f ; \
+ 	done
+-	for f in muttrc.5 mbox.5 mmdf.5 ; do \
++	for f in muttrc.5 ; do \
+ 		rm -f $(DESTDIR)$(mandir)/man5/$$f ; \
+ 	done
+ 	for f in $(srcdir_DOCFILES) $(topsrcdir_DOCFILES) $(HTML_DOCFILES) ; \
--- mutt-devel.patch.txt ends here ---

--- tin.patch.txt begins here ---
diff -ruN news/tin~/Makefile news/tin/Makefile
--- news/tin~/Makefile	2008-06-06 14:55:03.000000000 +0100
+++ news/tin/Makefile	2008-09-19 14:35:50.000000000 +0100
@@ -63,7 +63,10 @@
 		LDFLAGS='${LDFLAGS} -L${LOCALBASE}/lib'
 ALL_TARGET=	build
 MAN1=		tin.1 w2r.pl.1 opt-case.pl.1 tinews.pl.1
-MAN5=		tin.5 mbox.5 mmdf.5
+MAN5=		tin.5
+.if !defined(WITHOUT_TIN_MAILBOX_MANPAGES)
+MAN5+=		mbox.5 mmdf.5
+.endif
 MLINKS=		tin.1 rtin.1
 
 .if defined(WITH_TIN_NNTP_ONLY)
@@ -102,6 +105,9 @@
 .endif
 
 post-patch:
+.if defined(WITHOUT_TIN_MAILBOX_MANPAGES)
+	@${PATCH} ${PATCH_ARGS} < ${PATCHDIR}/extra-patch-no-mbox-manpage
+.endif
 	${REINPLACE_CMD} -e 's:/var/spool/news:/var/news:g' \
 		-e 's:/etc/nntpserver:${PREFIX}/etc/nntpserver:g' \
 		-e 's:/usr/lib/news:${PREFIX}/news/lib:g' \
diff -ruN news/tin~/files/extra-patch-no-mbox-manpage news/tin/files/extra-patch-no-mbox-manpage
--- news/tin~/files/extra-patch-no-mbox-manpage	1970-01-01 01:00:00.000000000 +0100
+++ news/tin/files/extra-patch-no-mbox-manpage	2008-09-19 11:09:55.000000000 +0100
@@ -0,0 +1,13 @@
+--- src/Makefile.in~	2006-05-04 09:19:04.000000000 +0100
++++ src/Makefile.in	2008-09-19 11:01:52.000000000 +0100
+@@ -336,8 +336,8 @@
+ 	@$(INSTALL) -m 444 $(DOCDIR)/tin.1 $(DESTDIR)$(INS_MANUAL_DIR)$(INS_MANUAL_EXT)/$(PROJECT).$(INS_MANUAL_EXT)
+ 	@( $(CD) $(DESTDIR)$(INS_MANUAL_DIR)$(INS_MANUAL_EXT) && $(RM) -f r$(PROJECT).$(INS_MANUAL_EXT) && $(LN) $(PROJECT).$(INS_MANUAL_EXT) r$(PROJECT).$(INS_MANUAL_EXT) )
+ 	@$(INSTALL) -m 444 $(DOCDIR)/tin.5 $(DESTDIR)$(INS_MANUAL_DIR)5/$(PROJECT).5
+-	@-if test ! -f $(DESTDIR)$(INS_MANUAL_DIR)5/mbox.5 ; then $(INSTALL) -m 444 $(DOCDIR)/mbox.5 $(DESTDIR)$(INS_MANUAL_DIR)5/mbox.5 ; else $(ECHO) "  ... skipping $(DESTDIR)$(INS_MANUAL_DIR)5/mbox.5 - file already exists" ; fi
+-	@-if test ! -f $(DESTDIR)$(INS_MANUAL_DIR)5/mmdf.5 ; then $(INSTALL) -m 444 $(DOCDIR)/mmdf.5 $(DESTDIR)$(INS_MANUAL_DIR)5/mmdf.5 ; else $(ECHO) "  ... skipping $(DESTDIR)$(INS_MANUAL_DIR)5/mmdf.5 - file already exists" ; fi
++#	@-if test ! -f $(DESTDIR)$(INS_MANUAL_DIR)5/mbox.5 ; then $(INSTALL) -m 444 $(DOCDIR)/mbox.5 $(DESTDIR)$(INS_MANUAL_DIR)5/mbox.5 ; else $(ECHO) "  ... skipping $(DESTDIR)$(INS_MANUAL_DIR)5/mbox.5 - file already exists" ; fi
++#	@-if test ! -f $(DESTDIR)$(INS_MANUAL_DIR)5/mmdf.5 ; then $(INSTALL) -m 444 $(DOCDIR)/mmdf.5 $(DESTDIR)$(INS_MANUAL_DIR)5/mmdf.5 ; else $(ECHO) "  ... skipping $(DESTDIR)$(INS_MANUAL_DIR)5/mmdf.5 - file already exists" ; fi
+ 
+ uninstall_manpage :
+ 	@$(ECHO) "Uninstalling $(PROJECT) manual page in $(DESTDIR)$(INS_MANUAL_DIR)$(INS_MANUAL_EXT) ..."
--- tin.patch.txt ends here ---


>Release-Note:
>Audit-Trail:
>Unformatted:



More information about the freebsd-ports-bugs mailing list