On Mon, 2005-20-06 at 17:40 +0200, Gour wrote:

> At least, I'd like that 'darcs dist' would keep the permission for easy
> packaging of the project, but no luck :-(

I studiously avoid the autotools; in our Makefile we ended up doing
something like what follows (extra newlines added for clarity):

dist: distclean
        @echo "CHECK     pristine, fully recorded tree"
        darcs what -s | perl -n -e 'if (!/^No changes!/) { print "\nFailed: you 
can only run make dist from a\npristene tree or one with all changes 
recorded\n\n" ; exit 1 }'

        @echo "PREP      files for distribution"
        darcs dist --dist-name xseq-$(VERSION) >/dev/null
        mv xseq-$(VERSION).tar.gz /tmp
        cd /tmp && tar xzf xseq-$(VERSION).tar.gz
        cd /tmp/xseq-$(VERSION) && rm -r stash && chmod +x configure

        @echo "TAR       distribution tarball"
        tar czf xseq-$(VERSION).tar.gz -C /tmp xseq-$(VERSION)

        @echo "RM        temporary files"
        rm -r /tmp/xseq-$(VERSION)*

Using darcs dist helps pick up only significant files and avoids cruft,
but there are still some aspects of the recorded tree that we don't want
to distribute (the stash/ directory, for example) and of course there is
the executable permissions nonsense. (Why, oh why, can't darcs get this
straight?).

This fragment runs in a Makefile where VERSION is defined (extracted
from a source file by configure, actually) and where MAKEFLAGS=-s is
standard, making for nice clean output.

AfC
Sydney

-- 
Andrew Frederick Cowie

Technology strategy, managing change, establishing procedures,
and executing successful upgrades to mission critical business
infrastructure.

http://www.operationaldynamics.com/

Sydney   New York   Toronto   London


_______________________________________________
darcs-users mailing list
[email protected]
http://www.abridgegame.org/mailman/listinfo/darcs-users

Reply via email to