View | Details | Raw Unified | Return to bug 192123
Collapse All | Expand All

(-)multimedia/zoneminder/Makefile (-34 / +54 lines)
Lines 3-9 Link Here
3
3
4
PORTNAME=	zoneminder
4
PORTNAME=	zoneminder
5
PORTVERSION=	1.25.0
5
PORTVERSION=	1.25.0
6
PORTREVISION=	3
6
PORTREVISION=	4
7
CATEGORIES=	multimedia
7
CATEGORIES=	multimedia
8
MASTER_SITES=	http://www2.zoneminder.com/downloads/ \
8
MASTER_SITES=	http://www2.zoneminder.com/downloads/ \
9
		http://www.zoneminder.com/downloads/
9
		http://www.zoneminder.com/downloads/
Lines 30-40 Link Here
30
		p5-MIME-Tools>=0:${PORTSDIR}/mail/p5-MIME-Tools \
30
		p5-MIME-Tools>=0:${PORTSDIR}/mail/p5-MIME-Tools \
31
		${LOCALBASE}/include/linux/videodev.h:${PORTSDIR}/multimedia/v4l_compat
31
		${LOCALBASE}/include/linux/videodev.h:${PORTSDIR}/multimedia/v4l_compat
32
32
33
USES=		perl5
33
USES=		perl5 shebangfix
34
GNU_CONFIGURE=	yes
34
GNU_CONFIGURE=	yes
35
USE_PHP=	json mysql session
35
USE_PHP=	json mysql session
36
USE_MYSQL=	yes
36
USE_MYSQL=	yes
37
USE_RC_SUBR=	zoneminder
37
USE_RC_SUBR=	zoneminder
38
USE_GCC=	any
39
USE_PERL5=	run build fixpacklist
38
40
39
CFLAGS+=	-I${LOCALBASE}/include/ffmpeg0 -I${LOCALBASE}/include
41
CFLAGS+=	-I${LOCALBASE}/include/ffmpeg0 -I${LOCALBASE}/include
40
LDFLAGS+=	-L${LOCALBASE}/lib/ffmpeg0
42
LDFLAGS+=	-L${LOCALBASE}/lib/ffmpeg0
Lines 52-64 Link Here
52
		ZM_DB_NAME=${DB_NAME} \
54
		ZM_DB_NAME=${DB_NAME} \
53
		ZM_DB_USER=${DB_USER} \
55
		ZM_DB_USER=${DB_USER} \
54
		ZM_DB_PASS=${DB_PASS} \
56
		ZM_DB_PASS=${DB_PASS} \
55
		ZM_SSL_LIB="openssl"
57
		ZM_SSL_LIB="openssl"  \
58
		ZM_LOGDIR=${M_LOGDIR} \
59
		ZM_RUNDIR=${M_RUNDIR} \
60
		ZM_TMPDIR=${M_TMPDIR}
56
61
57
DB_HOST?=	localhost
62
DB_HOST?=	localhost
58
DB_NAME?=	zm
63
DB_NAME?=	zm
59
DB_USER?=	zmuser
64
DB_USER?=	zmuser
60
DB_PASS?=	zmpass
65
DB_PASS?=	zmpass
61
66
67
#
68
# These variables default to to the defaults specified in the
69
# original distributed ZoneMinder/configure.ac
70
#
71
M_LOGDIR?=	/var/log/zm
72
M_RUNDIR?=	/var/run/zm
73
M_TMPDIR?=	/tmp/zm
74
75
PLIST_SUB=	ZM_LOGDIR=${M_LOGDIR}	\
76
		ZM_RUNDIR=${M_RUNDIR}	\
77
		ZM_TMPDIR=${M_TMPDIR}	\
78
		WEB_USER=${WWWOWN}	\
79
		WEB_GROUP=${WWWGRP}
80
81
SHEBANG_FILES=	scripts/zmdc.pl.in	\
82
		scripts/zmaudit.pl.in	\
83
		scripts/zmfilter.pl.in	\
84
		scripts/zmtrigger.pl.in	\
85
		scripts/zmx10.pl.in	\
86
		scripts/zmwatch.pl.in	\
