|
From: Jeevan V. <jva...@ya...> - 2008-04-08 15:54:44
|
Stephen Williams wrote:
> I think Jeevan's proposal (is that how you wish to be addressed?) is
> to generate the version stamp from within a git context then copy
> that information into the snapshot. There was some scripting to
> automate that.
Larry Doolittle wrote:
> I humbly request that a sensible way to make such a snapshot
> be found, documented (scripted?), and close to what Steve does
> for his public snapshots.
Here is a little script, based on what Steve said in an earlier post, that will recreate the 20080314 snapshot (without the autom4te.cache directories). It needs to be run in the directory with the git repo, but it doesn't change anything in that directory; the /tmp/verilog-20080314 directory is remade, though. (Run with sh -x to see what goes on.)
#!/bin/sh
tag_date=20080314
tag=s$tag_date
snapshot=verilog-$tag_date
# Clean out any old packing directory.
rm -rf /tmp/$snapshot
# Get sources from git for the given snapshot
# and put them in the packing directory.
git archive --format=tar --prefix=$snapshot/ $tag \
| tar -x -C /tmp
# Housekeeping.
(cd /tmp/$snapshot && sh autoconf.sh)
#--- Version specific things, e.g., version.h
#--- & verilog.spec, can be built here.
# Pack it up.
(cd /tmp && tar -cO --exclude 'autom4te.cache' $snapshot \
| gzip -9 > $snapshot.tar.gz)
# Look at the result
ls -l /tmp/$snapshot.tar.gz
I ran diff on the publicly available 20080314 snapshot and the one this script built, and they were same except for the configure files and the lexor_keyword.cc file, because my autoconf and gperf put different version numbers into those files. It builds and runs alright (`make check' passes).
Larry Doolittle wrote:
> One more thing: the current version of version.h handling
> breaks the write-protected pristine-source build concept.
> The reference source tree should not be touched with an
> out-of-tree configure/make.
That was nagging me, too. I have a scheme that avoids touching the source tree and does not break compilation if the version file is missing, but i've run into a bootstrapping issue with make. I'll have something to show in a day or two.
Cary R. wrote:
> Thanks for taking care of this!
Glad to be of help. Thank you all, for the comments.
Jeevan
____________________________________________________________________________________
You rock. That's why Blockbuster's offering you one month of Blockbuster Total Access, No Cost.
http://tc.deals.yahoo.com/tc/blockbuster/text5.com
|