Mercurial > trustbridge
annotate packaging/create-dist-package.sh.in @ 801:4538cda1062c
Merged
author | Sascha Wilde <wilde@intevation.de> |
---|---|
date | Tue, 15 Jul 2014 15:44:53 +0200 |
parents | fdc15f0cfdd8 |
children | eef8e0ca82b9 |
rev | line source |
---|---|
760
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
1 #!/bin/bash |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
2 # Helper script to package the files expected by the -admin application |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
3 # Windows build is expected to live in CMAKE_SOURCE_DIR/build-windows |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
4 set -x |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
5 set -e |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
6 |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
7 if [ ! -d "$WINDOWS_NSSDIR" ]; then |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
8 echo "ERROR: Please set WINDOWS_NSSDIR to the location of your nss binaries" |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
9 exit 1 |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
10 fi |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
11 |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
12 TMPD=$(mktemp -d) |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
13 TMPDIR=$TMPD/TrustBridge-@PROJECT_VERSION@ |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
14 cd @CMAKE_BINARY_DIR@ |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
15 /bin/bash packaging/linux-createpackage.sh |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
16 mkdir -p $TMPDIR/linux |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
17 mkdir -p $TMPDIR/windows |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
18 cp @CMAKE_BINARY_DIR@/TrustBridge-@PROJECT_VERSION@.sh $TMPDIR/linux |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
19 cp @CMAKE_SOURCE_DIR@/build-windows/ui/trustbridge.exe $TMPDIR/windows |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
20 cp @CMAKE_SOURCE_DIR@/build-windows/cinst/cinst.exe $TMPDIR/windows |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
21 cp @CMAKE_SOURCE_DIR@/build-windows/cinst/mozilla.exe $TMPDIR/windows |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
22 cp @CMAKE_SOURCE_DIR@/packaging/filelist.nsh $TMPDIR |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
23 cp @CMAKE_SOURCE_DIR@/packaging/trustbridge.nsi $TMPDIR |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
24 cp -r @CMAKE_SOURCE_DIR@/packaging/resources $TMPDIR/resources |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
25 LC_ALL="de_DE.latin-1" echo "company=Bundesamt f�r Sicherheit in der Informationstechnik" > $TMPDIR/meta.ini |
794
fdc15f0cfdd8
(issue61) NSIS Write uninstall information and make URL configurable.
Andre Heinecke <andre.heinecke@intevation.de>
parents:
760
diff
changeset
|
26 EST_SIZE=$(du -s $TMPDIR/windows | cut -f 1) |
760
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
27 echo "version_number=@PROJECT_VERSION@" >> $TMPDIR/meta.ini |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
28 echo "setupname=%1TrustBridge-@PROJECT_VERSION@.exe" >> $TMPDIR/meta.ini |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
29 echo "productname=TrustBridge" >> $TMPDIR/meta.ini |
794
fdc15f0cfdd8
(issue61) NSIS Write uninstall information and make URL configurable.
Andre Heinecke <andre.heinecke@intevation.de>
parents:
760
diff
changeset
|
30 echo "info_url=https://wald.intevation.org/projects/trustbridge/" >> $TMPDIR/meta.ino |
fdc15f0cfdd8
(issue61) NSIS Write uninstall information and make URL configurable.
Andre Heinecke <andre.heinecke@intevation.de>
parents:
760
diff
changeset
|
31 echo "size=$EST_SIZE" >> $TMPDIR/meta.ini |
760
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
32 cp $WINDOWS_NSSDIR/*.dll $TMPDIR/windows |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
33 cd $TMPD |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
34 zip -r TrustBridge-@PROJECT_VERSION@.zip TrustBridge-@PROJECT_VERSION@ |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
35 mv TrustBridge-@PROJECT_VERSION@.zip @CMAKE_BINARY_DIR@ |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
36 rm -r $TMPD |
438d7c88104f
Add create-dist-package script to create a package suitable for trustbridge-admin
Andre Heinecke <andre.heinecke@intevation.de>
parents:
diff
changeset
|
37 echo "Package is: @CMAKE_BINARY_DIR@/TrustBridge-@PROJECT_VERSION@.zip" |