CONFIGURE = aclocal.m4 configure config.guess config.sub install-sh ltmain.sh
LSRCFILES = configure.ac release.sh README VERSION $(CONFIGURE)
SRCTARINC = m4/libtool.m4 m4/lt~obsolete.m4 m4/ltoptions.m4 m4/ltsugar.m4 \
- m4/ltversion.m4 po/xfsprogs.pot $(CONFIGURE)
-
+ m4/ltversion.m4 po/xfsprogs.pot .gitcensus $(CONFIGURE)
LDIRT = config.log .ltdep .dep config.status config.cache confdefs.h \
conftest* built .census install.* install-dev.* *.gz \
autom4te.cache/* libtool include/builddefs include/platform_defs.h
$(Q)rm -f $(LDIRT)
realclean: distclean
- $(Q)rm -f $(CONFIGURE)
+ $(Q)rm -f $(CONFIGURE) .gitcensus
#
# All this gunk is to allow for a make dist on an unconfigured tree
$(Q)$(MAKE) $(MAKEOPTS) -C . $@
else
$(Q)$(MAKE) $(MAKEOPTS) $(SRCDIR)
- $(Q)$(MAKE) $(MAKEOPTS) -C po
- $(Q)$(MAKE) $(MAKEOPTS) source-link
$(Q)cd $(SRCDIR) && dpkg-buildpackage
endif
-$(SRCDIR) : $(_FORCE)
+$(SRCDIR) : $(_FORCE) $(SRCTAR)
rm -fr $@
- mkdir -p $@
+ $(Q)$(TAR) -zxvf $(SRCTAR)
-$(SRCTAR) : default
- $(Q)git archive --prefix=$(SRCDIR)/ --format=tar v$(PKG_VERSION) > $(SRCDIR).tar
- $(Q)$(TAR) --transform "s,^,$(SRCDIR)/," -rf $(SRCDIR).tar \
- $(SRCTARINC)
- $(Q)$(ZIP) $(SRCDIR).tar
+$(SRCTAR) : default $(SRCTARINC) .gitcensus
+ $(Q)$(TAR) --transform "s,^,$(SRCDIR)/," -zcf $(SRCDIR).tar.gz \
+ `cat .gitcensus` $(SRCTARINC)
echo Wrote: $@
+
+.gitcensus: $(_FORCE)
+ $(Q)if test -d .git; then \
+ git ls-files > .gitcensus && echo "new .gitcensus"; \
+ fi
$(Q)$(MAKE) $(MAKEOPTS) -q -C $@ || $(MAKE) $(MAKEOPTS) -C $@
endif
-source-link:
- @test -z "$$DIR" && DIR="."; \
- for f in `echo $(SRCFILES) $(SUBDIRS) $(POTHEAD)`; do \
- if test -d $$f ; then \
- mkdir $(TOPDIR)/$(PKG_NAME)-$(PKG_VERSION)/$$DIR/$$f || exit $$?; \
- $(MAKEF) DIR=$$DIR/$$f -C $$f $@ || exit $$?; \
- else \
- ln $$f $(TOPDIR)/$(PKG_NAME)-$(PKG_VERSION)/$$DIR/$$f || exit $$?; \
- fi; \
- done
-
#
# Standard targets
#