[csw-devel] SF.net SVN: gar:[5491] csw/mgar/pkg/postfix/branches/postfix-2.6

skayser at users.sourceforge.net skayser at users.sourceforge.net
Fri Jul 3 01:38:35 CEST 2009


Revision: 5491
          http://gar.svn.sourceforge.net/gar/?rev=5491&view=rev
Author:   skayser
Date:     2009-07-02 23:38:35 +0000 (Thu, 02 Jul 2009)

Log Message:
-----------
postfix 2.6: working copy, basic build

Modified Paths:
--------------
    csw/mgar/pkg/postfix/branches/postfix-2.6/Makefile
    csw/mgar/pkg/postfix/branches/postfix-2.6/checksums

Added Paths:
-----------
    csw/mgar/pkg/postfix/branches/postfix-2.6/files/CSWpostfix.cswusergroup

Modified: csw/mgar/pkg/postfix/branches/postfix-2.6/Makefile
===================================================================
--- csw/mgar/pkg/postfix/branches/postfix-2.6/Makefile	2009-07-02 20:18:38 UTC (rev 5490)
+++ csw/mgar/pkg/postfix/branches/postfix-2.6/Makefile	2009-07-02 23:38:35 UTC (rev 5491)
@@ -1,25 +1,31 @@
+# Status
+# - Basic configuration, build completes, packaging not yet tested
+# - Beware: uses a modified GARv2 for USERGROUP=
 # TODO
-# - Integrate the manifest with cswinitsmf
-# - Understand what the sed main.cf script is doing
-# - Build scripts to handle the spool location change
 # - Check open bugs
-# - Read postfix build instructions and verify CSW flags/lib/...
+# - Activate features (SSL, LDAP, *SQL, ...)
+# - Integrate the manifest from files/ with cswinitsmf
+# - Check sed main.cf script functionality, do we need this?
+# - Check update script functionality, add handling for spool location change
 # - See how the csw_conf_config for cfg files was handled in gar v1
+#   Does the currently available package preserve configuration files on
+#   removal?
 GARNAME = postfix
 GARVERSION = 2.6.2
 CATEGORIES = server
 
-DESCRIPTION = Postfix aims to be an alternative to the widely-used sendmail program
+DESCRIPTION = A high-performance mail transport agent
 define BLURB
-What is Postfix? It is Wietse Venema's mailer that started life as an 
-alternative to the widely-used Sendmail program. 
-
-Postfix attempts to be fast, easy to administer, and secure, while at the same 
-time being sendmail compatible enough to not upset existing users. Thus, the 
-outside has a sendmail-ish flavor, but the inside is completely different.
+  What is Postfix? It is Wietse Venema's mailer that started life as an
+  alternative to the widely-used Sendmail program. 
+  
+  Postfix attempts to be fast, easy to administer, and secure, while at
+  the same time being sendmail compatible enough to not upset existing
+  users. Thus, the outside has a sendmail-ish flavor, but the inside is
+  completely different.
 endef
 
-MASTER_SITES = http://mirrors.isc.org/pub/postfix/official/
+MASTER_SITES = ftp://ftp.porcupine.org/mirrors/postfix-release/official/
 DISTFILES  = $(GARNAME)-$(GARVERSION).tar.gz
 SPKG_SOURCEURL = http://www.postfix.org
 
@@ -31,52 +37,49 @@
 # We define upstream file regex so we can be notifed of new upstream software release
 UFILES_REGEX = $(GARNAME)-(\d+(?:\.\d+)*).tar.gz
 
-PREREQUISITE_PKGS = CSWbdb4 CSWmysql4devel CSWlibpq CSWossldevel CSWoldapdevel
-REQUIRED_PKGS = CSWbdb3 CSWlibpq CSWmysql4rt CSWoldaprt CSWosslrt CSWpcrert
-REQUIRED_PKGS += CSWsasl CSWzlib
+PREREQUISITE_PKGS = CSWpcre
+REQUIRED_PKGS = CSWpcrert
 