87
		scripts/zmpkg.pl.in	\
88
		scripts/zmupdate.pl.in	\
89
		scripts/zmvideo.pl.in	\
90
		scripts/zmcontrol.pl.in	\
91
		scripts/zmtrack.pl.in
92
62
PORTDOCS=	AUTHORS \
93
PORTDOCS=	AUTHORS \
63
		COPYING \
94
		COPYING \
64
		ChangeLog \
95
		ChangeLog \
Lines 68-101 Link Here
68
		README.FreeBSD \
99
		README.FreeBSD \
69
		TODO
100
		TODO
70
101
71
MAN3PREFIX?=	${PREFIX}/lib/perl5/${PERL_VER}
72
MAN3=		ZoneMinder::Trigger::Connection.3 \
73
		ZoneMinder::Control::Ncs370.3 \
74
		ZoneMinder::Trigger::Channel::Serial.3 \
75
		ZoneMinder.3 \
76
		ZoneMinder::Config.3 \
77
		ZoneMinder::Control::mjpgStreamer.3 \
78
		ZoneMinder::Control::PanasonicIP.3 \
79
		ZoneMinder::Base.3 \
80
		ZoneMinder::Trigger::Channel::Unix.3 \
81
		ZoneMinder::Control::AxisV2.3 \
82
		ZoneMinder::Trigger::Channel.3 \
83
		ZoneMinder::Memory.3 \
84
		ZoneMinder::Trigger::Channel::File.3 \
85
		ZoneMinder::Database.3 \
86
		ZoneMinder::Control::PelcoD.3 \
87
		ZoneMinder::Control::Visca.3 \
88
		ZoneMinder::Trigger::Channel::Inet.3 \
89
		ZoneMinder::Trigger::Connection::Example.3 \
90
		ZoneMinder::Trigger::Channel::Spawning.3 \
91
		ZoneMinder::Control.3 \
92
		ZoneMinder::General.3 \
93
		ZoneMinder::Trigger::Channel::Handle.3 \
94
		ZoneMinder::ConfigAdmin.3 \
95
		ZoneMinder::ConfigData.3 \
96
		ZoneMinder::Logger.3
97
98
NO_STAGE=	yes
99
.include <bsd.port.pre.mk>
102
.include <bsd.port.pre.mk>
100
103
101
.if ${ARCH}=="i386"
104
.if ${ARCH}=="i386"
Lines 123-141 Link Here
123
		${WRKSRC}/configure
126
		${WRKSRC}/configure
124
	${REINPLACE_CMD} -e 's,ZM_V4L2,ZM_HAS_V4L2,g' ${WRKSRC}//web/skins/classic/views/monitorprobe.php
127
	${REINPLACE_CMD} -e 's,ZM_V4L2,ZM_HAS_V4L2,g' ${WRKSRC}//web/skins/classic/views/monitorprobe.php
125
128
129
PKGMESSAGE=	${WRKDIR}/pkg-message
126
pre-build:
130
pre-build:
127
	${CP} ${FILESDIR}/videodev.h ${WRKSRC}/src
131
	${CP} ${FILESDIR}/videodev.h ${WRKSRC}/src
128
	${CP} ${FILESDIR}/zm_fbsd_camera.cpp ${WRKSRC}/src
132
	${CP} ${FILESDIR}/zm_fbsd_camera.cpp ${WRKSRC}/src
129
	${TOUCH} ${WRKSRC}/src/zm_fbsd_camera.h
133
	${TOUCH} ${WRKSRC}/src/zm_fbsd_camera.h
130
	${CP} ${FILESDIR}/README.FreeBSD ${WRKSRC}
134
	${CP} ${FILESDIR}/README.FreeBSD ${WRKSRC}
135
	${CP} ${FILESDIR}/README.FreeBSD  ${PKGMESSAGE}
136
131
137
132
post-install:
138
post-install:
133
.if !defined(NOPORTDOCS)
139
.if !defined(NOPORTDOCS)
134
	${MKDIR} ${DOCSDIR}
140
	${MKDIR} ${STAGEDIR}${DOCSDIR}
