| 
      
      
      From: Jeevan V. <jva...@ya...> - 2008-04-07 02:12:39
      
     | 
| This is in regards to patch request 1935736 at http://sourceforge.net/tracker/index.php?func=detail&aid=193573&group_id=149850&atid=775999 Stephen Williams wrote: > I'm a little concerned how this will impact the making of > snapshots. In particular, I use "get-archive" to export by tag. I > then extract the generated tar file, run the autoconf.sh script, > and re-tar to make the actual snapshot bundle. > With this patch, the version.h header file is missing, and there is > no way to generate it once it is exported. We should discuss in the > iverilog-devel list what to do about this. Please follow up there > with any ideas you might have. The git sources reveal that the git maintainers also use `git archive' to make a distribution tarball and use `git describe' to obtain a version string for their distribution. They have a `dist' target in their Makefile which appends the file with the version to the tarball. Also, instead of using a C include file for the version, like i did, they use a make include file; which allows them to automatically use the version in the tarball name and the RPM spec file. Along those lines, i could add a `dist' target to Makefile.in that would automatically build a tarball for a given tag (or the head, by default) and add the version information file and an updated verilog.spec file to it. One possible implementation would look like below. In Makefile.in TAG ?= HEAD version.mk: # Put `VERSION = <output of git-describe $(TAG)>' in version.mk include version.mk all: ... version.mk ... cd driver; make VERSION=$(VERSION) $@ verilog.spec: verilog.spec.in version.mk # Replace @@VERSION@@ with $(VERSION) SNAPSHOT = verilog-$(VERSION) dist: version.mk verilog.spec # Use git-archive $(TAG) to create $(SNAPSHOT).tar # Unpack to $(SNAPSHOT) # Copy version.mk and verilog.spec to $(SNAPSHOT) # Run autoconf.sh in $(SNAPSHOT) # Repack and compress $(SNAPSHOT) to $(SNAPSHOT).tar.gz In driver/Makefile.in main.o: ... ../version.mk The above example assumes that the verilog.spec file has been replaced with a verilog.spec.in file, and for simplicity's sake, there is just one version string instead of the two that i had in my patch. The latter brings me to a question i have: should the "0.9.devel" version string be treated any differently than i did? I just left it as it was. And, of course, anything else that needs to be done to make a snapshot can be added to the `dist' target. In the end making a snapshot would look like below. make dist TAG=<tagname> ____________________________________________________________________________________ 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 |