Added dist target

This commit is contained in:
mainzelm 2003-05-19 14:37:18 +00:00
parent 04f3bf68a0
commit 4f33260308
1 changed files with 37 additions and 0 deletions

View File

@ -1,6 +1,40 @@
SCX=@SCX@ SCX=@SCX@
ORION-WM=orion-wm ORION-WM=orion-wm
enough: $(ORION-WM)
# --------------------
# Distribution...
distdir = /tmp
# DISTFILES should include all sources.
DISTFILES = COPYING INSTALL README configure configure.in Makefile.in \
src/*.scm doc/*.html
distname = $(ORION-WM)-0.1
.PHONY : dist
dist:
distname=$(distname) && \
distfile=$(distdir)/$$distname.tar.gz && \
if [ -d $(distdir) ] && \
[ -w $$distfile -o -w $(distdir) ]; then \
rm -f $$distname && \
ln -s . $$distname && \
files='' && \
for i in $(DISTFILES); do \
files="$$files $$distname/$$i"; \
done && \
tar -cf - $$files | \
gzip --best >$$distfile && \
rm $$distname; \
else \
echo "Can't write $$distfile" >&2; \
exit 1; \
fi
$(ORION-WM): Makefile $(ORION-WM): Makefile
script=$(ORION-WM) && \ script=$(ORION-WM) && \
echo "#!$(SCX) \\" > $$script && \ echo "#!$(SCX) \\" > $$script && \
@ -8,3 +42,6 @@ $(ORION-WM): Makefile
echo '!#' >> $$script && \ echo '!#' >> $$script && \
echo '(start)' >> $$script && \ echo '(start)' >> $$script && \
chmod 755 $$script chmod 755 $$script
clean:
rm -f $(ORION-WM)