Code

BUGS file addition to release
[nagiosplug.git] / Makefile.am
1 ## Process this file with automake to produce Makefile.in
3 SUBDIRS = intl lib plugins plugins-scripts m4 po
5 EXTRA_DIST = config.rpath \
6         ABOUT-NLS ACKNOWLEDGEMENTS AUTHORS BUGS CHANGES CODING FAQ LEGAL \
7         REQUIREMENTS SUPPORT THANKS \
8         Helper.pm contrib pkg nagios-plugins.spec
10 ACLOCAL_AMFLAGS = -I m4
12 localedir = $(datadir)/locale
13 DEFS = -DLOCALEDIR=\"$(localedir)\"
15 dist-hook:
16         make THANKS nagios-plugins.spec pkg/fedora/nagios-plugins.spec
18 test:
19         cd plugins; $(MAKE) test
20         cd plugins-scripts; $(MAKE) test
22 nagios-plugins.spec: nagios-plugins.spec.in
23         sed "s/%%{VERSION}/${VERSION}/;s/%%{RELEASE}/${RELEASE}/;s/^%%{requires}$$//" $? > $@
25 pkg/fedora/nagios-plugins.spec: nagios-plugins.spec.in
26         $(top_srcdir)/mkinstalldirs pkg/fedora
27         sed "s/%%{VERSION}/${VERSION}/;s/%%{RELEASE}/${RELEASE}/;/^# Requires$$/r $(top_srcdir)/pkg/fedora/requires" $? > $@
29 # Solaris pkgmk
30 BUILDDIR = build-solaris
31 PACKDIR = build-pkg
32 PKGSCRIPT = pkg/solaris/solpkg
34 solpkg:
35         if [ ! -d $(BUILDDIR) ] ; then mkdir $(BUILDDIR); fi
36         if [ ! -d $(PACKDIR) ] ; then mkdir $(PACKDIR); fi
37         $(MAKE) all
38         $(MAKE) DESTDIR=$$PWD/$(BUILDDIR) install
39         $(INSTALL) pkg/solaris/pkginfo $(BUILDDIR)
40         cd $(BUILDDIR) && $(PERL) ../$(PKGSCRIPT) ../$(PACKDIR)
42 THANKS: THANKS.in
43         @echo "This software is brought to you by the Nagios Plugins Development Team. However," > $@
44         @echo "there have been many contributors to this project. Everyone below has helped in " >> $@
45         @echo "raising bug reports, creating patches or contributing new plugins." >> $@
46         @echo "" >> $@
47         perl -e ' while (<>) { print STDERR "Duplicate: $$_",$$/ if ($$a{$$_}) ; $$a{$$_}++}; print sort by_last_field (keys %a); sub by_last_field { ($$a1) = $$a =~ /\s(\w+)$$/; ($$b1) = $$b =~ /\s(\w+)$$/; $$a1 cmp $$b1}' $? >> $@
49 pkgclean:
50         rm -rf $(BUILDDIR) $(PACKDIR)