diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 00000000..c76e0d25 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,6 @@ +/.* export-ignore +/hooks export-ignore +doc/*.html export-ignore +coverity.sh export-ignore + +/** export-subst diff --git a/.gitignore b/.gitignore index acba1527..f74c4287 100644 --- a/.gitignore +++ b/.gitignore @@ -7,6 +7,10 @@ /MSVC_* .libs/ +# release files +/libtomcrypt-* +/crypt-* + # suppress output of build process gcc_[12].txt testok.txt diff --git a/makefile b/makefile index 792383e8..1a76fd06 100644 --- a/makefile +++ b/makefile @@ -387,7 +387,8 @@ doxy: doxygen #from the clean command! This is because most people would like to keep the #nice pre-compiled crypt.pdf that comes with libtomcrypt! We only need to #delete it if we are rebuilding it. -docs: crypt.tex +docs: doc/crypt.pdf +doc/crypt.pdf: crypt.tex rm -f doc/crypt.pdf $(LEFTOVERS) cp crypt.tex crypt.bak touch --reference=crypt.tex crypt.bak @@ -418,24 +419,21 @@ docdvi: crypt.tex latex crypt $(silent_stdout) latex crypt $(silent_stdout) -#zipup the project (take that!) -no_oops: clean - cd .. ; cvs commit - echo Scanning for scratch/dirty files - find . -type f | grep -v CVS | xargs -n 1 bash mess.sh - -zipup: no_oops docs - cd .. ; rm -rf crypt* libtomcrypt-$(VERSION) ; mkdir libtomcrypt-$(VERSION) ; \ - cp -R ./libtomcrypt/* ./libtomcrypt-$(VERSION)/ ; \ - cd libtomcrypt-$(VERSION) ; rm -rf `find . -type d | grep CVS | xargs` ; cd .. ; \ - tar -cjvf crypt-$(VERSION).tar.bz2 libtomcrypt-$(VERSION) ; \ - zip -9r crypt-$(VERSION).zip libtomcrypt-$(VERSION) ; \ - gpg -b -a crypt-$(VERSION).tar.bz2 ; gpg -b -a crypt-$(VERSION).zip ; \ - mv -fv crypt* ~ ; rm -rf libtomcrypt-$(VERSION) +zipup: doc/crypt.pdf + @git diff-index --quiet HEAD -- || ( echo "FAILURE: uncommited changes or not a git" && exit 1 ) + @perl helper.pl --check-all || ( echo "FAILURE: helper.pl --check-all errors" && exit 1 ) + rm -rf libtomcrypt-$(VERSION) libtomcrypt-$(VERSION).* + # files/dirs excluded from "git archive" are defined in .gitattributes + git archive --format=tar --prefix=libtomcrypt-$(VERSION)/ HEAD | tar x + mkdir -p libtomcrypt-$(VERSION)/doc + cp doc/crypt.pdf libtomcrypt-$(VERSION)/doc/crypt.pdf + tar -cjf libtomcrypt-$(VERSION).tar.bz2 libtomcrypt-$(VERSION) + zip -9rq libtomcrypt-$(VERSION).zip libtomcrypt-$(VERSION) + rm -rf libtomcrypt-$(VERSION) + gpg -b -a libtomcrypt-$(VERSION).tar.bz2 + gpg -b -a libtomcrypt-$(VERSION).zip perlcritic: perlcritic *.pl -# $Source$ -# $Revision$ -# $Date$ +# git commit: $Format:%h$ $Format:%ai$ $Format:%ci$ diff --git a/mess.sh b/mess.sh deleted file mode 100755 index bd8dc19c..00000000 --- a/mess.sh +++ /dev/null @@ -1,4 +0,0 @@ -#!/bin/bash -if cvs log $1 >/dev/null 2>/dev/null; then exit 0; else echo "$1 shouldn't be here, removed"; rm -f $1 ; fi - -