141
	${CP} ${WRKSRC}/db/zm_create.sql ${STAGEDIR}${DOCSDIR}
135
.for i in ${PORTDOCS}
142
.for i in ${PORTDOCS}
136
	${INSTALL_DATA} ${WRKSRC}/$i ${DOCSDIR}
143
	${INSTALL_DATA} ${WRKSRC}/$i ${STAGEDIR}${DOCSDIR}
137
.endfor
144
.endfor
138
.endif
145
.endif
139
	${CAT} ${FILESDIR}/README.FreeBSD
146
	-${RM} -f ${STAGEDIR}${PREFIX}/lib/perl5/${PERL_VER}/mach/perllocal.pod
147
	${MKDIR} -m 0700 -p ${STAGEDIR}${M_TMPDIR}
148
	${CHOWN} ${WWWOWN}:${WWWGRP} ${STAGEDIR}${M_TMPDIR}
149
	${MKDIR} -m 0755 -p ${STAGEDIR}${M_RUNDIR}
150
	${CHOWN} ${WWWOWN}:${WWWGRP} ${STAGEDIR}${M_RUNDIR}
151
	${MKDIR} -m 0755 -p ${STAGEDIR}${M_LOGDIR}
152
	${CHOWN} ${WWWOWN}:${WWWGRP} ${STAGEDIR}${M_LOGDIR}
153
154
pre-deinstall:
155
	-${RMDIR} ${STAGEDIR}${M_RUNDIR}
156
	-${RMDIR} ${STAGEDIR}${M_TMPDIR}
157
	-${RMDIR} ${STAGEDIR}${M_LOGDIR}
158
140
159
141
.include <bsd.port.post.mk>
160
.include <bsd.port.post.mk>
161
(-)multimedia/zoneminder/files/patch-src_zm_comms.h (-5 / +5 lines)
Lines 1-6 Link Here
1
--- src/zm_comms.h.orig	2009-03-20 15:07:00.000000000 +0300
1
--- src/zm_comms.h.orig	2009-10-14 06:08:49.000000000 -0700
2
+++ src/zm_comms.h	2011-04-08 17:48:07.410804476 +0400
2
+++ src/zm_comms.h	2014-07-23 08:26:15.000000000 -0700
3
@@ -26,10 +26,11 @@
3
@@ -26,9 +26,12 @@
4
 #include <netdb.h>
4
 #include <netdb.h>
5
 #include <errno.h>
5
 #include <errno.h>
6
 #include <sys/un.h>
6
 #include <sys/un.h>
Lines 8-16 Link Here
8
+#include <sys/socket.h>
8
+#include <sys/socket.h>
9
 #include <set>
9
 #include <set>
10
 #include <vector>
10
 #include <vector>
11
-
12
+#include <sys/uio.h>
11
+#include <sys/uio.h>
13
+#include <netinet/in.h>
12
+#include <netinet/in.h>
13
+#include <string.h>
14
 
14
 class CommsException : public Exception
15
 class CommsException : public Exception
