From: Ben Myers <bpm@sgi.com>
To: Nathan Scott <nathans@debian.org>
Cc: Andrew Dahl <adahl@sgi.com>, xfs@oss.sgi.com
Subject: xfsdump: update 'make deb' to use tarball archive
Date: Thu, 14 Feb 2013 11:31:20 -0600 [thread overview]
Message-ID: <20130214173120.GF22182@sgi.com> (raw)
In-Reply-To: <20130214162454.GH30652@sgi.com>
This patch changes the build process so that 'make deb' uses the same
process of creating a source tree as the release script.
* Add a list of files which go in the release tarball in .gitcensus
This is needed so that you can create a tarball in a bare release
tree, when .git is not available.
* Modify the SRCTAR target to include files from .gitcensus and use tar
instead of git archive.
* Modify the SRCTARINC files to include .gitcensus, and include
.gitcensus in the 'make realclean' target.
* remove the 'make source-link' target.
Signed-off-by: Ben Myers <bpm@sgi.com>
---
.gitignore | 1 +
Makefile | 23 ++++++++++++-----------
include/buildrules | 11 -----------
3 files changed, 13 insertions(+), 22 deletions(-)
Index: b/.gitignore
===================================================================
--- a/.gitignore 2013-02-14 10:55:13.061985803 -0600
+++ b/.gitignore 2013-02-14 10:55:49.061340568 -0600
@@ -4,6 +4,7 @@
# build system
.census
+.gitcensus
/include/config.h
/include/builddefs
/install-sh
Index: b/Makefile
===================================================================
--- a/Makefile 2013-02-14 10:55:06.961977139 -0600
+++ b/Makefile 2013-02-14 10:59:19.131340450 -0600
@@ -30,7 +30,7 @@ SRCTAR = $(PKG_NAME)-$(PKG_VERSION).tar.
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 $(CONFIGURE)
+ m4/ltversion.m4 .gitcensus $(CONFIGURE)
LDIRT = config.log .ltdep .dep config.status config.cache confdefs.h \
conftest* built .census install.* install-dev.* *.gz \
@@ -100,7 +100,7 @@ distclean: clean
rm -f $(LDIRT)
realclean: distclean
- rm -f $(CONFIGURE)
+ rm -f $(CONFIGURE) .gitcensus
#
# All this gunk is to allow for a make dist on an unconfigured tree
@@ -117,18 +117,19 @@ ifeq ($(HAVE_BUILDDEFS), no)
$(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
Index: b/include/buildrules
===================================================================
--- a/include/buildrules 2013-02-14 10:59:26.221945695 -0600
+++ b/include/buildrules 2013-02-14 10:59:39.321985640 -0600
@@ -23,17 +23,6 @@ $(SUBDIRS):
$(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
#
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
next prev parent reply other threads:[~2013-02-14 17:31 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <50F44B2E.9050408@sgi.com>
[not found] ` <50F44B62.7060504@sgi.com>
2013-02-01 2:10 ` [PATCH 1/4] xfsprogs: Refactor release scripts to conform to using git archive Ben Myers
[not found] ` <50F44B87.3040102@sgi.com>
2013-02-01 2:36 ` [PATCH 2/4] xfsdump: " Ben Myers
[not found] ` <50F44BA5.9030509@sgi.com>
2013-02-01 2:55 ` [PATCH 3/4] xfstests: " Ben Myers
[not found] ` <50F44BC0.80708@sgi.com>
2013-02-01 16:47 ` [PATCH 4/4] dmapi: " Ben Myers
2013-02-01 19:09 ` [PATCH 0/4] " Ben Myers
2013-02-06 1:15 ` Dave Chinner
2013-02-06 6:28 ` Nathan Scott
2013-02-06 19:31 ` [PATCH 0/4] Refactor release scripts to conform to using git?archive Ben Myers
2013-02-06 22:47 ` Dave Chinner
2013-02-14 1:08 ` [PATCH 0/4] Refactor release scripts to conform to using git archive Ben Myers
2013-02-14 2:14 ` Nathan Scott
2013-02-14 16:24 ` Ben Myers
2013-02-14 16:54 ` xfsprogs: update 'make deb' to use tarball Ben Myers
2013-02-14 22:26 ` Nathan Scott
2013-02-14 22:50 ` Dave Chinner
2013-02-14 17:31 ` Ben Myers [this message]
2013-02-14 22:27 ` xfsdump: update 'make deb' to use tarball archive Nathan Scott
2013-02-14 22:51 ` Dave Chinner
2013-02-14 22:25 ` [PATCH 0/4] Refactor release scripts to conform to using git archive Nathan Scott
2013-02-14 22:37 ` Ben Myers
2013-02-14 22:36 ` Dave Chinner
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20130214173120.GF22182@sgi.com \
--to=bpm@sgi.com \
--cc=adahl@sgi.com \
--cc=nathans@debian.org \
--cc=xfs@oss.sgi.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox