View | Details | Raw Unified | Return to bug 195968 | Differences between
and this patch

Collapse All | Expand All

(-)netdot/Makefile (-1 / +2 lines)
Lines 2-8 Link Here
2
# $FreeBSD: head/net-mgmt/netdot/Makefile 361083 2014-07-07 13:28:39Z wg $
2
# $FreeBSD: head/net-mgmt/netdot/Makefile 361083 2014-07-07 13:28:39Z wg $
3
3
4
PORTNAME=	netdot
4
PORTNAME=	netdot
5
PORTVERSION=	1.0.6
5
PORTVERSION=	1.0.7
6
CATEGORIES=	net-mgmt
6
CATEGORIES=	net-mgmt
7
MASTER_SITES=	http://netdot.uoregon.edu/pub/dists/
7
MASTER_SITES=	http://netdot.uoregon.edu/pub/dists/
8
8
Lines 12-17 Link Here
12
LICENSE=	GPLv2
12
LICENSE=	GPLv2
13
13
14
RUN_DEPENDS=	p5-libapreq2>=0:${PORTSDIR}/www/p5-libapreq2 \
14
RUN_DEPENDS=	p5-libapreq2>=0:${PORTSDIR}/www/p5-libapreq2 \
15
		mp2bug:${PORTSDIR}/www/mod_perl2 \
15
		p5-Apache-Session>=1.6:${PORTSDIR}/www/p5-Apache-Session \
16
		p5-Apache-Session>=1.6:${PORTSDIR}/www/p5-Apache-Session \
16
		p5-Apache-AuthCookie>=0:${PORTSDIR}/www/p5-Apache-AuthCookie \
17
		p5-Apache-AuthCookie>=0:${PORTSDIR}/www/p5-Apache-AuthCookie \
17
		p5-Apache2-SiteControl>=1.0:${PORTSDIR}/www/p5-Apache2-SiteControl \
18
		p5-Apache2-SiteControl>=1.0:${PORTSDIR}/www/p5-Apache2-SiteControl \
(-)netdot/distinfo (-2 / +2 lines)
Lines 1-2 Link Here
1
SHA256 (netdot-1.0.6.tar.gz) = 0b1d98f8bf2a92901a290cf6689880fe9e98790bb54d95e7747d67b92783501e
1
SHA256 (netdot-1.0.7.tar.gz) = f8fe9804973d09f953dd520795312d5ef2b595151fadd595a1fec2758d99d79c
2
SIZE (netdot-1.0.6.tar.gz) = 2208181
2
SIZE (netdot-1.0.7.tar.gz) = 2216634
(-)netdot/files/patch-stagedir (-150 / +3 lines)
Lines 1-158 Link Here
1
diff -bur Makefile.orig Makefile
1
--- htdocs/Makefile.orig	2014-12-14 15:02:04.000000000 +0000
2
--- Makefile.orig	2013-12-19 15:09:48.000000000 +0000
2
+++ htdocs/Makefile	2014-12-14 15:02:12.000000000 +0000
3
+++ Makefile	2014-06-29 16:27:32.000000000 +0100
4
@@ -7,7 +7,8 @@
5
 # Netdot Makefile
6
 #
7
 PERL        ?= /usr/bin/perl
8
-PREFIX      ?= /usr/local/netdot
9
+PREFIX      ?= /usr/local/www/netdot
10
+STAGEDIR    ?= $(PREFIX)
11
 APACHEUSER  ?= apache
12
 APACHEGROUP ?= apache
13
 MAKE        ?= make
14
@@ -23,6 +24,7 @@
15
 	@echo 
16
 	@echo "   PERL          = $(PERL)"
17
 	@echo "   PREFIX        = $(PREFIX)"
18
+	@echo "   STAGEDIR      = $(STAGEDIR)"
19
 	@echo "   APACHEUSER    = $(APACHEUSER)"
20
 	@echo "   APACHEGROUP   = $(APACHEGROUP)"
21
 	@echo "   MAKE          = $(MAKE)"
22
@@ -88,14 +90,14 @@
23
 	@echo "Creating necessary directories..."
24
 	echo $(PREFIX) > ./.prefix
25
 	for dir in $(DIR); do \
26
-	    if test -d $(PREFIX)/$$dir; then \
27
-	       echo "Skipping dir $(PREFIX)/$$dir; already exists"; \
28
+	    if test -d $(STAGEDIR)/$$dir; then \
29
+	       echo "Skipping dir $(STAGEDIR)/$$dir; already exists"; \
30
 	    else \
31
-	       mkdir -m $(DMOD) -p $(PREFIX)/$$dir ; \
32
+	       mkdir -m $(DMOD) -p $(STAGEDIR)/$$dir ; \
33
 	    fi ; \
34
 	done
35
-	chown -R $(APACHEUSER):$(APACHEGROUP) $(PREFIX)/tmp
36
-	chmod 750 $(PREFIX)/tmp
37
+	chown -R $(APACHEUSER):$(APACHEGROUP) $(STAGEDIR)/tmp
38
+	chmod 750 $(STAGEDIR)/tmp
39
 
40
 htdocs:
41
 	cd $@ ; $(MAKE) all DIR=$@ 
42
diff -bur doc/Makefile.orig doc/Makefile
43
--- doc/Makefile.orig	2011-09-23 16:00:36.000000000 +0100
44
+++ doc/Makefile	2014-06-29 16:32:27.000000000 +0100
45
@@ -11,8 +11,8 @@
46
 	$(substitute)
47
 
48
 	for dir in $(NDIR); do \
49
-	  chown $(APACHEUSER):$(APACHEGROUP) $(PREFIX)/$(DIR)/$$dir; \
50
-	  chmod 0755 $(PREFIX)/$(DIR)/$$dir; \
51
+	  chown $(APACHEUSER):$(APACHEGROUP) $(STAGEDIR)/$(DIR)/$$dir; \
52
+	  chmod 0755 $(STAGEDIR)/$(DIR)/$$dir; \
53
 	done
54
 
55
 # This section creates the doc/ subdirs
56
diff -bur etc/utility-Makefile.orig etc/utility-Makefile
57
--- etc/utility-Makefile.orig	2012-07-13 19:17:17.000000000 +0100
58
+++ etc/utility-Makefile	2014-06-29 16:37:23.000000000 +0100
59
@@ -17,6 +17,7 @@
60
 
61
 # Defaults
62
 REPLACE_PREFIX = $(PREFIX)
63
+REPLACE_STAGEDIR=$(STAGEDIR)
64
 REPLACE_LIB    = $(REPLACE_PREFIX)/lib
65
 REPLACE_ETC    = $(REPLACE_PREFIX)/etc
66
 REPLACE_PERL   = $(PERL)
67
@@ -41,7 +42,7 @@
68
 for file in $(FILES); do\
69
   $(SED) -r $(REPLACEMENT_EXPRESSIONS) $$file\
70
     > $$file.tmp;\
71
-  install -m $(FMOD) $$file.tmp $(PREFIX)/$(DIR)/$$file;\
72
+  install -m $(FMOD) $$file.tmp $(STAGEDIR)/$(DIR)/$$file;\
73
   rm -rf $$file.tmp;\
74
 done
75
 @echo "Done."
76
@@ -51,10 +52,10 @@
77
 define mkdirs
78
 @echo "Creating necessary directories..."
79
 for dir in $(NDIR); do \
80
-    if test -d $(PREFIX)/$(DIR)/$$dir; then \
81
-       echo "Skipping dir $(PREFIX)/$(DIR)/$$dir; already exists"; \
82
+    if test -d $(STAGEDIR)/$(DIR)/$$dir; then \
83
+       echo "Skipping dir $(STAGEDIR)/$(DIR)/$$dir; already exists"; \
84
     else \
85
-       mkdir -m $(DMOD) -p $(PREFIX)/$(DIR)/$$dir ; \
86
+       mkdir -m $(DMOD) -p $(STAGEDIR)/$(DIR)/$$dir ; \
87
     fi ; \
