source: subversion/applications/editors/josm/nsis/josm-setup.sh @ 14186

Last change on this file since 14186 was 14186, checked in by ulf, 11 years ago

unify setup script

File size: 2.0 KB
Line 
1#!/bin/bash
2
3# Creates an josm-setup-xy.exe File
4#
5# for working on a debian-unix system install the nsis package with
6# apt-get install nsis
7# replace the  /usr/share/nsis/Plugins/System.dll with the Version from the nsis .zip File
8# The one comming with the debian package is missing the Call:: Function
9# See also /usr/share/doc/nsis/README.Debian
10#
11# Then download launch4j from http://launch4j.sourceforge.net/
12# wget http://mesh.dl.sourceforge.net/sourceforge/launch4j/launch4j-3.0.0-pre2-linux.tgz
13# and unpack it to /usr/share/launch4j
14
15## settings ##
16LAUNCH4J="/cygdrive/c/Programme/Launch4j/launch4jc.exe"
17MAKENSIS="/cygdrive/c/Programme/nsis/makensis.exe"
18
19svncorerevision=`svnversion ../core`
20svnpluginsrevision=`svnversion ../plugins`
21svnrevision="$svncorerevision-$svnpluginsrevision"
22
23#export VERSION=latest
24export VERSION=custom-${svnrevision}                                         
25
26echo "Creating Windows Installer for josm-$VERSION"
27
28##################################################################
29### Build the Complete josm + Plugin Stuff
30if true; then
31    (
32        echo "Build the Complete josm Stuff"
33       
34        echo "Compile Josm"
35        cd ../core
36        ant -q clean
37        ant -q compile || exit -1
38        cd ..
39       
40        echo "Compile Josm Plugins"
41        cd plugins
42        ant -q clean
43        ant -q dist || exit -1
44        ) || exit -1
45fi
46
47echo 
48echo "##################################################################"
49echo "### convert jar to exe with launch4j"
50# (an exe file makes attaching to file extensions a lot easier)
51# launch4j - http://launch4j.sourceforge.net/
52# delete old exe file first
53rm -f josm.exe
54$LAUNCH4J "launch4j.xml"
55
56if ! [ -s josm.exe ]; then
57    echo "NO Josm File Created"
58    exit -1
59fi
60
61echo 
62echo "##################################################################"
63echo "### create the josm-installer-${VERSION}.exe with makensis"
64# NSIS - http://nsis.sourceforge.net/Main_Page
65# apt-get install nsis
66$MAKENSIS -V2 -DVERSION=$VERSION josm.nsi
67
68# keep the intermediate file, for debugging
69rm -f josm-intermediate.exe
70mv josm.exe josm-intermediate.exe
Note: See TracBrowser for help on using the repository browser.