-SPKG_CLASSES = none cswusergroup cswcpsampleconf cswinitsmf
+# Tag files for cswclassutils
+CONFIG_BASE  = /etc/opt/csw/postfix/
+CONFIG_FILES  = access aliases canonical generic header_checks
+CONFIG_FILES += main.cf master.cf
+CONFIG_FILES += relocated transport virtual
 
+SAMPLECONF  = $(prefix $(CONFIG_BASE), $(CONFIG_FILES))
+INITSMF     = /etc/opt/csw/init.d/cswpostfix
+USERGROUP   = $(sysconfdir)/pkg/CSWpostfix/cswusergroup
+
+EXTRA_MERGE_EXCLUDE_FILES  = /etc/opt/csw/postfix/LICENSE
+EXTRA_MERGE_EXCLUDE_FILES += /etc/opt/csw/postfix/TLS_LICENSE
+EXTRA_MERGE_EXCLUDE_FILES += /etc/opt/csw/postfix/makedefs.out
+
+STRIP_DIRS = $(DESTDIR)$(libexecdir)/postfix
+
+
 CONFIGURE_SCRIPTS = custom
-BUILD_SCRIPTS     = custom
 TEST_SCRIPTS      =
 INSTALL_SCRIPTS   = custom
 
-CONFIG_BASE = \/etc\/opt\/csw\/postfix\/
-CONFIG_FILES = access aliases canonical generic header_checks
-CONFIG_FILES += main.cf master.cf
-CONFIG_FILES += relocated transport virtual
-
-PROTOTYPE_FILTER  = awk '\
-	$(foreach C,$(prefix $(CONFIG_BASE),$(CONFIG_FILES)), \
-		$$$$3 ~ /^$(C)$$$$/ { $$$$2 = "cswcpsampleconf" }) \
-	$$$$3 ~ /^\/etc\/default\/cswpostgrey$$$$/ { $$$$2 = "cswcpsampleconf" } \
-	$$$$3 ~ /\/init.d\/cswpostfix$$$$/ { $$$$2 = "cswinitsmf" } \
-	$$$$3 ~ /cswusergroup$$$$/ { $$$$2 = "cswusergroup" } \
-	 { print }'
-
 include gar/category.mk
 
+# Supporting documentation for building postfix
+# - Postfix Installation From Source Code 
+#   http://www.postfix.org/INSTALL.html
+# - Guidelines for Package Builders
+#   http://www.postfix.org/PACKAGE_README.html
+
 DEF_COMMAND_DIR    = /opt/csw/sbin
 DEF_CONFIG_DIR     = /etc/opt/csw/postfix
 DEF_DAEMON_DIR     = /opt/csw/libexec/postfix
 DEF_MAILQ_PATH     = /opt/csw/bin/mailq
-DEF_HTML_DIR       = yes
-DEF_MANPAGE_DIR    = /opt/csw/man
+DEF_HTML_DIR       = /opt/csw/share/doc/postfix/html
+DEF_MANPAGE_DIR    = /opt/csw/share/man
 DEF_NEWALIAS_PATH  = /opt/csw/bin/newaliases
 DEF_QUEUE_DIR      = /var/opt/csw/spool/postfix
-DEF_README_DIR     = yes
+DEF_DATA_DIR       = /var/opt/csw/lib/postfix
+DEF_README_DIR     = /opt/csw/share/doc/postfix/README_FILES
 
-FLAGS=\
-	-DUSE_TLS \
-	-DUSE_SASL_AUTH \
-	-DHAS_LDAP \
-	-DHAS_PCRE \
-	-DHAS_MYSQL \
-	-DHAS_PGSQL \
-	-DHAS_DB \
-	-DUSE_CYRUS_SASL 
-
 DEFAULTS=\
 	-DDEF_MANPAGE_DIR=\"$(DEF_MANPAGE_DIR)\" \
 	-DDEF_COMMAND_DIR=\"$(DEF_COMMAND_DIR)\" \
@@ -86,46 +89,23 @@
 	-DDEF_HTML_DIR=\"$(DEF_HTML_DIR)\" \
 	-DDEF_NEWALIAS_PATH=\"$(DEF_NEWALIAS_PATH)\" \
 	-DDEF_QUEUE_DIR=\"$(DEF_QUEUE_DIR)\" \
+	-DDEF_DATA_DIR=\"$(DEF_DATA_DIR)\" \
 	-DDEF_README_DIR=\"$(DEF_README_DIR)\"
 