88
 done
89
 @echo "Done."
90
@@ -64,6 +65,6 @@
91
 # left hanging around
92
 define wipedir
93
 @echo "Wiping out directory before installing"
94
-rm -fr $(PREFIX)/$(DIR)
95
+rm -fr $(STAGEDIR)/$(DIR)
96
 @echo "done"
97
 endef
98
diff -bur export/Makefile.orig export/Makefile
99
--- export/Makefile.orig	2012-07-13 19:17:17.000000000 +0100
100
+++ export/Makefile	2014-06-29 16:32:47.000000000 +0100
101
@@ -11,8 +11,8 @@
102
 	$(substitute)
103
 
104
 	for dir in $(NDIR); do \
105
-	  chown $(APACHEUSER):$(APACHEGROUP) $(PREFIX)/$(DIR)/$$dir; \
106
-	  chmod 0755 $(PREFIX)/$(DIR)/$$dir; \
107
+	  chown $(APACHEUSER):$(APACHEGROUP) $(STAGEDIR)/$(DIR)/$$dir; \
108
+	  chmod 0755 $(STAGEDIR)/$(DIR)/$$dir; \
109
 	done
110
 
111
 # This section creates the export/ subdirs
112
diff -bur htdocs/Makefile.orig htdocs/Makefile
113
--- htdocs/Makefile.orig	2012-07-13 19:17:17.000000000 +0100
114
+++ htdocs/Makefile	2014-06-29 16:33:00.000000000 +0100
115
@@ -9,7 +9,7 @@
3
@@ -9,7 +9,7 @@
116
 
4
 
117
 all: wipedir dir
5
 all: wipedir dir
118
 	$(substitute)
6
 	$(substitute)
119
-	ln -s $(PREFIX)/doc/manual/netdot-manual.htm  $(PREFIX)/$(DIR)/help/manual.html
7
-	ln -s $(STAGEDIR)/doc/manual/netdot-manual.htm  $(STAGEDIR)/$(DIR)/help/manual.html
120
+	ln -s $(PREFIX)/doc/manual/netdot-manual.htm  $(STAGEDIR)/$(DIR)/help/manual.html
8
+	ln -s $(PREFIX)/doc/manual/netdot-manual.htm  $(STAGEDIR)/$(DIR)/help/manual.html
121
 
9
 
122
 # Wipe out dir before installing
10
 # Wipe out dir before installing
123
 wipedir:
11
 wipedir:
124
@@ -20,10 +20,10 @@
125
 	$(mkdirs)
126
 
127
 	@echo "Hacking together mason permissions fix..."
128
-	touch $(PREFIX)/$(DIR)/masondata/obj/.__obj_create_marker
129
-	chown -R $(APACHEUSER):$(APACHEGROUP) $(PREFIX)/$(DIR)/masondata
130
-	chmod 0755 $(PREFIX)/$(DIR)/masondata
131
+	touch $(STAGEDIR)/$(DIR)/masondata/obj/.__obj_create_marker
132
+	chown -R $(APACHEUSER):$(APACHEGROUP) $(STAGEDIR)/$(DIR)/masondata
133
+	chmod 0755 $(STAGEDIR)/$(DIR)/masondata
134
 # Graphs can be updated dynamically so apache needs +w
135
-	chown $(APACHEUSER):$(APACHEGROUP) $(PREFIX)/$(DIR)/img/graphs
136
-	chmod 0750 $(PREFIX)/$(DIR)/img/graphs
137
+	chown $(APACHEUSER):$(APACHEGROUP) $(STAGEDIR)/$(DIR)/img/graphs
138
+	chmod 0750 $(STAGEDIR)/$(DIR)/img/graphs
139
 
140
diff -bur var/Makefile.orig var/Makefile
141
--- var/Makefile.orig	2011-09-23 16:00:38.000000000 +0100
142
+++ var/Makefile	2014-06-29 16:34:01.000000000 +0100
143
@@ -13,7 +13,7 @@
144
 POLLSTATSRRD = pollstats.rrd
