[csw-devel] SF.net SVN: gar:[14833] csw/mgar/pkg/sendmail/trunk

bonivart at users.sourceforge.net bonivart at users.sourceforge.net
Thu Jun 16 18:42:27 CEST 2011


Revision: 14833
          http://gar.svn.sourceforge.net/gar/?rev=14833&view=rev
Author:   bonivart
Date:     2011-06-16 16:42:27 +0000 (Thu, 16 Jun 2011)

Log Message:
-----------
sendmail/trunk: try alternatives, disable extra merge, disabe autoenable, test post message

Modified Paths:
--------------
    csw/mgar/pkg/sendmail/trunk/Makefile
    csw/mgar/pkg/sendmail/trunk/files/cswsendmail

Added Paths:
-----------
    csw/mgar/pkg/sendmail/trunk/files/CSWsendmail.postmsg

Modified: csw/mgar/pkg/sendmail/trunk/Makefile
===================================================================
--- csw/mgar/pkg/sendmail/trunk/Makefile	2011-06-16 10:45:39 UTC (rev 14832)
+++ csw/mgar/pkg/sendmail/trunk/Makefile	2011-06-16 16:42:27 UTC (rev 14833)
@@ -1,8 +1,9 @@
 # $Id$
 
 # TODO
+# - use alternatives to clear collisions with postfix, see gnuplot as example
+#   - tcpwrap, mutt. set 100 on both sendmail/postfix
 # - migrate conf from /opt/csw/etc/mail
-# - post message
 # - libmilter
 # - try to fix bugs
 #   - 2915 Must stop built-in sendmail manually
@@ -10,6 +11,8 @@
 #   - 4150 Sendmail 8.14.4 released
 #   - 4486 Provide sendmail's contrib/ tools as a separate package?
 
+# + post message
+# + never start cswsendmail by default (collides with system sendmail)
 # + path to sendmail.cf (/etc/opt/csw/mail)
 # + bdb hash support
 # + cpsample conf files
@@ -62,6 +65,7 @@
 SAMPLECONF += $(addprefix /etc/opt/csw/mail/,$(CONFFILES))
 SAMPLECONF += /var/opt/csw/spool/clientmqueue/sm-client.st
 USERGROUP   = /etc/opt/csw/pkg/CSWsendmail/cswusergroup
+POSTMSG     = $(docdir)/sendmail/README.postinstall
 
 # Enable support for files > 2GB in size.
 EXTRA_CFLAGS = -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE
@@ -85,14 +89,23 @@
 BUILD_SCRIPTS       = custom
 TEST_SCRIPTS        = custom
 INSTALL_SCRIPTS     = custom
-EXTRA_MERGE_SCRIPTS = OS
+#EXTRA_MERGE_SCRIPTS = OS
 
+# Some files collide with CSWpostfix
+ALTERNATIVE  = $(bindir)/mailq mailq $(bindir)/mailq1.sendmail 100
+ALTERNATIVE += $(bindir)/newaliases newaliases $(bindir)/newaliases.sendmail 100
+ALTERNATIVE += $(mandir)/man1/mailq.1 mailq1.1 $(mandir)/man1/mailq1.1.sendmail 100
+ALTERNATIVE += $(mandir)/man1/newaliases.1 newaliases.1 $(mandir)/man1/newaliases.1.sendmail 100
+ALTERNATIVE += $(mandir)/man5/aliases.5 aliases.5 $(mandir)/man5/aliases.5.sendmail 100
+
 # Collisions with Postfix naming it's files after the Sendmail de facto standard
