forked from juce-framework/JUCE
-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathBuildProjucer.sh
More file actions
executable file
·52 lines (39 loc) · 1.12 KB
/
BuildProjucer.sh
File metadata and controls
executable file
·52 lines (39 loc) · 1.12 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
#!/bin/sh
unameOut="$(uname -s)"
case "${unameOut}" in
Linux*) machine=Linux;;
Darwin*) machine=Mac;;
CYGWIN*) machine=Cygwin;;
MINGW*) machine=MinGw;;
*) machine="UNKNOWN:${unameOut}"
esac
currentos=${machine}
BASEDIR=$(dirname "$0")
APPNAME="Projucer"
PROJUCER_DIR="$BASEDIR/extras/$APPNAME"
FRUT_PATH="$BASEDIR/../FRUT/prefix/FRUT"
JUCERPROJ="$PROJUCER_DIR/$APPNAME.jucer"
BUILD_DIR="$PROJUCER_DIR/cmakebuild"
"$FRUT_PATH/../../Build.sh"
cd "$PROJUCER_DIR"
"$FRUT_PATH/bin/Jucer2CMake" reprojucer "$JUCERPROJ" "$FRUT_PATH/cmake/Reprojucer.cmake"
if [ ! -d "$BUILD_DIR" ]; then
mkdir "$BUILD_DIR"
fi
cd "$BUILD_DIR"
if [ $currentos = MinGw ]; then
cmake .. -G "Visual Studio 17 2022"
elif [ $currentos = Linux ]; then
cmake .. -G "Unix Makefiles"
else
cmake .. -G "Xcode" -DCMAKE_OSX_ARCHITECTURES="arm64;x86_64"
fi
cmake --build . --config "Release" --parallel 8
if [ $currentos = MinGw ]; then
BUILD="$BUILD_DIR/Release/App/Projucer.exe"
elif [ $currentos = Mac ]; then
BUILD="$BUILD_DIR/Release/Projucer.app"
elif [ $currentos = Linux ]; then
BUILD="$BUILD_DIR/Projucer"
fi
"$BUILD"