-
Notifications
You must be signed in to change notification settings - Fork 234
Expand file tree
/
Copy pathinstall_deps.sh
More file actions
executable file
·84 lines (73 loc) · 2.03 KB
/
Copy pathinstall_deps.sh
File metadata and controls
executable file
·84 lines (73 loc) · 2.03 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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
#!/bin/bash
echo "Installing Maven dependencies..."
mvn install:install-file \
-Dfile=lib/ant/poi/poi-3.10-FINAL-20140208.jar \
-DgroupId=com.apache.poi \
-DartifactId=poi \
-Dversion=3.10-FINAL \
-Dpackaging=jar
mvn install:install-file \
-Dfile=lib/ant/eclipse/org.eclipse.draw2d_3.10.100.201606061308.jar \
-DgroupId=org.eclipse \
-DartifactId=draw2d \
-Dversion=3.10.100 \
-Dpackaging=jar \
-DgeneratePom=true
mvn install:install-file \
-Dfile=lib/ant/smile/smile-1.3.1-java7.jar \
-DgroupId=com.github.haifengl \
-DartifactId=smile \
-Dversion=1.3.1 \
-Dpackaging=jar
OS=$(uname -s)
ARCH=$(uname -m)
case "$ARCH" in
x86_64|amd64)
MAVEN_ARCH="x86_64"
;;
arm64|aarch64)
MAVEN_ARCH="aarch64"
;;
*)
echo "Unsupported architecture: $ARCH"
exit 1
;;
esac
case "$OS" in
Linux*)
SWT_FILE="lib/ant/eclipse/org.eclipse.swt.gtk.linux.x86_64_3.114.100.v20200604-0951.jar"
SWT_ARTIFACTID="org.eclipse.swt.gtk.linux.x86_64"
PROFILE="gtk-64"
PLATFORM="Linux"
;;
Darwin*)
SWT_FILE="lib/ant/eclipse/org.eclipse.swt.cocoa.macosx.x86_64_3.114.100.v20200604-0951.jar"
SWT_ARTIFACTID="org.eclipse.swt.cocoa.macosx.x86_64"
PROFILE="osx-64"
PLATFORM="macOS"
;;
CYGWIN*|MINGW*|MSYS*|Windows*)
SWT_FILE="lib/ant/eclipse/org.eclipse.swt.win32.win32.x86_64_3.114.100.v20200604-0951.jar"
SWT_ARTIFACTID="org.eclipse.swt.win32.win32.x86_64"
PROFILE="win-64"
PLATFORM="Windows"
;;
*)
echo "Unsupported operating system: $OS"
exit 1
;;
esac
echo "Detected platform: $PLATFORM ($ARCH)"
echo "Installing SWT library: $SWT_ARTIFACTID"
if [ ! -f "$SWT_FILE" ]; then
echo "Error: SWT library file not found: $SWT_FILE"
echo "Please ensure the correct SWT library for your platform is in the lib/ant/eclipse/ directory."
exit 1
fi
mvn install:install-file \
-Dfile="$SWT_FILE" \
-DgroupId=org.eclipse.platform \
-DartifactId="$SWT_ARTIFACTID" \
-Dversion=3.114.100 \
-Dpackaging=jar
echo "Dependencies installed successfully!"