[csw-devel] SF.net SVN: gar:[10073] csw/mgar/pkg/snmptt/trunk/Makefile

skayser at users.sourceforge.net skayser at users.sourceforge.net
Wed Jun 2 18:07:47 CEST 2010


Revision: 10073
          http://gar.svn.sourceforge.net/gar/?rev=10073&view=rev
Author:   skayser
Date:     2010-06-02 16:07:46 +0000 (Wed, 02 Jun 2010)

Log Message:
-----------
snmptt: path and config file fixes

Modified Paths:
--------------
    csw/mgar/pkg/snmptt/trunk/Makefile

Modified: csw/mgar/pkg/snmptt/trunk/Makefile
===================================================================
--- csw/mgar/pkg/snmptt/trunk/Makefile	2010-06-02 15:41:10 UTC (rev 10072)
+++ csw/mgar/pkg/snmptt/trunk/Makefile	2010-06-02 16:07:46 UTC (rev 10073)
@@ -22,11 +22,14 @@
 TEST_SCRIPTS =
 INSTALL_SCRIPTS = custom
 
-SAMPLECONF = /etc/opt/csw/snmptt.ini
+SAMPLECONF = /etc/opt/csw/snmptt.ini /etc/opt/csw/snmptt.conf
 
 CHECKPKG_OVERRIDES_CSWsnmptt += surplus-dependency|CSWperl
 CHECKPKG_OVERRIDES_CSWsnmptt += surplus-dependency|CSWpmcfginifls
 
+sysconfdir=/etc/opt/csw
+localstatedir=/var/opt/csw
+
 include gar/category.mk
 
 install-custom: BIN=snmpttconvertmib
@@ -36,9 +39,9 @@
 install-custom:
 	ginstall -d $(DESTDIR)$(bindir) 
 	ginstall -d $(DESTDIR)$(sbindir) 
-	ginstall -d $(DESTDIR)/etc/opt/csw/
-	ginstall -d $(DESTDIR)/var/opt/csw/log/snmptt
-	ginstall -d $(DESTDIR)/var/opt/csw/spool/snmptt/
+	ginstall -d $(DESTDIR)$(sysconfdir)/snmp
+	ginstall -d $(DESTDIR)$(localstatedir)/log/snmptt
+	ginstall -d $(DESTDIR)$(localstatedir)/spool/snmptt/
 	ginstall -d $(DOCDEST) $(DOCDEST)/examples
 
 	ginstall -m 755 $(addprefix $(WORKSRC)/, $(BIN)) $(DESTDIR)$(bindir)
@@ -46,11 +49,14 @@
 	gsed -i 's,/usr/bin/perl,/opt/csw/bin/perl,' $(DESTDIR)$(bindir)/*
 	gsed -i 's,/usr/bin/perl,/opt/csw/bin/perl,' $(DESTDIR)$(sbindir)/*
 
-	cp $(WORKSRC)/snmptt.ini $(DESTDIR)/etc/opt/csw/snmptt.ini
-	gsed \
+	cp $(WORKSRC)/snmptt.ini $(DESTDIR)$(sysconfdir)/snmp/snmptt.ini
+	gsed -i \
+		-e 's,/etc/snmp/,/etc/opt/csw/snmp/,' \
 		-e 's,/var/,/var/opt/csw/,' \
 		-e 's,/var/opt/csw/run/snmptt.pid,/var/run/cswsnmptt.pid,' \
-		$(DESTDIR)/etc/opt/csw/snmptt.ini
+		$(DESTDIR)$(sysconfdir)/snmp/snmptt.ini
+	cp $(WORKSRC)/examples/snmptt.conf.generic \
+		$(DESTDIR)$(sysconfdir)/snmp/snmptt.conf
 
 	cp $(WORKSRC)/examples/* $(WORKSRC)/sample-* $(DOCDEST)/examples
 	cp $(WORKSRC)/docs/* $(DOCDEST)


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