-CHECKPKG_OVERRIDES_CSWsendmail += file-collision|/opt/csw/share/man/man1/mailq.1|CSWpostfix|CSWsendmail
-CHECKPKG_OVERRIDES_CSWsendmail += file-collision|/opt/csw/bin/newaliases|CSWpostfix|CSWsendmail
-CHECKPKG_OVERRIDES_CSWsendmail += file-collision|/opt/csw/share/man/man5/aliases.5|CSWpostfix|CSWsendmail
-CHECKPKG_OVERRIDES_CSWsendmail += file-collision|/opt/csw/bin/mailq|CSWpostfix|CSWsendmail
-CHECKPKG_OVERRIDES_CSWsendmail += file-collision|/opt/csw/share/man/man1/newaliases.1|CSWpostfix|CSWsendmail
+#CHECKPKG_OVERRIDES_CSWsendmail += file-collision|/opt/csw/bin/mailq|CSWpostfix|CSWsendmail
+#CHECKPKG_OVERRIDES_CSWsendmail += file-collision|/opt/csw/bin/newaliases|CSWpostfix|CSWsendmail
+#CHECKPKG_OVERRIDES_CSWsendmail += file-collision|/opt/csw/share/man/man1/mailq.1|CSWpostfix|CSWsendmail
+#CHECKPKG_OVERRIDES_CSWsendmail += file-collision|/opt/csw/share/man/man1/newaliases.1|CSWpostfix|CSWsendmail
+#CHECKPKG_OVERRIDES_CSWsendmail += file-collision|/opt/csw/share/man/man5/aliases.5|CSWpostfix|CSWsendmail
+# Surely this should not be needed
+CHECKPKG_OVERRIDES_CSWsendmail += surplus-dependency|CSWalternatives
 # Look thru these to see if they are harmless, e.g. examples
 CHECKPKG_OVERRIDES_CSWsendmail += file-with-bad-content|/usr/local|root/opt/csw/share/mail/cf/README
 CHECKPKG_OVERRIDES_CSWsendmail += file-with-bad-content|/usr/share|root/opt/csw/share/mail/cf/README
@@ -147,7 +160,7 @@
 	@$(MAKECOOKIE)
 
 install-custom:
-	@# install dirs
+	@# Install dirs
 	@echo " ==> Installing $(NAME) (custom)"
 	ginstall -d $(DESTDIR)$(libdir)
 	ginstall -d $(DESTDIR)$(bindir)
@@ -160,12 +173,12 @@
 	ginstall -d $(DESTDIR)/etc/opt/csw/init.d
 	ginstall -d $(DESTDIR)$(sysconfdir)/mail
 
-	@# install the libraries
+	@# Install the libraries
 	@( for file in $(LIBFILES) ; do \
 		ginstall -c -m 755 $(OBJDIR)/$$file $(DESTDIR)$(libdir) ; \
 		done )
 
-	@# install the binaries
+	@# Install the binaries
 	ginstall -m 755 $(OBJDIR)/$(BINFILES) $(DESTDIR)$(bindir)
 	( for file in $(SBINFILES) ; do \
 		ginstall -m 755 $(OBJDIR)/$$file $(DESTDIR)$(sbindir) ; \
@@ -182,7 +195,7 @@
 #		mv $(DESTDIR)$(sbindir)/$$file $(DESTDIR)$(sbindir)/$(SOLVER).$$file;\
 #		done )
 
-	@# install manpages
+	@# Install manpages
 	( for file in $(MANFILES1) ; do \
 		ginstall -m 644 $(OBJDIR)/$$file $(DESTDIR)$(mandir)/man1 ; \
 		done )
@@ -193,15 +206,15 @@
 		ginstall -m 644 $(OBJDIR)/$$file $(DESTDIR)$(mandir)/man8 ; \
 		done )
 
-	@# install m4/cf macros
+	@# Install m4/cf macros
 	find $(WORKSRC)/cf -type f -exec chmod 644 {} +
 	cp -r $(WORKSRC)/cf $(DESTDIR)$(sharedstatedir)/mail
 
-	@# install startup script
+	@# Install startup script
 	chmod +x $(DOWNLOADDIR)/cswsendmail && \
 		cp -p $(DOWNLOADDIR)/cswsendmail $(DESTDIR)/etc/opt/csw/init.d
 