145
 
146
 all: 
147
-	if ! test -r $(PREFIX)/$(DIR)/$(POLLSTATSRRD); then \
148
+	if ! test -r $(STAGEDIR)/$(DIR)/$(POLLSTATSRRD); then \
149
 	  rrdtool create $(POLLSTATSRRD) -s 3600 \
150
 	  DS:ips:GAUGE:7200:0:4294967296 \
151
 	  DS:macs:GAUGE:7200:0:4294967296 \
152
@@ -24,5 +24,5 @@
153
 	  RRA:AVERAGE:0.5:24:365 \
154
 	  RRA:MAX:0.5:24:30 \
155
 	  RRA:MIN:0.5:24:30; \
156
-	  install -m $(FMOD) $(POLLSTATSRRD) $(PREFIX)/$(DIR)/$(POLLSTATSRRD); \
157
+	  install -m $(FMOD) $(POLLSTATSRRD) $(STAGEDIR)/$(DIR)/$(POLLSTATSRRD); \
158
 	fi;
(-)netdot/files/pkg-message.in (+6 lines)
Lines 28-32 Link Here
28
%%WWWDIR%%/etc/netdot_apache2_local.conf
28
%%WWWDIR%%/etc/netdot_apache2_local.conf
29
%%WWWDIR%%/etc/netdot_apache2_ldap.conf
29
%%WWWDIR%%/etc/netdot_apache2_ldap.conf
30
30
31
6. Running Apache 2.4?  Make sure that both the mod_perl and mod_apreq2 have
32
been added to httpd.conf:
33
34
LoadModule perl_module		libexec/apache24/mod_perl.so
35
LoadModule apreq_module		libexec/apache24/mod_apreq2.so
36
31
Note that any changes to Site.conf require an apache reload.
37
Note that any changes to Site.conf require an apache reload.
32
###############################################################################
38
###############################################################################
(-)netdot/pkg-plist (-52 / +54 lines)
Lines 28-33 Link Here
28
%%WWWDIR%%/etc/default_data
28
%%WWWDIR%%/etc/default_data
29
%%WWWDIR%%/etc/netdot.cron
29
%%WWWDIR%%/etc/netdot.cron
30
%%WWWDIR%%/etc/netdot.meta
30
%%WWWDIR%%/etc/netdot.meta
31
%%WWWDIR%%/etc/netdot_apache24_local.conf
31
%%WWWDIR%%/etc/netdot_apache2_ldap.conf
32
%%WWWDIR%%/etc/netdot_apache2_ldap.conf
32
%%WWWDIR%%/etc/netdot_apache2_local.conf
33
%%WWWDIR%%/etc/netdot_apache2_local.conf
33
%%WWWDIR%%/etc/netdot_apache2_radius.conf
34
%%WWWDIR%%/etc/netdot_apache2_radius.conf
Lines 202-207 Link Here
202
%%WWWDIR%%/htdocs/rest/host
203
%%WWWDIR%%/htdocs/rest/host
203
%%WWWDIR%%/htdocs/rest/host_contacts
204
%%WWWDIR%%/htdocs/rest/host_contacts
204
%%WWWDIR%%/htdocs/rest/index.html
205
%%WWWDIR%%/htdocs/rest/index.html
206
%%WWWDIR%%/htdocs/rest/updatedev
205
%%WWWDIR%%/htdocs/user_help/autohandler
207
%%WWWDIR%%/htdocs/user_help/autohandler
206
%%WWWDIR%%/htdocs/user_help/dhandler
208
%%WWWDIR%%/htdocs/user_help/dhandler
207
%%WWWDIR%%/htdocs/user_help/hosts.html
209
%%WWWDIR%%/htdocs/user_help/hosts.html
Lines 319-376 Link Here
319
%%WWWDIR%%/upgrade/updatedb
321
%%WWWDIR%%/upgrade/updatedb
320
%%WWWDIR%%/upgrade/upgrade-tasks
322
%%WWWDIR%%/upgrade/upgrade-tasks
321
%%WWWDIR%%/var/pollstats.rrd
323
%%WWWDIR%%/var/pollstats.rrd
322
@dirrmtry %%WWWDIR%%/bin
324
@dir %%WWWDIR%%/bin
323
@dirrmtry %%WWWDIR%%/doc/manual
325
@dir %%WWWDIR%%/doc/manual
324
@dirrmtry %%WWWDIR%%/doc
326
@dir %%WWWDIR%%/doc
325
@dirrmtry %%WWWDIR%%/htdocs/cable_plant
327
@dir %%WWWDIR%%/htdocs/cable_plant
326
@dirrmtry %%WWWDIR%%/htdocs/css
328
@dir %%WWWDIR%%/htdocs/css
327
@dirrmtry %%WWWDIR%%/htdocs/generic
329
@dir %%WWWDIR%%/htdocs/generic
328
@dirrmtry %%WWWDIR%%/htdocs/help
330
@dir %%WWWDIR%%/htdocs/help
329
@dirrmtry %%WWWDIR%%/htdocs/img/graphs
331
@dir %%WWWDIR%%/htdocs/img/graphs
330
@dirrmtry %%WWWDIR%%/htdocs/img
332
@dir %%WWWDIR%%/htdocs/img
331
@dirrmtry %%WWWDIR%%/htdocs/java_script
333
@dir %%WWWDIR%%/htdocs/java_script
332
@dirrmtry %%WWWDIR%%/htdocs/management
334
@dir %%WWWDIR%%/htdocs/management
333
@dirrmtry %%WWWDIR%%/htdocs/contacts
335
@dir %%WWWDIR%%/htdocs/contacts
334
@dirrmtry %%WWWDIR%%/htdocs/operations
336
@dir %%WWWDIR%%/htdocs/operations
335
@dirrmtry %%WWWDIR%%/htdocs/reports
337
@dir %%WWWDIR%%/htdocs/reports
336
@dirrmtry %%WWWDIR%%/htdocs/export
338
@dir %%WWWDIR%%/htdocs/export
337
@dirrmtry %%WWWDIR%%/htdocs/user_management
339
@dir %%WWWDIR%%/htdocs/user_management
338
@dirrmtry %%WWWDIR%%/htdocs/user_help
340
@dir %%WWWDIR%%/htdocs/user_help
339
@dirrmtry %%WWWDIR%%/htdocs/rest
341
@dir %%WWWDIR%%/htdocs/rest
340
@dirrmtry %%WWWDIR%%/lib/Netdot/Manual
342
@dir %%WWWDIR%%/lib/Netdot/Manual
341
@dirrmtry %%WWWDIR%%/lib/Netdot/Meta/Table
343
@dir %%WWWDIR%%/lib/Netdot/Meta/Table
342
@dirrmtry %%WWWDIR%%/lib/Netdot/Meta
344
@dir %%WWWDIR%%/lib/Netdot/Meta
343
@dirrmtry %%WWWDIR%%/lib/Netdot/Model/Plugins
345
@dir %%WWWDIR%%/lib/Netdot/Model/Plugins
344
@dirrmtry %%WWWDIR%%/lib/Netdot/Model/Device/CLI
346
@dir %%WWWDIR%%/lib/Netdot/Model/Device/CLI
345
@dirrmtry %%WWWDIR%%/lib/Netdot/Model/Device
347
@dir %%WWWDIR%%/lib/Netdot/Model/Device
346
@dirrmtry %%WWWDIR%%/lib/Netdot/Model
348
@dir %%WWWDIR%%/lib/Netdot/Model
347
@dirrmtry %%WWWDIR%%/lib/Netdot/UI
349
@dir %%WWWDIR%%/lib/Netdot/UI
348
@dirrmtry %%WWWDIR%%/lib/Netdot/Util
350
@dir %%WWWDIR%%/lib/Netdot/Util
349
@dirrmtry %%WWWDIR%%/lib/Netdot/Exporter
351
@dir %%WWWDIR%%/lib/Netdot/Exporter
350
@dirrmtry %%WWWDIR%%/lib/Netdot
352
@dir %%WWWDIR%%/lib/Netdot
351
@dirrmtry %%WWWDIR%%/lib
353
@dir %%WWWDIR%%/lib
352
@dirrmtry %%WWWDIR%%/etc
354
@dir %%WWWDIR%%/etc
353
@dirrmtry %%WWWDIR%%/import
355
@dir %%WWWDIR%%/import
354
@dirrmtry %%WWWDIR%%/export/docs
356
@dir %%WWWDIR%%/export/docs
355
@dirrmtry %%WWWDIR%%/export/nagios
357
@dir %%WWWDIR%%/export/nagios
356
@dirrmtry %%WWWDIR%%/export/sysmon
358
@dir %%WWWDIR%%/export/sysmon
357
@dirrmtry %%WWWDIR%%/export/rancid
359
@dir %%WWWDIR%%/export/rancid
358
@dirrmtry %%WWWDIR%%/export/cacti
360
@dir %%WWWDIR%%/export/cacti
359
@dirrmtry %%WWWDIR%%/export/ethers
361
@dir %%WWWDIR%%/export/ethers
360
@dirrmtry %%WWWDIR%%/export/bind
362
@dir %%WWWDIR%%/export/bind
361
@dirrmtry %%WWWDIR%%/export/dhcpd
363
@dir %%WWWDIR%%/export/dhcpd
362
@dirrmtry %%WWWDIR%%/export/smokeping
364
@dir %%WWWDIR%%/export/smokeping
363
@dirrmtry %%WWWDIR%%/export
365
@dir %%WWWDIR%%/export
364
@dirrmtry %%WWWDIR%%/htdocs/masondata/obj
366
@dir %%WWWDIR%%/htdocs/masondata/obj
365
@unexec rm -rf %D/%%WWWDIR%%/htdocs/masondata/obj 2> /dev/null || true
367
@unexec rm -rf %D/%%WWWDIR%%/htdocs/masondata/obj 2> /dev/null || true
366
@dirrmtry %%WWWDIR%%/htdocs/masondata/cache
368
@dir %%WWWDIR%%/htdocs/masondata/cache
367
@dirrmtry %%WWWDIR%%/htdocs/masondata
369
@dir %%WWWDIR%%/htdocs/masondata
368
@dirrmtry %%WWWDIR%%/htdocs
370
@dir %%WWWDIR%%/htdocs
369
@dirrmtry %%WWWDIR%%/tmp/sessions/locks
371
@dir %%WWWDIR%%/tmp/sessions/locks
370
@dirrmtry %%WWWDIR%%/tmp/sessions
372
@dir %%WWWDIR%%/tmp/sessions
371
@unexec rm -rf %D/%%WWWDIR%%/tmp/sessions 2> /dev/null || true
373
@unexec rm -rf %D/%%WWWDIR%%/tmp/sessions 2> /dev/null || true
372
@dirrmtry %%WWWDIR%%/tmp
374
@dir %%WWWDIR%%/tmp
373
@dirrmtry %%WWWDIR%%/upgrade
375
@dir %%WWWDIR%%/upgrade
374
@dirrmtry %%WWWDIR%%/var
376
@dir %%WWWDIR%%/var
375
@dirrmtry %%WWWDIR%%
377
@dir %%WWWDIR%%
376
@unexec if [ -d %%WWWDIR%% ]; then echo "===>  There are files/directories remaining under %D/%%WWWDIR%%. If you wish to deinstall netdot completely, inspect this directory for any files you may want to keep and then remove it."; fi
378
@unexec if [ -d %%WWWDIR%% ]; then echo "===>  There are files/directories remaining under %D/%%WWWDIR%%. If you wish to deinstall netdot completely, inspect this directory for any files you may want to keep and then remove it."; fi

Return to bug 195968