[22627] trunk/dports/net/zabbix/Portfile

source_changes at macosforge.org source_changes at macosforge.org
Wed Mar 7 22:20:55 PST 2007


Revision: 22627
          http://trac.macosforge.org/projects/macports/changeset/22627
Author:   markd at macports.org
Date:     2007-03-07 22:20:54 -0800 (Wed, 07 Mar 2007)

Log Message:
-----------
Add a dummy server variant.

Modified Paths:
--------------
    trunk/dports/net/zabbix/Portfile

Modified: trunk/dports/net/zabbix/Portfile
===================================================================
--- trunk/dports/net/zabbix/Portfile	2007-03-08 06:19:58 UTC (rev 22626)
+++ trunk/dports/net/zabbix/Portfile	2007-03-08 06:20:54 UTC (rev 22627)
@@ -15,6 +15,7 @@
 homepage		http://www.zabbix.com
 master_sites		sourceforge
 checksums		md5 baa6896c5f41ed286bca3c40e419e1cf
+default_variants	+server
 
 patchfiles		patch-configure
 
@@ -45,44 +46,23 @@
 	startupitem.stop        "${prefix}/share/zabbix/zabbix_server.init stop"
 }
 
+variant server  {
+# This variant doesn't do anything in this port.  Its only purpose is to trigger the server
+# variant in the mysql5 port.
+}
+
 variant agent_only {
-	depends_lib-delete		port:mysql5 \
-							port:fping
+	depends_lib-delete	port:mysql5 \
+				port:fping
 
 	configure.args-delete	--enable-server \
-							--with-mysql=${prefix} \
-							--with-net-snmp
-							
+				--with-mysql=${prefix} \
+				--with-net-snmp					
 }
 
 build {}
-        
-pre-fetch {
-if { [variant_isset agent_only] } {
-# If agent_only don'y display MySQL ui_msg
-} else {
 
-        ui_msg "\n
-
-                   ************************************************
-	           **** It is highly recommended you           ****
-	           **** pre-install MySQL with the +server     ****
-		   **** variant so MySQL will run at system    ****
-		   **** boot.  So for new MySQL installs:      ****
-
-	              1) Cancel this install now with Cntrl-C.
-	              2) Type \"port install mysql5 +server\"
-	              3) Re-install ZABBIX
-	           ************************************************
-
-		\n"
-}
-}
-
 post-extract {
-        reinplace "s|PACKETSZ|NS_PACKETSZ|g" \
-                ${worksrcpath}/src/libs/zbxsysinfo/common/common.c
-
         reinplace "s|#DBSocket=/tmp/mysql.sock|DBSocket=${prefix}/var/run/mysql5/mysqld.sock|g" \
                 ${worksrcpath}/misc/conf/zabbix_server.conf
                 
@@ -107,14 +87,12 @@
         xinstall -m 755  ${worksrcpath}/misc/conf/zabbix_agentd.conf \
                 ${destroot}${prefix}/etc/zabbix/zabbix_agentd.conf.sample
 
-
 # Copy a startup script for the agent
 		xinstall -d -m 755 -d ${destroot}${prefix}/share/zabbix
 		xinstall -m 755 ${portpath}/${filesdir}/zabbix_agentd.init \
 			${destroot}${prefix}/share/zabbix
 		reinplace "s|__PREFIX__|${prefix}|g" \
-                ${destroot}${prefix}/share/zabbix/zabbix_agentd.init
-                
+                ${destroot}${prefix}/share/zabbix/zabbix_agentd.init                
 } else {
 
 # Copy sample server and agent .conf files

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.macosforge.org/pipermail/macports-changes/attachments/20070307/59a04e6d/attachment.html


More information about the macports-changes mailing list