-INCLUDES=\
-	-I/opt/csw/include \
-	-I/opt/csw/include/openssl \
-	-I/opt/csw/include/sasl \
-	-I/opt/csw/mysql4/include/mysql \
-	-I/opt/csw/postgresql/include \
-	-I/opt/csw/bdb4/include
+CCARGS=$(CFLAGS) $(DEFAULTS)
 
-AUXLIBS=\
-	-R/opt/csw/lib \
-	-R/opt/csw/lib/sasl2 \
-	-R/opt/csw/mysql4/lib/mysql \
-	-R/opt/csw/postgresql/lib \
-	-R/opt/csw/bdb4/lib \
-	-L/opt/csw/lib \
-	-L/opt/csw/lib/sasl2 \
-	-L/opt/csw/mysql4/lib/mysql \
-	-L/opt/csw/postgresql/lib \
-	-L/opt/csw/bdb4/lib \
-	-lssl -lcrypto -lsasl2 -lldap -llber -lpcre -lmysqlclient -lz -lm -lpq -ldb
-
-CCARGS=$(FLAGS) $(DEFAULTS) $(INCLUDES)
-
+# We zero makedef's DEBUG and OPT, the relevant flags are set via GAR & CFLAGS
 configure-custom:
-	echo $(MAKE) -C $(WORKDIR)/$(DISTNAME) makefiles CC=$(CC_HOME)/bin/$(CC) CCARGS=$(CCARGS)
-	$(MAKE) -C $(WORKDIR)/$(DISTNAME) makefiles CC=$(CC_HOME)/bin/$(CC) CCARGS='$(CCARGS)' AUXLIBS='$(AUXLIBS)'
+	echo $(MAKE) -C $(WORKSRC) makefiles CC=$(CC) CCARGS='$(CCARGS)' DEBUG= OPT=
+	$(MAKE) -C $(WORKSRC) makefiles \
+		CC=$(CC) \
+		CCARGS='$(CCARGS)' \
+		DEBUG= \
+		OPT=
 	@$(MAKECOOKIE)
-# CC=compiler OPT=compiler-flags DEBUG=debug-flags
 
-build-custom:
-	$(MAKE) -C $(WORKDIR)/$(DISTNAME)
-	@$(MAKECOOKIE)
-
-# Files that will be copied to .CSW files
-install-custom: TEMPLATE_FILES = access aliases canonical generic header_checks
-install-custom: TEMPLATE_FILES += main.cf master.cf relocated transport virtual
 install-custom:
-	$(MAKE) -C $(WORKDIR)/$(DISTNAME) non-interactive-package install_root=$(DESTDIR) \
+	$(MAKE) -C $(WORKSRC) non-interactive-package install_root=$(DESTDIR) \
 		config_directory=$(DEF_CONFIG_DIR) \
 		daemon_directory=$(DEF_DAEMON_DIR) \
 		command_directory=$(DEF_COMMAND_DIR) \
@@ -133,26 +113,27 @@
 		sendmail_path=$(DEF_COMMAND_DIR)/sendmail \
 		newaliases_path=$(DEF_NEWALIAS_PATH) \
 		mailq_path=$(DEF_MAILQ_PATH) \
-		manpage_directory=/opt/csw/share/man \
+		manpage_directory=$(DEF_MANPAGE_DIR) \
 		setgid_group=postdrop \
 		sample_directory=/opt/csw/share/doc/postfix/samples \
-		readme_directory=/opt/csw/share/doc/postfix/README_FILES \
-		html_directory=/opt/csw/share/doc/postfix/html
+		readme_directory=$(DEF_README_DIR) \
+		html_directory=$(DEF_HTML_DIR)
+
+	# XXX: Needs to be checked/revised for current version
 	sed -f $(FILEDIR)/fix_main.cf.sed $(DESTDIR)/etc/opt/csw/postfix/main.cf > $(WORKDIR)/main.cf
 	cp $(WORKDIR)/main.cf $(DESTDIR)/etc/opt/csw/postfix/main.cf
