Skip to content
This repository was archived by the owner on Sep 16, 2024. It is now read-only.

Commit 435f6db

Browse files
committed
Fix build.sh
1 parent 7d605fd commit 435f6db

File tree

1 file changed

+8
-6
lines changed

1 file changed

+8
-6
lines changed

Diff for: build.sh

+8-6
Original file line numberDiff line numberDiff line change
@@ -86,23 +86,27 @@ else
8686
mkdir -p out
8787
cd "out"
8888
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_C_COMPILER=/usr/bin/x86_64-linux-gnu-gcc -DCMAKE_CXX_COMPILER=/usr/bin/x86_64-linux-gnu-g++ ..
89-
make -j$(nproc)
89+
make "-j$(nproc)"
9090
cp libosintgram4j.so "$CURRENT_WORKDIR/out/project/input"
9191

92+
set +e
93+
9294
MINGW_C="$(command -v x86_64-w64-mingw32-gcc)"
9395
MINGW_CPP="$(command -v x86_64-w64-mingw32-g++)"
9496

9597
if [ -n "$MINGW_C" ] && [ -n "$MINGW_CPP" ]; then
96-
echo "* Compiling CXX code for Windows"
98+
echo "* Compiling CXX code for Windows x86_64"
9799

98100
cd "$CURRENT_WORKDIR/cxx"
99101
mkdir win
100102
cd win
101103
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_C_COMPILER="$MINGW_C" -DCMAKE_CXX_COMPILER="$MINGW_CPP" ..
102-
make -j$(nproc)
104+
make "-j$(nproc)"
103105
cp osintgram4j.dll "$CURRENT_WORKDIR/out/project/input"
104106
fi
105107

108+
set -e
109+
106110
cd "$CURRENT_WORKDIR"
107111
fi
108112

@@ -133,8 +137,6 @@ echo '## Making "modapi.jar"'
133137
echo '## Making "core.jar"'
134138
"$JAR_CMD" -cfm out/project/input/core.jar META-INF/MANIFEST.MF -C out/project/core .
135139

136-
## Minimal Java Runtime Removal: Modding will be limited, if not removed
137-
138140
echo '## Building the Application Package'
139141
cp out/libs/json.jar out/project/input/json.jar
140142
cp AppSettings.cfg out/project/input/AppSettings.cfg
@@ -168,7 +170,7 @@ if [[ "$INSTALL_CHOICE" =~ ^[Yy]$ ]]; then
168170
fi
169171
fi
170172

171-
echo "Copying built files"
173+
echo "> Copying built files"
172174
"$PREFIX" mkdir -p /usr/share/bc100dev/osintgram4j/
173175
"$PREFIX" cp -r out/pkg/osintgram4j/* /usr/share/bc100dev/osintgram4j
174176
"$PREFIX" ln -s /usr/share/bc100dev/osintgram4j/bin/osintgram4j /usr/bin/osintgram4j

0 commit comments

Comments
 (0)