bindings/Makefile.am: Fix a bug that happened when src and build directory are not...
[collectd.git] / bindings / Makefile.am
1 EXTRA_DIST = perl/Collectd.pm perl/Makefile.PL perl/Collectd/Makefile.PL perl/Collectd/Unixsock.pm
2
3 PERL_SUBDIR = $(srcdir)/perl
4
5 all-local: @PERL_BINDINGS@
6
7 install-exec-local:
8         [ ! -f $(PERL_SUBDIR)/Makefile ] || $(MAKE) -C $(PERL_SUBDIR) install
9
10 clean-local:
11         [ ! -f $(PERL_SUBDIR)/Makefile ] || $(MAKE) -C $(PERL_SUBDIR) realclean
12
13 @srcdir@/perl: $(PERL_SUBDIR)/Makefile
14         $(MAKE) -C $(PERL_SUBDIR)
15
16 @srcdir@/perl/Makefile: @srcdir@/perl/Makefile.PL @srcdir@/perl/Collectd/Makefile.PL
17         cd $(PERL_SUBDIR) && @PERL@ Makefile.PL PREFIX=$(prefix) @PERL_BINDINGS_OPTIONS@
18
19 .PHONY: @srcdir@/perl
20