1 include ..
/..
/Makefile.omd
5 GEARMAND
= $(shell grep
"^VERSION " ..
/gearmand
/Makefile | awk
'{ print $$3 }')
6 DIR
= mod_gearman-
$(VERSION
)
11 test -f mod_gearman-
${VERSION}.
tar.gz || wget
"http://labs.consol.de/wp-content/uploads/2010/09/mod_gearman-$(VERSION).tar.gz"
12 tar xzf mod_gearman-
$(VERSION
).
tar.gz
13 #for p in patches/*.patch ; do \
14 # echo "applying $$p..." ; \
15 # ( cd $(DIR) ; patch -p1 -b ) < $$p || exit 1; \
18 .
/configure
--prefix=$(OMD_ROOT
) --enable-embedded-perl
--with-gearman
=$(shell pwd
)/..
/gearmand
/gearmand-
${GEARMAND} && \
22 $(MAKE
) DESTDIR
=$(DESTDIR
) -C
$(DIR
) -j
1 install
24 [ -d
$(DESTDIR
)$(OMD_ROOT
)/lib
/nagios
/plugins
] || mkdir
-p
$(DESTDIR
)$(OMD_ROOT
)/lib
/nagios
/plugins
25 mv
$(DESTDIR
)$(OMD_ROOT
)/bin
/check_gearman
$(DESTDIR
)$(OMD_ROOT
)/lib
/nagios
/plugins
/
26 rm -rf
$(DESTDIR
)$(OMD_ROOT
)/share
/mod_gearman
/*.conf
27 rm -f
$(DESTDIR
)$(OMD_ROOT
)/lib
/mod_gearman
/mod_gearman.so
28 rm -rf
$(DESTDIR
)$(OMD_ROOT
)/etc
29 rm -rf
$(DESTDIR
)$(OMD_ROOT
)/var
32 mkdir
-p
$(SKEL
)/etc
/mod-gearman
33 cp
$(DIR
)/etc
/mod_gearman_neb.conf.in
$(SKEL
)/etc
/mod-gearman
/server.cfg
34 cp
$(DIR
)/etc
/mod_gearman_worker.conf.in
$(SKEL
)/etc
/mod-gearman
/worker.cfg
35 for p in patches
/*.skel_patch
; do \
36 echo
"applying $$p..." ; \
37 ( cd
$(SKEL
) ; patch
-p1
) < $$p || exit
1; \
39 find
$(SKEL
)/etc
/mod-gearman
-name \
*.orig
-exec
rm {} \
;
40 mkdir
-p
$(SKEL
)/var
/log
/mod_gearman
41 touch
$(SKEL
)/var
/log
/mod_gearman
/neb.log
42 touch
$(SKEL
)/var
/log
/mod_gearman
/worker.log