Add a dist target to the Makefile

This commit is contained in:
Tim Foster 2008-09-23 10:12:19 +01:00
parent 8ddb975058
commit db4ded62bd

View File

@ -1,8 +1,19 @@
DIR = \
`basename ${PWD}`
pkg: clean
mkdir -p proto
cat `pwd`/src/pkginfo.s | sed -e s/~PSTAMP~/`uname -n``date +%Y%m%d%H%M%S`/g > `pwd`/src/pkginfo
pkgmk -f `pwd`/src/prototype -d `pwd`/proto -r `pwd`/src
cat src/pkginfo.s | sed -e s/~PSTAMP~/`uname -n``date +%Y%m%d%H%M%S`/g > src/pkginfo
pkgmk -f src/prototype -d proto -r src
clean:
rm -rf proto/*
rmdir proto
if [ -d proto ] ; then \
rmdir proto ; \
fi
dist:
hg revert --all
tar cf ${DIR}.tar -C .. ${DIR}/Changelog -C .. ${DIR}/Makefile \
-C .. ${DIR}/README.zfs-auto-snapshot.txt -C .. ${DIR}/src
gzip ${DIR}.tar