-	for file in $(TEMPLATE_FILES); do \
-		cp $(DESTDIR)/etc/opt/csw/postfix/$$file $(DESTDIR)/etc/opt/csw/postfix/$$file.CSW; \
-	done
-	rm \
-		$(DESTDIR)/etc/opt/csw/postfix/LICENSE \
-		$(DESTDIR)/etc/opt/csw/postfix/TLS_LICENSE \
-		$(DESTDIR)/etc/opt/csw/postfix/makedefs.out
-	mkdir -p $(DESTDIR)/opt/csw/share/postfix
-	cp $(FILEDIR)/upgrade $(DESTDIR)/opt/csw/share/postfix/upgrade
 
+	# mv configuration files to .CSW
+	$(foreach F,$(prefix $(DESTDIR),$(SAMPLECONF)), mv $(F) $(F).CSW;)
+
+	# Script to handle the sysconfdir location change /opt -> /etc
+	# XXX: Needs to be checked and amended with /opt -> /var changes
+	ginstall -D -m 755 $(FILEDIR)/upgrade \
+		$(DESTDIR)/opt/csw/share/postfix/upgrade
+
 	# Files for cswinitsmf and cswusergroup
-	ginstall -m 755 $(FILEDIR)/cswpostfix  \
+	ginstall -Dm 755 $(FILEDIR)/cswpostfix  \
 		$(DESTDIR)/etc/opt/csw/init.d/cswpostfix
-	cp $(FILEDIR)/CSWpostfix.cswusergroup \
+	ginstall -D $(FILEDIR)/CSWpostfix.cswusergroup \
 		$(DESTDIR)$(sysconfdir)/pkg/CSWpostfix/cswusergroup
 	@$(MAKECOOKIE)

Modified: csw/mgar/pkg/postfix/branches/postfix-2.6/checksums
===================================================================
--- csw/mgar/pkg/postfix/branches/postfix-2.6/checksums	2009-07-02 20:18:38 UTC (rev 5490)
+++ csw/mgar/pkg/postfix/branches/postfix-2.6/checksums	2009-07-02 23:38:35 UTC (rev 5491)
@@ -1,10 +1,4 @@
-bf7cf64513bb701347665b0440019884  download/postfix-2.4.7.tar.gz
-4aa7056be9b135a68a4bda6199c0cb8c  download/CSWpostfix.gspec
-ae35f0ad52a10ab36f185b2486e63935  download/CSWpostfix.prototype
-b9a2cb932f32be618c28910613d332a8  download/CSWpostfix.csw_conf_config
-e52799d35088c030851576b62df6695f  download/CSWpostfix.csw_usrgrp_config
+63ac43075e092255cb266e5270ce5364  download/CSWpostfix.cswusergroup
 76e992eb49e5d2d8c51305be8891566f  download/CSWpostfix.postinstall
 980c70abf5ea711adec41f3dd4e37141  download/CSWpostfix.postremove
-99db84b11f968a416809e18c0768ac7e  download/cswpostfix.xml
-abda7e4968f750f0fced9c98abd053c8  download/svc-cswpostfix
-7bd7e87829c623a9cdd2653a16eb473e  download/cswpostfix
+1f0edbd521d2b0473626f4d61e8bb4eb  download/postfix-2.6.2.tar.gz

Added: csw/mgar/pkg/postfix/branches/postfix-2.6/files/CSWpostfix.cswusergroup
===================================================================
--- csw/mgar/pkg/postfix/branches/postfix-2.6/files/CSWpostfix.cswusergroup	                        (rev 0)
+++ csw/mgar/pkg/postfix/branches/postfix-2.6/files/CSWpostfix.cswusergroup	2009-07-02 23:38:35 UTC (rev 5491)
@@ -0,0 +1,2 @@
+:postdrop:::::
+postfix:postfix:Postfix Daemon:/var/opt/csw/spool/postfix:/usr/bin/pfsh::


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