-
Notifications
You must be signed in to change notification settings - Fork 112
Expand file tree
/
Copy pathmakeExecutable.sh
More file actions
executable file
·56 lines (44 loc) · 1.49 KB
/
makeExecutable.sh
File metadata and controls
executable file
·56 lines (44 loc) · 1.49 KB
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
#!/bin/bash
WINDOWS="--license-file ./LICENSE --type msi --win-dir-chooser --win-console"
OSX="--license-file ./LICENSE --type dmg"
DEBIAN="--license-file ./LICENSE --type deb"
APP="--type app-image"
APPWIN="--type app-image --win-console"
JPACKAGE=jpackage
TAG=$1
if [ "$TAG" == "WINDOWS" ]; then
OS=$WINDOWS
JPACKAGE="jpackage.exe"
elif [ "$TAG" == "OSX" ]; then
OS=$OSX
elif [ "$TAG" == "DEBIAN" ]; then
OS=$DEBIAN
elif [ "$TAG" == "APP" ]; then
OS=$APP
elif [ "$TAG" == "APPWIN" ]; then
OS=$APPWIN
else
echo Unrecognized tag "$TAG"
exit 1
fi
VERSION=5.2.1
RELEASE=release
BUILD=build
JAR=evomaster.jar
rm -fr $RELEASE
mkdir -p $RELEASE
rm -fr $BUILD
mkdir -p $BUILD
cp core/target/$JAR $BUILD/$JAR
YEAR=`date +'%Y'`
COPYRIGHT="Copyright 2016-$YEAR EvoMaster Team"
VENDOR="EvoMaster Team"
$JPACKAGE --main-jar $JAR --input $BUILD --dest $RELEASE --name evomaster \
--copyright "$COPYRIGHT" --vendor "$VENDOR" --app-version $VERSION $OS \
--java-options "--add-opens java.base/java.net=ALL-UNNAMED" \
--java-options "--add-opens java.base/java.util=ALL-UNNAMED"
# In theory, should not need --add-opens here, as in theory handled inside manifest of uber jar.
# Unfortunately, it does not work when unpacking an app-image distribution without installing it.
# After pulling enough hair understanding WTF was going on, an easy workaround was just to force the
# --add-opens here as well.
# IMPORTANT: must be kept in sync with maven-shade-plugin in pom.xml and JdkIssue