Skip to content

Commit 0ef67e8

Browse files
authored
Merge pull request #2 from godotengine/classical-mono-optional
Refactor build scripts to allow building only Classical or Mono
2 parents 7b37680 + 067d3f3 commit 0ef67e8

File tree

12 files changed

+786
-568
lines changed

12 files changed

+786
-568
lines changed

build-android/build.sh

Lines changed: 51 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,11 @@
22

33
set -e
44

5+
# Config
6+
57
export BUILD_NAME=official
68
export SCONS="scons -j${NUM_CORES} verbose=yes warnings=no progress=no"
7-
export OPTIONS="builtin_libpng=yes builtin_openssl=yes builtin_zlib=yes debug_symbols=no use_static_cpp=yes use_lto=yes"
9+
export OPTIONS="debug_symbols=no"
810
export OPTIONS_MONO="module_mono_enabled=yes mono_static=no"
911
export TERM=xterm
1012

@@ -13,50 +15,64 @@ mkdir godot
1315
cd godot
1416
tar xf /root/godot.tar.gz --strip-components=1
1517

16-
cp /root/mono-glue/*.cpp modules/mono/glue/
17-
cp -r /root/mono-glue/Managed/Generated modules/mono/glue/Managed/
18+
# Classical
19+
20+
if [ "${CLASSICAL}" == "1" ]; then
21+
echo "Starting classical build for Android..."
22+
23+
$SCONS platform=android android_arch=armv7 $OPTIONS tools=no target=release_debug
24+
$SCONS platform=android android_arch=armv7 $OPTIONS tools=no target=release
25+
26+
$SCONS platform=android android_arch=arm64v8 $OPTIONS tools=no target=release_debug
27+
$SCONS platform=android android_arch=arm64v8 $OPTIONS tools=no target=release
28+
29+
$SCONS platform=android android_arch=x86 $OPTIONS tools=no target=release_debug
30+
$SCONS platform=android android_arch=x86 $OPTIONS tools=no target=release
31+
32+
$SCONS platform=android android_arch=x86_64 $OPTIONS tools=no target=release_debug
33+
$SCONS platform=android android_arch=x86_64 $OPTIONS tools=no target=release
1834

19-
$SCONS platform=android android_arch=armv7 $OPTIONS tools=no target=release_debug
20-
$SCONS platform=android android_arch=armv7 $OPTIONS tools=no target=release
35+
pushd platform/android/java
36+
./gradlew generateGodotTemplates
37+
popd
2138

22-
$SCONS platform=android android_arch=arm64v8 $OPTIONS tools=no target=release_debug
23-
$SCONS platform=android android_arch=arm64v8 $OPTIONS tools=no target=release
39+
mkdir -p /root/out/templates
40+
cp bin/android_source.zip /root/out/templates
41+
cp bin/android_debug.apk /root/out/templates/android_debug.apk
42+
cp bin/android_release.apk /root/out/templates/android_release.apk
43+
fi
2444

25-
$SCONS platform=android android_arch=x86 $OPTIONS tools=no target=release_debug
26-
$SCONS platform=android android_arch=x86 $OPTIONS tools=no target=release
45+
# Mono
2746

28-
$SCONS platform=android android_arch=x86_64 $OPTIONS tools=no target=release_debug
29-
$SCONS platform=android android_arch=x86_64 $OPTIONS tools=no target=release
47+
if [ "${MONO}" == "1" ]; then
48+
echo "Starting Mono build for Android..."
3049

31-
pushd platform/android/java
32-
./gradlew generateGodotTemplates
33-
popd
50+
cp /root/mono-glue/*.cpp modules/mono/glue/
51+
cp -r /root/mono-glue/Managed/Generated modules/mono/glue/Managed/
3452

35-
mkdir -p /root/out/templates
36-
cp bin/android_source.zip /root/out/templates
37-
cp bin/android_debug.apk /root/out/templates/android_debug.apk
38-
cp bin/android_release.apk /root/out/templates/android_release.apk
53+
$SCONS platform=android android_arch=armv7 $OPTIONS $OPTIONS_MONO mono_prefix=/root/mono-installs/android-armeabi-v7a-release tools=no target=release_debug
54+
$SCONS platform=android android_arch=armv7 $OPTIONS $OPTIONS_MONO mono_prefix=/root/mono-installs/android-armeabi-v7a-release tools=no target=release
3955

40-
$SCONS platform=android android_arch=armv7 $OPTIONS $OPTIONS_MONO mono_prefix=/root/mono-installs/android-armeabi-v7a-release tools=no target=release_debug
41-
$SCONS platform=android android_arch=armv7 $OPTIONS $OPTIONS_MONO mono_prefix=/root/mono-installs/android-armeabi-v7a-release tools=no target=release
56+
$SCONS platform=android android_arch=arm64v8 $OPTIONS $OPTIONS_MONO mono_prefix=/root/mono-installs/android-arm64-v8a-release tools=no target=release_debug
57+
$SCONS platform=android android_arch=arm64v8 $OPTIONS $OPTIONS_MONO mono_prefix=/root/mono-installs/android-arm64-v8a-release tools=no target=release
4258

43-
$SCONS platform=android android_arch=arm64v8 $OPTIONS $OPTIONS_MONO mono_prefix=/root/mono-installs/android-arm64-v8a-release tools=no target=release_debug
44-
$SCONS platform=android android_arch=arm64v8 $OPTIONS $OPTIONS_MONO mono_prefix=/root/mono-installs/android-arm64-v8a-release tools=no target=release
59+
$SCONS platform=android android_arch=x86 $OPTIONS $OPTIONS_MONO mono_prefix=/root/mono-installs/android-x86-release tools=no target=release_debug
60+
$SCONS platform=android android_arch=x86 $OPTIONS $OPTIONS_MONO mono_prefix=/root/mono-installs/android-x86-release tools=no target=release
4561

46-
$SCONS platform=android android_arch=x86 $OPTIONS $OPTIONS_MONO mono_prefix=/root/mono-installs/android-x86-release tools=no target=release_debug
47-
$SCONS platform=android android_arch=x86 $OPTIONS $OPTIONS_MONO mono_prefix=/root/mono-installs/android-x86-release tools=no target=release
62+
$SCONS platform=android android_arch=x86_64 $OPTIONS $OPTIONS_MONO mono_prefix=/root/mono-installs/android-x86_64-release tools=no target=release_debug
63+
$SCONS platform=android android_arch=x86_64 $OPTIONS $OPTIONS_MONO mono_prefix=/root/mono-installs/android-x86_64-release tools=no target=release
4864

49-
$SCONS platform=android android_arch=x86_64 $OPTIONS $OPTIONS_MONO mono_prefix=/root/mono-installs/android-x86_64-release tools=no target=release_debug
50-
$SCONS platform=android android_arch=x86_64 $OPTIONS $OPTIONS_MONO mono_prefix=/root/mono-installs/android-x86_64-release tools=no target=release
65+
pushd platform/android/java
66+
./gradlew generateGodotTemplates
67+
popd
5168

52-
pushd platform/android/java
53-
./gradlew generateGodotTemplates
54-
popd
69+
mkdir -p /root/out/templates-mono
70+
cp bin/android_source.zip /root/out/templates-mono
71+
cp bin/android_debug.apk /root/out/templates-mono/android_debug.apk
72+
cp bin/android_release.apk /root/out/templates-mono/android_release.apk
5573

56-
mkdir -p /root/out/templates-mono
57-
cp bin/android_source.zip /root/out/templates-mono
58-
cp bin/android_debug.apk /root/out/templates-mono/android_debug.apk
59-
cp bin/android_release.apk /root/out/templates-mono/android_release.apk
74+
mkdir /root/out/templates-mono/bcl
75+
cp -r /root/mono-installs/android-bcl/monodroid /root/out/templates-mono/bcl/
76+
fi
6077

61-
mkdir /root/out/templates-mono/bcl
62-
cp -r /root/mono-installs/android-bcl/monodroid /root/out/templates-mono/bcl/
78+
echo "Android build successful"

build-ios/build.sh

Lines changed: 27 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,12 @@
22

33
set -e
44

5+
# Config
6+
57
export BUILD_NAME=official
68
export SCONS="scons -j${NUM_CORES} verbose=yes warnings=no progress=no"
79
export IOS_SDK="12.4"
8-
export OPTIONS="osxcross_sdk=darwin18 builtin_libpng=yes builtin_openssl=yes builtin_zlib=yes debug_symbols=no use_static_cpp=yes"
10+
export OPTIONS="osxcross_sdk=darwin18 debug_symbols=no"
911
export OPTIONS_MONO="module_mono_enabled=yes mono_static=yes"
1012
export TERM=xterm
1113
export OSXCROSS_IOS=not_nothing
@@ -15,19 +17,33 @@ mkdir godot
1517
cd godot
1618
tar xf /root/godot.tar.gz --strip-components=1
1719

18-
$SCONS platform=iphone $OPTIONS arch=arm64 tools=no target=release_debug IPHONESDK="/root/ioscross/arm64/SDK/iPhoneOS${IOS_SDK}.sdk" IPHONEPATH="/root/ioscross/arm64/" ios_triple="arm-apple-darwin11-"
19-
$SCONS platform=iphone $OPTIONS arch=arm64 tools=no target=release IPHONESDK="/root/ioscross/arm64/SDK/iPhoneOS${IOS_SDK}.sdk" IPHONEPATH="/root/ioscross/arm64/" ios_triple="arm-apple-darwin11-"
20+
# Classical
21+
22+
if [ "${CLASSICAL}" == "1" ]; then
23+
echo "Starting classical build for iOS..."
24+
25+
$SCONS platform=iphone $OPTIONS arch=arm64 tools=no target=release_debug IPHONESDK="/root/ioscross/arm64/SDK/iPhoneOS${IOS_SDK}.sdk" IPHONEPATH="/root/ioscross/arm64/" ios_triple="arm-apple-darwin11-"
26+
$SCONS platform=iphone $OPTIONS arch=arm64 tools=no target=release IPHONESDK="/root/ioscross/arm64/SDK/iPhoneOS${IOS_SDK}.sdk" IPHONEPATH="/root/ioscross/arm64/" ios_triple="arm-apple-darwin11-"
27+
28+
$SCONS platform=iphone $OPTIONS arch=x86_64 tools=no target=release_debug IPHONESDK="/root/ioscross/x86_64/SDK/iPhoneOS${IOS_SDK}.sdk" IPHONEPATH="/root/ioscross/x86_64/" ios_triple="x86_64-apple-darwin11-"
29+
$SCONS platform=iphone $OPTIONS arch=x86_64 tools=no target=release IPHONESDK="/root/ioscross/x86_64/SDK/iPhoneOS${IOS_SDK}.sdk" IPHONEPATH="/root/ioscross/x86_64/" ios_triple="x86_64-apple-darwin11-"
30+
31+
/root/ioscross/arm64/bin/arm-apple-darwin11-lipo -create bin/libgodot.iphone.opt.arm64.a bin/libgodot.iphone.opt.x86_64.a -output /root/out/libgodot.iphone.opt.fat
32+
/root/ioscross/arm64/bin/arm-apple-darwin11-lipo -create bin/libgodot.iphone.opt.debug.arm64.a bin/libgodot.iphone.opt.debug.x86_64.a -output /root/out/libgodot.iphone.opt.debug.fat
2033

21-
$SCONS platform=iphone $OPTIONS arch=x86_64 tools=no target=release_debug IPHONESDK="/root/ioscross/x86_64/SDK/iPhoneOS${IOS_SDK}.sdk" IPHONEPATH="/root/ioscross/x86_64/" ios_triple="x86_64-apple-darwin11-"
22-
$SCONS platform=iphone $OPTIONS arch=x86_64 tools=no target=release IPHONESDK="/root/ioscross/x86_64/SDK/iPhoneOS${IOS_SDK}.sdk" IPHONEPATH="/root/ioscross/x86_64/" ios_triple="x86_64-apple-darwin11-"
34+
/root/ioscross/arm64/bin/arm-apple-darwin11-lipo -create bin/libgodot_arkit_module.iphone.opt.arm64.a bin/libgodot_arkit_module.iphone.opt.x86_64.a -output /root/out/libgodot_arkit_module.iphone.opt.fat
35+
/root/ioscross/arm64/bin/arm-apple-darwin11-lipo -create bin/libgodot_arkit_module.iphone.opt.debug.arm64.a bin/libgodot_arkit_module.iphone.opt.debug.x86_64.a -output /root/out/libgodot_arkit_module.iphone.opt.debug.fat
2336

24-
/root/ioscross/arm64/bin/arm-apple-darwin11-lipo -create bin/libgodot.iphone.opt.arm64.a bin/libgodot.iphone.opt.x86_64.a -output /root/out/libgodot.iphone.opt.fat
25-
/root/ioscross/arm64/bin/arm-apple-darwin11-lipo -create bin/libgodot.iphone.opt.debug.arm64.a bin/libgodot.iphone.opt.debug.x86_64.a -output /root/out/libgodot.iphone.opt.debug.fat
37+
/root/ioscross/arm64/bin/arm-apple-darwin11-lipo -create bin/libgodot_camera_module.iphone.opt.arm64.a bin/libgodot_camera_module.iphone.opt.x86_64.a -output /root/out/libgodot_camera_module.iphone.opt.fat
38+
/root/ioscross/arm64/bin/arm-apple-darwin11-lipo -create bin/libgodot_camera_module.iphone.opt.debug.arm64.a bin/libgodot_camera_module.iphone.opt.debug.x86_64.a -output /root/out/libgodot_camera_module.iphone.opt.debug.fat
39+
fi
2640

27-
/root/ioscross/arm64/bin/arm-apple-darwin11-lipo -create bin/libgodot_arkit_module.iphone.opt.arm64.a bin/libgodot_arkit_module.iphone.opt.x86_64.a -output /root/out/libgodot_arkit_module.iphone.opt.fat
28-
/root/ioscross/arm64/bin/arm-apple-darwin11-lipo -create bin/libgodot_arkit_module.iphone.opt.debug.arm64.a bin/libgodot_arkit_module.iphone.opt.debug.x86_64.a -output /root/out/libgodot_arkit_module.iphone.opt.debug.fat
41+
# Mono
2942

30-
/root/ioscross/arm64/bin/arm-apple-darwin11-lipo -create bin/libgodot_camera_module.iphone.opt.arm64.a bin/libgodot_camera_module.iphone.opt.x86_64.a -output /root/out/libgodot_camera_module.iphone.opt.fat
31-
/root/ioscross/arm64/bin/arm-apple-darwin11-lipo -create bin/libgodot_camera_module.iphone.opt.debug.arm64.a bin/libgodot_camera_module.iphone.opt.debug.x86_64.a -output /root/out/libgodot_camera_module.iphone.opt.debug.fat
43+
if [ "${MONO}" == "1" ]; then
44+
echo "No Mono support for iOS yet."
45+
#cp /root/mono-glue/*.cpp modules/mono/glue/
46+
#cp -r /root/mono-glue/Managed/Generated modules/mono/glue/Managed/
47+
fi
3248

3349
echo "iOS build successful"

build-javascript/build.sh

Lines changed: 31 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -2,35 +2,49 @@
22

33
set -e
44

5+
# Config
6+
57
export BUILD_NAME=official
68
export SCONS="scons -j${NUM_CORES} verbose=yes warnings=no progress=no"
7-
export OPTIONS="builtin_libpng=yes builtin_openssl=yes builtin_zlib=yes debug_symbols=no use_static_cpp=yes use_lto=yes"
9+
export OPTIONS="debug_symbols=no"
810
export OPTIONS_MONO="module_mono_enabled=yes mono_static=yes mono_prefix=/root/mono-installs/wasm-runtime-release"
911
export TERM=xterm
1012

11-
source /root/emsdk/emsdk_env.sh
12-
1313
rm -rf godot
1414
mkdir godot
1515
cd godot
1616
tar xf /root/godot.tar.gz --strip-components=1
1717

18-
cp /root/mono-glue/*.cpp modules/mono/glue/
19-
cp -r /root/mono-glue/Managed/Generated modules/mono/glue/Managed/
18+
# Classical
19+
20+
if [ "${CLASSICAL}" == "1" ]; then
21+
echo "Starting classical build for JavaScript..."
22+
23+
$SCONS platform=javascript ${OPTIONS} target=release_debug tools=no
24+
$SCONS platform=javascript ${OPTIONS} target=release tools=no
25+
26+
mkdir -p /root/out/templates
27+
cp -rvp bin/*.zip /root/out/templates
28+
rm -f bin/*.zip
29+
fi
30+
31+
# Mono
32+
33+
if [ "${MONO}" == "1" ]; then
34+
echo "Starting Mono build for JavaScript..."
2035

21-
$SCONS platform=javascript ${OPTIONS} target=release_debug tools=no
22-
$SCONS platform=javascript ${OPTIONS} target=release tools=no
36+
cp /root/mono-glue/*.cpp modules/mono/glue/
37+
cp -r /root/mono-glue/Managed/Generated modules/mono/glue/Managed/
2338

24-
mkdir -p /root/out/templates
25-
cp -rvp bin/*.zip /root/out/templates
26-
rm -f bin/*.zip
39+
$SCONS platform=javascript ${OPTIONS} ${OPTIONS_MONO} target=release_debug tools=no
40+
$SCONS platform=javascript ${OPTIONS} ${OPTIONS_MONO} target=release tools=no
2741

28-
$SCONS platform=javascript ${OPTIONS} ${OPTIONS_MONO} target=release_debug tools=no
29-
$SCONS platform=javascript ${OPTIONS} ${OPTIONS_MONO} target=release tools=no
42+
mkdir -p /root/out/templates-mono
43+
cp -rvp bin/*.zip /root/out/templates-mono
44+
rm -f bin/*.zip
3045

31-
mkdir -p /root/out/templates-mono
32-
cp -rvp bin/*.zip /root/out/templates-mono
33-
rm -f bin/*.zip
46+
mkdir -p /root/out/templates-mono/bcl
47+
cp -r /root/mono-installs/wasm-bcl/wasm /root/out/templates-mono/bcl/
48+
fi
3449

35-
mkdir -p /root/out/templates-mono/bcl
36-
cp -r /root/mono-installs/wasm-bcl/wasm /root/out/templates-mono/bcl/
50+
echo "JavaScript build successful"

build-linux/build.sh

Lines changed: 36 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,11 @@
22

33
set -e
44

5+
# Config
6+
57
export BUILD_NAME=official
68
export SCONS="scons -j${NUM_CORES} verbose=yes warnings=no progress=no"
7-
export OPTIONS="builtin_libpng=yes builtin_openssl=yes builtin_zlib=yes debug_symbols=no use_static_cpp=yes use_lto=yes"
9+
export OPTIONS="debug_symbols=no use_static_cpp=yes use_lto=yes"
810
export OPTIONS_MONO="module_mono_enabled=yes mono_static=yes"
911
export TERM=xterm
1012
export CC="gcc-8"
@@ -15,30 +17,42 @@ mkdir godot
1517
cd godot
1618
tar xf /root/godot.tar.gz --strip-components=1
1719

18-
cp /root/mono-glue/*.cpp modules/mono/glue/
19-
cp -r /root/mono-glue/Managed/Generated modules/mono/glue/Managed/
20+
# Classical
21+
22+
if [ "${CLASSICAL}" == "1" ]; then
23+
echo "Starting classical build for Linux..."
24+
25+
$SCONS platform=x11 CC=$CC CXX=$CXX $OPTIONS tools=yes target=release_debug
26+
mkdir -p /root/out/tools
27+
cp -rvp bin/* /root/out/tools
28+
rm -rf bin
29+
30+
$SCONS platform=x11 CC=$CC CXX=$CXX $OPTIONS tools=no target=release_debug
31+
$SCONS platform=x11 CC=$CC CXX=$CXX $OPTIONS tools=no target=release
32+
mkdir -p /root/out/templates
33+
cp -rvp bin/* /root/out/templates
34+
rm -rf bin
35+
fi
2036

21-
$SCONS platform=x11 CC=$CC CXX=$CXX $OPTIONS tools=yes target=release_debug
22-
mkdir -p /root/out/tools
23-
cp -rvp bin/* /root/out/tools
24-
rm -rf bin
37+
# Mono
2538

26-
$SCONS platform=x11 CC=$CC CXX=$CXX $OPTIONS tools=no target=release_debug
27-
$SCONS platform=x11 CC=$CC CXX=$CXX $OPTIONS tools=no target=release
28-
mkdir -p /root/out/templates
29-
cp -rvp bin/* /root/out/templates
30-
rm -rf bin
39+
if [ "${MONO}" == "1" ]; then
40+
echo "Starting Mono build for Linux..."
3141

32-
export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/usr/lib/pkgconfig/
42+
cp /root/mono-glue/*.cpp modules/mono/glue/
43+
cp -r /root/mono-glue/Managed/Generated modules/mono/glue/Managed/
44+
export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/usr/lib/pkgconfig/
3345

34-
$SCONS platform=x11 CC=$CC CXX=$CXX $OPTIONS $OPTIONS_MONO tools=yes target=release_debug copy_mono_root=yes
35-
mkdir -p /root/out/tools-mono
36-
cp -rvp bin/* /root/out/tools-mono
37-
rm -rf bin
46+
$SCONS platform=x11 CC=$CC CXX=$CXX $OPTIONS $OPTIONS_MONO tools=yes target=release_debug copy_mono_root=yes
47+
mkdir -p /root/out/tools-mono
48+
cp -rvp bin/* /root/out/tools-mono
49+
rm -rf bin
3850

39-
$SCONS platform=x11 CC=$CC CXX=$CXX $OPTIONS $OPTIONS_MONO tools=no target=release_debug
40-
$SCONS platform=x11 CC=$CC CXX=$CXX $OPTIONS $OPTIONS_MONO tools=no target=release
41-
mkdir -p /root/out/templates-mono
42-
cp -rvp bin/* /root/out/templates-mono
43-
rm -rf bin
51+
$SCONS platform=x11 CC=$CC CXX=$CXX $OPTIONS $OPTIONS_MONO tools=no target=release_debug
52+
$SCONS platform=x11 CC=$CC CXX=$CXX $OPTIONS $OPTIONS_MONO tools=no target=release
53+
mkdir -p /root/out/templates-mono
54+
cp -rvp bin/* /root/out/templates-mono
55+
rm -rf bin
56+
fi
4457

58+
echo "Linux build successful"

build-macosx/build.sh

Lines changed: 37 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,11 @@
22

33
set -e
44

5+
# Config
6+
57
export BUILD_NAME=official
68
export SCONS="scons -j${NUM_CORES} verbose=yes warnings=no progress=no"
7-
export OPTIONS="osxcross_sdk=darwin18 builtin_libpng=yes builtin_openssl=yes builtin_zlib=yes debug_symbols=no use_static_cpp=yes use_lto=yes"
9+
export OPTIONS="osxcross_sdk=darwin18 debug_symbols=no"
810
export OPTIONS_MONO="module_mono_enabled=yes mono_static=yes mono_prefix=/root/dependencies/mono"
911
export TERM=xterm
1012

@@ -13,35 +15,47 @@ mkdir godot
1315
cd godot
1416
tar xf /root/godot.tar.gz --strip-components=1
1517

16-
cp /root/mono-glue/*.cpp modules/mono/glue/
17-
cp -r /root/mono-glue/Managed/Generated modules/mono/glue/Managed/
18+
# Classical
19+
20+
if [ "${CLASSICAL}" == "1" ]; then
21+
echo "Starting classical build for macOS..."
22+
23+
$SCONS platform=osx $OPTIONS tools=yes target=release_debug
24+
25+
mkdir -p /root/out/tools
26+
cp -rvp bin/* /root/out/tools
27+
rm -rf bin
28+
29+
$SCONS platform=osx $OPTIONS tools=no target=release_debug
30+
$SCONS platform=osx $OPTIONS tools=no target=release
1831

19-
$SCONS platform=osx $OPTIONS tools=yes target=release_debug
32+
mkdir -p /root/out/templates
33+
cp -rvp bin/* /root/out/templates
34+
rm -rf bin
35+
fi
2036

21-
mkdir -p /root/out/tools
22-
cp -rvp bin/* /root/out/tools
23-
rm -rf bin
37+
# Mono
2438

25-
$SCONS platform=osx $OPTIONS tools=no target=release_debug
26-
$SCONS platform=osx $OPTIONS tools=no target=release
39+
if [ "${MONO}" == "1" ]; then
40+
echo "Starting Mono build for macOS..."
2741

28-
mkdir -p /root/out/templates
29-
cp -rvp bin/* /root/out/templates
30-
rm -rf bin
42+
cp /root/mono-glue/*.cpp modules/mono/glue/
43+
cp -r /root/mono-glue/Managed/Generated modules/mono/glue/Managed/
3144

32-
$SCONS platform=osx $OPTIONS $OPTIONS_MONO tools=yes target=release_debug copy_mono_root=yes
45+
$SCONS platform=osx $OPTIONS $OPTIONS_MONO tools=yes target=release_debug copy_mono_root=yes
3346

34-
mkdir -p /root/out/tools-mono
35-
cp -rvp bin/* /root/out/tools-mono
36-
rm -rf bin
47+
mkdir -p /root/out/tools-mono
48+
cp -rvp bin/* /root/out/tools-mono
49+
rm -rf bin
3750

38-
$SCONS platform=osx $OPTIONS $OPTIONS_MONO tools=no target=release_debug
39-
$SCONS platform=osx $OPTIONS $OPTIONS_MONO tools=no target=release
51+
$SCONS platform=osx $OPTIONS $OPTIONS_MONO tools=no target=release_debug
52+
$SCONS platform=osx $OPTIONS $OPTIONS_MONO tools=no target=release
4053

41-
mkdir -p /root/out/templates-mono
42-
cp -rvp bin/* /root/out/templates-mono
43-
rm -rf bin
54+
mkdir -p /root/out/templates-mono
55+
cp -rvp bin/* /root/out/templates-mono
56+
rm -rf bin
4457

45-
find /root/out -name config -exec cp /root/dependencies/mono/etc/config {} \;
58+
find /root/out -name config -exec cp /root/dependencies/mono/etc/config {} \;
59+
fi
4660

47-
echo "MacOS build successful"
61+
echo "macOS build successful"

0 commit comments

Comments
 (0)