-	@# install configurations, XXX missing submit.cf/sendmail.cf
+	@# Install configurations, XXX missing submit.cf/sendmail.cf
 	( for file in $(CONFFILES) ; do \
 		ginstall -m 644 $(DOWNLOADDIR)/$$file \
 		$(DESTDIR)$(sysconfdir)/mail/$$file; \
@@ -217,11 +230,27 @@
 	@ginstall -m 755 -d $(DESTDIR)$(docdir)/$(NAME)
 	@ginstall -m 644 $(FILEDIR)/README.CSW $(DESTDIR)$(docdir)/$(NAME)/
 
+	@# Create links in bindir
+	ln -s $(libdir)/sendmail $(DESTDIR)$(bindir)/newaliases
+	ln -s $(libdir)/sendmail $(DESTDIR)$(bindir)/mailq
+	ln -s $(libdir)/sendmail $(DESTDIR)$(bindir)/purgestats
+	ln -s $(libdir)/sendmail $(DESTDIR)$(bindir)/hoststat
+
+	@# Fix alternatives files
+	mv $(DESTDIR)$(bindir)/mailq $(DESTDIR)$(bindir)/mailq1.sendmail
+	mv $(DESTDIR)$(bindir)/newaliases $(DESTDIR)$(bindir)/newaliases.sendmail
+	mv $(DESTDIR)$(mandir)/man1/mailq.1 $(DESTDIR)$(mandir)/man1/mailq1.1.sendmail
+	mv $(DESTDIR)$(mandir)/man1/newaliases.1 $(DESTDIR)$(mandir)/man1/newaliases.1.sendmail
+	mv $(DESTDIR)$(mandir)/man5/aliases.5 $(DESTDIR)$(mandir)/man5/aliases.5.sendmail
+
+	@# Post install message
+	@ginstall -m 444 $(FILEDIR)/CSWsendmail.postmsg $(DESTDIR)$(docdir)/sendmail/README.postinstall
+
 	@$(MAKECOOKIE)
 
 merge-OS:
+	@echo " ==> Merging $(NAME) (custom)"
 	@# create links in bindir
-	@echo " ==> Merging $(NAME) (custom)"
 	ln -s $(libdir)/sendmail $(PKGROOT)$(bindir)/newaliases
 	ln -s $(libdir)/sendmail $(PKGROOT)$(bindir)/mailq
 	ln -s $(libdir)/sendmail $(PKGROOT)$(bindir)/purgestats

Added: csw/mgar/pkg/sendmail/trunk/files/CSWsendmail.postmsg
===================================================================
--- csw/mgar/pkg/sendmail/trunk/files/CSWsendmail.postmsg	                        (rev 0)
+++ csw/mgar/pkg/sendmail/trunk/files/CSWsendmail.postmsg	2011-06-16 16:42:27 UTC (rev 14833)
@@ -0,0 +1,45 @@
+=== SAMPLE FROM OTHER PACKAGES ===
+
+--- POSTFIX ---
+
+Note for users upgrading from postfix 2.4.6 and previous
+--------------------------------------------------------
+
+- Starting with postfix 2.6.x the spool location has changed from 
+
+    /opt/csw/var/spool/postfix to
+    /var/opt/csw/spool/postfix
+
+  If you have any pending email in the old spool location, please move
+  it to the new spool location and run "postsuper" before starting
+  postfix. An example script on how this can be done is shipped with the
+  package (migrate-queuefiles.sh). Make sure to understand what you are
+  doing.
+
+- Starting with postfix 2.6.x this package will _not_ automatically
+  substitute the common sendmail binaries with links to the postfix
+  binaries any more. Thus, the following files will be untouched and
+  possibly belong to the system sendmail installation.
+  
+    /usr/lib/sendmail
+    /usr/bin/mailq
+    /usr/bin/newaliases
+  
+  This makes the package installation less troublesome for shared zones
+  and leaves the choice of fully replacing your system sendmail up to you.
+  If you intend to replace those binaries above with the ones from this
+  postfix package, please see README.CSW.
+
+--- MUTT ---
+
+There are now two versions of mutt on the system installed:
+
+  * mutt-ncurses  with ncurses interface
+  * mutt-slang    with slang interface (per default linked to 'mutt')
+
+You can easily select between the versions with the alternatives(8)
+system by executing
+
+  /opt/csw/sbin/alternatives --config mutt
+
+See http://www.opencsw.org/packages/alternatives for details.

Modified: csw/mgar/pkg/sendmail/trunk/files/cswsendmail
===================================================================
--- csw/mgar/pkg/sendmail/trunk/files/cswsendmail	2011-06-16 10:45:39 UTC (rev 14832)
+++ csw/mgar/pkg/sendmail/trunk/files/cswsendmail	2011-06-16 16:42:27 UTC (rev 14833)
@@ -6,6 +6,9 @@
 #ident	"@(#)sendmail	1.19	01/12/05 SMI"
 # Modified for CSW by Alex Moore 01/01/2004
 
+# Magic comments for use with cswinitsmf
+#AUTOENABLE no
+
 ERRMSG1='WARNING: /var/mail is NFS-mounted without setting actimeo=0,'
 ERRMSG2='this can cause mailbox locking and access problems.'
 SERVER_PID_FILE="/var/run/sendmail.pid"


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.


More information about the devel mailing list