-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrelease.mk
63 lines (49 loc) · 1.9 KB
/
release.mk
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
include release.conf
BASEJAR=target/OMiSCID-$(release-version).jar
PATCHEDBASEJAR=OMiSCID-$(release-version).jar
INTERFACEJAR=omiscidService.jar
m=make -f release.mk
remote-dist:
$m ssh-test
$m omiscid-jar
$m clean-package-build
$m release-package
$m clean-destination
# displays a warning if default domain is wrong
$m checkdomain
ssh-test:
@ssh $(release-server) echo SSH OK
checkdomain:
@find src -name \*.java -exec egrep -e '_bip.+\._tcp' {} \; -exec echo "!!!!!!!!!!!!!!!!!!!!" \; -exec echo "!! DOMAIN WARNING !!" \; -exec echo "!!!!!!!!!!!!!!!!!!!!" \;
release-package-upload:
scp $(release-all-zip) $(release-diston)/
clean-package-build:
rm -rf ,,rel
mkdir ,,rel
clean-destination:
# cleans the concerned destinations
ssh $(release-server) rm -rf $(release-server-path)/$(release-version)
ssh $(release-server) mkdir -p $(release-server-path)/$(release-version)
release-package:
cp $(PATCHEDBASEJAR) ,,rel/$(release-omiscid-jar)
cp licences $(patsubst %,lib/%,$(release-jars)) $(patsubst %,lib/%,$(release-libs)) ,,rel/
mv ,,rel/ $(release-all-folder-name) && zip -r $(release-all-zip) $(release-all-folder-name)/ && mv $(release-all-folder-name)/ ,,rel
omiscid-jar:
rm -rf ,,build
mvn -Dmaven.test.skip=true install
mkdir ,,build
cd ,,build && jar xf ../$(BASEJAR)
cp CHANGES ,,build/
cd src/main/java && find . -name \*.java -exec cp {} ../../../,,build/{} \;
cd src/main/dnssd-src && find . -name \*.java -exec cp {} ../../../,,build/{} \;
#cd generated-src && find . -name \*.java -exec cp {} ../,,build/{} \;
cd src/main/user-level-src && find . -name \*.java -exec cp {} ../../../,,build/{} \;
cd ,,build && jar cvf ../$(PATCHEDBASEJAR) .
cd ,,build && ( \
rm -r fr/prima/omiscid/com ;\
rm -r fr/prima/omiscid/control ;\
rm -r fr/prima/omiscid/dnssd ;\
rm -r fr/prima/omiscid/user/*/impl ;\
rm -r org/ ;\
)
cd ,,build && jar cvf ../$(INTERFACEJAR) .