1 VERSION := $(shell pwd | sed -e 's/.*MUMail\.//')
3 VERSION_MAJOR := $(shell echo $(VERSION) | awk -F. '{print $$1 "." $$2}')
5 #VPATH = mumail:mumail/gui:mumail/mime:mumail/net:musoft/utils
9 SOURCE := $(shell find . -name "*.java" -print)
11 CLASS := $(patsubst %.java,%.class,$(SOURCE))
13 RELEASE = MUMail.jar \
20 philosophical-gnu-sm.jpg
22 ARCMDS = mkdir tmp; mkdir tmp/MUMail; \
23 \cp $(RELEASE) tmp/MUMail; \
24 (cd tmp;zip -add -recurse -dir=current MUMail.zip MUMail/\*); \
25 (cd tmp;tar cf MUMail.tar MUMail;gzip MUMail.tar); \
26 gtar czf MUMail.src.tar.gz $(shell find . -name "*.java" -print);\
27 \mv tmp/MUMail.tar.gz tmp/MUMail.zip .; \
34 jar cf MUMail.jar $(shell find . -name "*.class" -print | sed -e "s/\\$$/\\\\\\$$/g" )
41 @echo creating archives: stage 1
46 @echo patching RELEASENOTES.html
47 @cat html/RELEASENOTES.html | \
48 sed -e 's/%VERSION_MAJOR%/$(VERSION_MAJOR)/g' | \
49 sed -e 's/%VERSION_MINOR%/$(VERSION)/g' | \
50 sed -e 's/%JAR_SIZE%/\
51 $(shell du -k MUMail.jar | awk '{print $$1}')/' | \
52 sed -e 's/%TAR_SIZE%/\
53 $(shell du -k MUMail.tar.gz | awk '{print $$1}')/' | \
54 sed -e 's/%ZIP_SIZE%/\
55 $(shell du -k MUMail.zip | awk '{print $$1}')/' | \
56 sed -e 's/%SRC_SIZE%/\
57 $(shell du -k MUMail.src.tar.gz | awk '{print $$1}')/' > \
59 @echo creating archives: stage 2
67 \cp MUMail.tar.gz $(HOME)/www
68 (cd $(HOME)/www; gunzip MUMail.tar.gz; tar xf MUMail.tar; gzip MUMail.tar ;\
69 \mv MUMail/RELEASENOTES.html MUMail/index.html; \
70 \mv MUMail.tar.gz MUMail/MUMail.$(VERSION).tar.gz)
71 \mv MUMail.zip $(HOME)/www/MUMail/MUMail.$(VERSION).zip
72 \mv MUMail.src.tar.gz $(HOME)/www/MUMail/MUMail.$(VERSION).src.tar.gz
76 java mumail.MUMail -pophost einstein.deteline.de -smtphost mail.deteline.de
80 (cd /; appletviewer $(CURDIR)/MUMail.html)
84 find . -name "*.class" -exec \rm {} \;
85 find . -name "*~" -exec \rm {} \;
86 find . -name "#*#" -exec \rm {} \;
87 -\rm -r MUMail.src.tar.gz MUMail.tar.gz MUMail.jar MUMail.zip
90 (cd ..; gtar czf tars/MUMail.$(VERSION).tgz MUMail.$(VERSION))
93 gtar czf src.tgz $(SOURCE)