summaryrefslogtreecommitdiff
blob: ff9ec5b929ea4a8600aa283a4500a03b548ebf67 (plain)
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
#!/bin/bash

# build gsjava
cd ../gsjava

bash build_darwin.sh

cd ../gsviewer

cp ../gsjava/gsjava.jar gsjava.jar

mkdir -p bin

echo "Compiling gsviewer Java source..."
javac -sourcepath src/ -d bin/ \
	-classpath "../gsjava/bin" \
	"src/com/artifex/gsviewer/DefaultUnhandledExceptionHandler.java" \
	"src/com/artifex/gsviewer/Page.java" \
	"src/com/artifex/gsviewer/Settings.java" \
	"src/com/artifex/gsviewer/Document.java" \
	"src/com/artifex/gsviewer/ImageUtil.java" \
	"src/com/artifex/gsviewer/PageUpdateCallback.java" \
	"src/com/artifex/gsviewer/StdIO.java" \
	"src/com/artifex/gsviewer/GSFileFilter.java" \
	"src/com/artifex/gsviewer/Main.java" \
	"src/com/artifex/gsviewer/PDFFileFilter.java" \
	"src/com/artifex/gsviewer/ViewerController.java" \
	\
	"src/com/artifex/gsviewer/gui/ScrollMap.java" \
	"src/com/artifex/gsviewer/gui/SettingsDialog.java" \
	"src/com/artifex/gsviewer/gui/ViewerGUIListener.java" \
	"src/com/artifex/gsviewer/gui/ViewerWindow.java"

cd bin

echo "Packing gsviewer JAR file..."
jar cfm "../gsviewer.jar" "../Manifest.md" "com/"


echo "Copy gs_jni.dylib"
cp "../jni/gs_jni/gs_jni.dylib" "gs_jni.dylib"

echo "Create libgpdl.dylib link"
cp "../../../sobin/libgpdl.dylib" "libgpdl.dylib"

cd ../../../sobin

echo "Copy libgpdl.dylib target"
cp $(readlink "libgpdl.dylib") "../demos/java/gsviewer"

cd ../demos/java/gsviewer