15
 {
16
 {
16
 public:
(-)multimedia/zoneminder/files/patch-src_zm_logger.cpp (-4 / +5 lines)
Lines 1-14 Link Here
1
--- src/zm_logger.cpp.orig	2011-06-28 15:07:35.000000000 +0400
1
--- src/zm_logger.cpp.orig	2011-06-28 04:07:35.000000000 -0700
2
+++ src/zm_logger.cpp	2012-02-03 01:42:44.626851425 +0400
2
+++ src/zm_logger.cpp	2014-07-23 00:23:50.000000000 -0700
3
@@ -33,6 +33,7 @@
3
@@ -33,6 +33,8 @@
4
 #include <signal.h>
4
 #include <signal.h>
5
 #include <stdarg.h>
5
 #include <stdarg.h>
6
 #include <errno.h>
6
 #include <errno.h>
7
+#include <sys/thr.h>
7
+#include <sys/thr.h>
8
+#include <unistd.h>
8
 
9
 
9
 bool Logger::smInitialised = false;
10
 bool Logger::smInitialised = false;
10
 Logger *Logger::smInstance = 0;
11
 Logger *Logger::smInstance = 0;
11
@@ -515,8 +516,12 @@
12
@@ -515,8 +517,12 @@
12
     #endif
13
     #endif
13
 
14
 
14
         pid_t tid;
15
         pid_t tid;
(-)multimedia/zoneminder/files/patch-src_zm_remote_camera.h (-3 / +6 lines)
Lines 1-6 Link Here
1
--- src/zm_remote_camera.h.orig	2009-05-28 12:47:59.000000000 +0400
1
--- src/zm_remote_camera.h.orig	2009-06-02 00:59:26.000000000 -0700
2
+++ src/zm_remote_camera.h	2011-04-08 17:48:07.392807144 +0400
2
+++ src/zm_remote_camera.h	2014-07-23 00:39:49.000000000 -0700
3
@@ -21,7 +21,7 @@
3
@@ -21,9 +21,10 @@
4
 #define ZM_REMOTE_CAMERA_H
4
 #define ZM_REMOTE_CAMERA_H
5
 
5
 
6
 #include "zm_camera.h"
6
 #include "zm_camera.h"
Lines 8-11 Link Here
8
+#include <netinet/in.h>
8
+#include <netinet/in.h>
9
 #include <string>
9
 #include <string>
10
 #include <netdb.h>
10
 #include <netdb.h>
11
+#include <unistd.h>
11
 
12
 
13
 //
14
 // Class representing 'remote' cameras, i.e. those which are
(-)multimedia/zoneminder/files/patch-src_zm_thread.h (+10 lines)
Line 0 Link Here
1
--- src/zm_thread.h.orig	2009-06-08 02:20:17.000000000 -0700
2
+++ src/zm_thread.h	2014-07-23 00:50:23.000000000 -0700
3
@@ -21,6 +21,7 @@
4
 #define ZM_THREAD_H
5
 
6
 #include <pthread.h>
7
+#include <unistd.h>
8
 #include "zm_exception.h"
9
 #include "zm_utils.h"
10
 
(-)multimedia/zoneminder/files/patch-Makefile.in (-4 / +52 lines)
Lines 1-6 Link Here
1
--- Makefile.in.orig	2011-04-27 18:25:46.000000000 +0400
1
--- Makefile.in.orig	2011-08-23 08:10:37.000000000 -0700
2
+++ Makefile.in	2011-05-05 17:28:47.671178104 +0400
2
+++ Makefile.in	2014-07-24 13:33:49.000000000 -0700
3
@@ -275,7 +275,7 @@ AUTOMAKE_OPTIONS = gnu
3
@@ -275,7 +275,7 @@
4
 webuser = @WEB_USER@
4
 webuser = @WEB_USER@
5
 webgroup = @WEB_GROUP@
5
 webgroup = @WEB_GROUP@
6
 sysconf_DATA = \
6
 sysconf_DATA = \
Lines 9-15 Link Here
9
 
9
 
10
 SUBDIRS = \
10
 SUBDIRS = \
11
 	src \
11
 	src \
12
@@ -343,7 +343,7 @@ $(srcdir)/config.h.in:  $(am__configure_
12
@@ -343,7 +343,7 @@
13
 
13
 
14
 distclean-hdr:
14
 distclean-hdr:
15
 	-rm -f config.h stamp-h1
15
 	-rm -f config.h stamp-h1
Lines 18-20 Link Here
18
 	cd $(top_builddir) && $(SHELL) ./config.status $@
18
 	cd $(top_builddir) && $(SHELL) ./config.status $@
19
 zmconfgen.pl: $(top_builddir)/config.status $(srcdir)/zmconfgen.pl.in
19
 zmconfgen.pl: $(top_builddir)/config.status $(srcdir)/zmconfgen.pl.in
20
 	cd $(top_builddir) && $(SHELL) ./config.status $@
20
 	cd $(top_builddir) && $(SHELL) ./config.status $@
21
@@ -742,7 +742,6 @@
22
 
23
 install-data-am:
24
 	@$(NORMAL_INSTALL)
25
-	$(MAKE) $(AM_MAKEFLAGS) install-data-hook
26
 install-dvi: install-dvi-recursive
27
 
28
 install-dvi-am:
29
@@ -789,7 +788,6 @@
30
 
31
 uninstall-am: uninstall-sysconfDATA
32
 	@$(NORMAL_INSTALL)
33
-	$(MAKE) $(AM_MAKEFLAGS) uninstall-hook
34
 .MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) all \
35
 	ctags-recursive install-am install-data-am install-strip \
36
 	tags-recursive uninstall-am
37
@@ -801,29 +799,17 @@
38
 	distclean distclean-generic distclean-hdr distclean-tags \
39
 	distcleancheck distdir distuninstallcheck dvi dvi-am html \
40
 	html-am info info-am install install-am install-data \
41
-	install-data-am install-data-hook install-dvi install-dvi-am \
42
+	install-data-am install-dvi install-dvi-am \
43
 	install-exec install-exec-am install-html install-html-am \
44
 	install-info install-info-am install-man install-pdf \
45
 	install-pdf-am install-ps install-ps-am install-strip \
46
 	install-sysconfDATA installcheck installcheck-am installdirs \
47
 	installdirs-am maintainer-clean maintainer-clean-generic \
48
 	mostlyclean mostlyclean-generic pdf pdf-am ps ps-am tags \
49
-	tags-recursive uninstall uninstall-am uninstall-hook \
50
+	tags-recursive uninstall uninstall-am \
51
 	uninstall-sysconfDATA
52
 
53
 
54
-# Yes, you are correct. This is a HACK!
55
-install-data-hook:
56
-	( cd $(DESTDIR)$(sysconfdir); chown $(webuser):$(webgroup) $(sysconf_DATA); chmod 600 $(sysconf_DATA) )
57
-	( if ! test -e $(ZM_RUNDIR); then mkdir -p $(ZM_RUNDIR); fi; if test "$(ZM_RUNDIR)" != "/var/run"; then chown $(webuser):$(webgroup) $(ZM_RUNDIR); chmod u+w $(ZM_RUNDIR); fi )
58
-	( if ! test -e $(ZM_TMPDIR); then mkdir -m 700 -p $(ZM_TMPDIR); fi; if test "$(ZM_TMPDIR)" != "/tmp"; then chown $(webuser):$(webgroup) $(ZM_TMPDIR); chmod u+w $(ZM_TMPDIR); fi )
59
-	( if ! test -e $(ZM_LOGDIR); then mkdir -p $(ZM_LOGDIR); fi; if test "$(ZM_LOGDIR)" != "/var/log"; then chown $(webuser):$(webgroup) $(ZM_LOGDIR); chmod u+w $(ZM_LOGDIR); fi )
60
-
61
-uninstall-hook:
62
-	@-( cd $(DESTDIR)$(webdir); rm -rf events graphics images sounds temp )
63
-	@-( if test "$(ZM_RUNDIR)" != "/var/run"; then rm -rf $(ZM_RUNDIR); fi )
64
-	@-( if test "$(ZM_TMPDIR)" != "/tmp"; then rm -rf $(ZM_TMPDIR); fi )
65
-	@-( if test "$(ZM_LOGDIR)" != "/var/log"; then rm -rf $(ZM_LOGDIR); fi )
66
 
67
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
68
 # Otherwise a system limit (for SysV at least) may be exceeded.
(-)multimedia/zoneminder/pkg-plist (-1 / +40 lines)
Lines 16-23 Link Here
16
bin/zmwatch.pl
16
bin/zmwatch.pl
17
bin/zmx10.pl
17
bin/zmx10.pl
18
@unexec if cmp -s %D/etc/zm.conf.sample %D/etc/zm.conf; then rm -f %D/etc/zm.conf; fi
18
@unexec if cmp -s %D/etc/zm.conf.sample %D/etc/zm.conf; then rm -f %D/etc/zm.conf; fi
19
@mode 0600
19
etc/zm.conf.sample
20
etc/zm.conf.sample
20
lib/perl5/%%PERL_VER%%/%%PERL_ARCH%%/perllocal.pod
21
@mode
22
%%DOCSDIR%%/zm_create.sql
23
%%PERL5_MAN3%%/ZoneMinder.3.gz
24
%%PERL5_MAN3%%/ZoneMinder::Base.3.gz
25
%%PERL5_MAN3%%/ZoneMinder::Config.3.gz
26
%%PERL5_MAN3%%/ZoneMinder::ConfigAdmin.3.gz
27
%%PERL5_MAN3%%/ZoneMinder::ConfigData.3.gz
28
%%PERL5_MAN3%%/ZoneMinder::Control.3.gz
29
%%PERL5_MAN3%%/ZoneMinder::Control::AxisV2.3.gz
30
%%PERL5_MAN3%%/ZoneMinder::Control::Ncs370.3.gz
31
%%PERL5_MAN3%%/ZoneMinder::Control::PanasonicIP.3.gz
32
%%PERL5_MAN3%%/ZoneMinder::Control::PelcoD.3.gz
33
%%PERL5_MAN3%%/ZoneMinder::Control::Visca.3.gz
34
%%PERL5_MAN3%%/ZoneMinder::Control::mjpgStreamer.3.gz
35
%%PERL5_MAN3%%/ZoneMinder::Database.3.gz
36
%%PERL5_MAN3%%/ZoneMinder::General.3.gz
37
%%PERL5_MAN3%%/ZoneMinder::Logger.3.gz
38
%%PERL5_MAN3%%/ZoneMinder::Memory.3.gz
39
%%PERL5_MAN3%%/ZoneMinder::Trigger::Channel.3.gz
40
%%PERL5_MAN3%%/ZoneMinder::Trigger::Channel::File.3.gz
41
%%PERL5_MAN3%%/ZoneMinder::Trigger::Channel::Handle.3.gz
42
%%PERL5_MAN3%%/ZoneMinder::Trigger::Channel::Inet.3.gz
43
%%PERL5_MAN3%%/ZoneMinder::Trigger::Channel::Serial.3.gz
44
%%PERL5_MAN3%%/ZoneMinder::Trigger::Channel::Spawning.3.gz
45
%%PERL5_MAN3%%/ZoneMinder::Trigger::Channel::Unix.3.gz
46
%%PERL5_MAN3%%/ZoneMinder::Trigger::Connection.3.gz
47
%%PERL5_MAN3%%/ZoneMinder::Trigger::Connection::Example.3.gz
21
%%SITE_PERL%%/ZoneMinder.pm
48
%%SITE_PERL%%/ZoneMinder.pm
22
%%SITE_PERL%%/ZoneMinder/Base.pm
49
%%SITE_PERL%%/ZoneMinder/Base.pm
23
%%SITE_PERL%%/ZoneMinder/Config.pm
50
%%SITE_PERL%%/ZoneMinder/Config.pm
Lines 320-322 Link Here
320
@dirrm %%SITE_PERL%%/ZoneMinder/Memory
347
@dirrm %%SITE_PERL%%/ZoneMinder/Memory
321
@dirrm %%SITE_PERL%%/ZoneMinder/Control
348
@dirrm %%SITE_PERL%%/ZoneMinder/Control
322
@dirrm %%SITE_PERL%%/ZoneMinder
349
@dirrm %%SITE_PERL%%/ZoneMinder
350
@exec mkdir -m 0700 -p %%ZM_TMPDIR%%/fgfhfh
351
@exec chown %%WEB_USER%% %%ZM_TMPDIR%%
352
@exec chgrp %%WEB_GROUP%% %%ZM_TMPDIR%%
353
@exec mkdir -m 0755 -p %%ZM_RUNDIR%%
354
@exec chown %%WEB_USER%% %%ZM_RUNDIR%%
355
@exec chgrp %%WEB_GROUP%% %%ZM_RUNDIR%%
356
@exec mkdir -m 0755 -p %%ZM_LOGDIR%%
357
@exec chown %%WEB_USER%% %%ZM_LOGDIR%%
358
@exec chgrp %%WEB_GROUP%% %%ZM_LOGDIR%%
359
@unexec rmdir %%ZM_RUNDIR%%
360
@unexec rmdir %%ZM_TMPDIR%%
361
@unexec rmdir %%ZM_LOGDIR%%

Return to bug 192123