1#
2# Makefile for perl support modules and routine
3#
4makfile:=perl.mak
5
6PERL_PATH_SQ = $(subst ','\'',$(PERL_PATH))
7prefix_SQ = $(subst ','\'',$(prefix))
8
9all install instlibdir: $(makfile)
10 $(MAKE) -f $(makfile) $@
11
12clean:
13 test -f $(makfile) && $(MAKE) -f $(makfile) $@ || exit 0
14 $(RM) ppport.h
15 $(RM) $(makfile)
16 $(RM) $(makfile).old
17
18ifdef NO_PERL_MAKEMAKER
19instdir_SQ = $(subst ','\'',$(prefix)/lib)
20$(makfile): ../GIT-CFLAGS Makefile
21 echo all: > $@
22 echo ' :' >> $@
23 echo install: >> $@
24 echo ' mkdir -p $(instdir_SQ)' >> $@
25 echo ' $(RM) $(instdir_SQ)/Git.pm; cp Git.pm $(instdir_SQ)' >> $@
26 echo ' $(RM) $(instdir_SQ)/Error.pm; \
27 cp private-Error.pm $(instdir_SQ)/Error.pm' >> $@
28 echo instlibdir: >> $@
29 echo ' echo $(instdir_SQ)' >> $@
30else
31$(makfile): Makefile.PL ../GIT-CFLAGS
32 '$(PERL_PATH_SQ)' $< FIRST_MAKEFILE='$@' PREFIX='$(prefix_SQ)'
33endif
34
35# this is just added comfort for calling make directly in perl dir
36# (even though GIT-CFLAGS aren't used yet. If ever)
37../GIT-CFLAGS:
38 $(MAKE) -C .. GIT-CFLAGS
39