Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ angle/
deps/
git/
mono-glue/
godot*.tar.gz
redot*.tar.gz
angle.7z

# Output
Expand Down
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Godot in-container build scripts
# Redot in-container build scripts

Build scripts used for official Godot Engine releases using containers
built from https://github.com/godotengine/build-containers
Build scripts used for official Redot Engine releases using containers
built from https://github.com/Redot-Engine/build-containers

## Disclaimer

Expand All @@ -14,18 +14,18 @@ this in a simple and user-friendly interface.

## Usage

- Build containers using https://github.com/godotengine/build-containers
- Build containers using https://github.com/Redot-Engine/build-containers
- Copy `config.sh.in` as `config.sh` and configure it as you want.
- Edit `build.sh` to properly reference those containers if local, or
use `config.sh` to point to your own registry if you uploaded
containers.
- Build with `build.sh` (check `--help` for usage).
- Package binaries with `build-release.sh` (check `--help` for usage).

Example that builds Godot 3.2-stable Classical (not Mono):
Example that builds Redot 4.3-stable Classical (not Mono):
```
./build.sh -v 3.2-stable -g 3.2-stable -b classical
./build-release.sh -v 3.2-stable -t 3.2.stable -b classical
./build.sh -v 4.3-stable -g 4.3-stable -b classical
./build-release.sh -v 4.3-stable -t 4.3.stable -b classical
```

Again, this is intended for release managers and usability is not the
Expand Down
14 changes: 7 additions & 7 deletions build-android/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ export OPTIONS="production=yes"
export OPTIONS_MONO="module_mono_enabled=yes"
export TERM=xterm

rm -rf godot
mkdir godot
cd godot
tar xf /root/godot.tar.gz --strip-components=1
rm -rf redot
mkdir redot
cd redot
tar xf /root/redot.tar.gz --strip-components=1

# Environment variables and keystore needed for signing store editor build,
# as well as signing and publishing to MavenCentral.
Expand Down Expand Up @@ -57,8 +57,8 @@ if [ "${CLASSICAL}" == "1" ]; then

# Restart from a clean tarball, as we'll copy all the contents
# outside the container for the MavenCentral upload.
rm -rf /root/godot/*
tar xf /root/godot.tar.gz --strip-components=1
rm -rf /root/redot/*
tar xf /root/redot.tar.gz --strip-components=1

$SCONS platform=android arch=arm32 $OPTIONS target=template_debug
$SCONS platform=android arch=arm32 $OPTIONS target=template_release
Expand All @@ -78,7 +78,7 @@ if [ "${CLASSICAL}" == "1" ]; then
if [ "$store_release" == "yes" ]; then
# Copy source folder with compiled libs so we can optionally use it
# in a separate script to upload the templates to MavenCentral.
cp -r /root/godot /root/out/source/
cp -r /root/redot /root/out/source/
# Backup ~/.gradle too so we can reuse all the downloaded stuff.
cp -r /root/.gradle /root/out/source/.gradle
fi
Expand Down
8 changes: 4 additions & 4 deletions build-android/upload-mavencentral.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ source ${basedir}/deps/keystore/config.sh

# Release the Godot Android library to MavenCentral
${PODMAN} run -it --rm \
-v ${basedir}/out/android/source:/root/godot -v ${basedir}/deps/keystore:/root/keystore \
localhost/godot-android:${IMAGE_VERSION} bash -c \
-v ${basedir}/out/android/source:/root/redot -v ${basedir}/deps/keystore:/root/keystore \
localhost/redot-android:${IMAGE_VERSION} bash -c \
"source /root/keystore/config.sh && \
cp -r /root/godot/.gradle /root && \
cd /root/godot/platform/android/java && \
cp -r /root/redot/.gradle /root && \
cd /root/redot/platform/android/java && \
./gradlew publishTemplateReleasePublicationToSonatypeRepository --max-workers 1 closeAndReleaseSonatypeStagingRepository"
8 changes: 4 additions & 4 deletions build-ios/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@ export TERM=xterm
export IOS_SDK="17.5"
export IOS_LIPO="/root/ioscross/arm64/bin/arm-apple-darwin11-lipo"

rm -rf godot
mkdir godot
cd godot
tar xf /root/godot.tar.gz --strip-components=1
rm -rf redot
mkdir redot
cd redot
tar xf /root/redot.tar.gz --strip-components=1

# Classical

Expand Down
8 changes: 4 additions & 4 deletions build-linux/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ export OPTIONS="production=yes"
export OPTIONS_MONO="module_mono_enabled=yes"
export TERM=xterm

rm -rf godot
mkdir godot
cd godot
tar xf /root/godot.tar.gz --strip-components=1
rm -rf redot
mkdir redot
cd redot
tar xf /root/redot.tar.gz --strip-components=1

# Classical

Expand Down
20 changes: 10 additions & 10 deletions build-macos/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ export OPTIONS="osxcross_sdk=darwin23.6 production=yes use_volk=no vulkan_sdk_pa
export OPTIONS_MONO="module_mono_enabled=yes"
export TERM=xterm

rm -rf godot
mkdir godot
cd godot
tar xf /root/godot.tar.gz --strip-components=1
rm -rf redot
mkdir redot
cd redot
tar xf /root/redot.tar.gz --strip-components=1

# Classical

Expand All @@ -21,18 +21,18 @@ if [ "${CLASSICAL}" == "1" ]; then

$SCONS platform=macos $OPTIONS arch=x86_64 target=editor
$SCONS platform=macos $OPTIONS arch=arm64 target=editor
lipo -create bin/godot.macos.editor.x86_64 bin/godot.macos.editor.arm64 -output bin/godot.macos.editor.universal
lipo -create bin/redot.macos.editor.x86_64 bin/redot.macos.editor.arm64 -output bin/redot.macos.editor.universal

mkdir -p /root/out/tools
cp -rvp bin/* /root/out/tools
rm -rf bin

$SCONS platform=macos $OPTIONS arch=x86_64 target=template_debug
$SCONS platform=macos $OPTIONS arch=arm64 target=template_debug
lipo -create bin/godot.macos.template_debug.x86_64 bin/godot.macos.template_debug.arm64 -output bin/godot.macos.template_debug.universal
lipo -create bin/redot.macos.template_debug.x86_64 bin/redot.macos.template_debug.arm64 -output bin/redot.macos.template_debug.universal
$SCONS platform=macos $OPTIONS arch=x86_64 target=template_release
$SCONS platform=macos $OPTIONS arch=arm64 target=template_release
lipo -create bin/godot.macos.template_release.x86_64 bin/godot.macos.template_release.arm64 -output bin/godot.macos.template_release.universal
lipo -create bin/redot.macos.template_release.x86_64 bin/redot.macos.template_release.arm64 -output bin/redot.macos.template_release.universal

mkdir -p /root/out/templates
cp -rvp bin/* /root/out/templates
Expand All @@ -49,7 +49,7 @@ if [ "${MONO}" == "1" ]; then

$SCONS platform=macos $OPTIONS $OPTIONS_MONO arch=x86_64 target=editor
$SCONS platform=macos $OPTIONS $OPTIONS_MONO arch=arm64 target=editor
lipo -create bin/godot.macos.editor.x86_64.mono bin/godot.macos.editor.arm64.mono -output bin/godot.macos.editor.universal.mono
lipo -create bin/redot.macos.editor.x86_64.mono bin/redot.macos.editor.arm64.mono -output bin/redot.macos.editor.universal.mono
./modules/mono/build_scripts/build_assemblies.py --godot-output-dir=./bin --godot-platform=macos

mkdir -p /root/out/tools-mono
Expand All @@ -58,10 +58,10 @@ if [ "${MONO}" == "1" ]; then

$SCONS platform=macos $OPTIONS $OPTIONS_MONO arch=x86_64 target=template_debug
$SCONS platform=macos $OPTIONS $OPTIONS_MONO arch=arm64 target=template_debug
lipo -create bin/godot.macos.template_debug.x86_64.mono bin/godot.macos.template_debug.arm64.mono -output bin/godot.macos.template_debug.universal.mono
lipo -create bin/redot.macos.template_debug.x86_64.mono bin/redot.macos.template_debug.arm64.mono -output bin/redot.macos.template_debug.universal.mono
$SCONS platform=macos $OPTIONS $OPTIONS_MONO arch=x86_64 target=template_release
$SCONS platform=macos $OPTIONS $OPTIONS_MONO arch=arm64 target=template_release
lipo -create bin/godot.macos.template_release.x86_64.mono bin/godot.macos.template_release.arm64.mono -output bin/godot.macos.template_release.universal.mono
lipo -create bin/redot.macos.template_release.x86_64.mono bin/redot.macos.template_release.arm64.mono -output bin/redot.macos.template_release.universal.mono

mkdir -p /root/out/templates-mono
cp -rvp bin/* /root/out/templates-mono
Expand Down
10 changes: 5 additions & 5 deletions build-mono-glue/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@ export TERM=xterm
export DISPLAY=:0
export PATH="${GODOT_SDK_LINUX_X86_64}/bin:${BASE_PATH}"

rm -rf godot
mkdir godot
cd godot
tar xf ../godot.tar.gz --strip-components=1
rm -rf redot
mkdir redot
cd redot
tar xf ../redot.tar.gz --strip-components=1

# Mono

Expand All @@ -25,7 +25,7 @@ if [ "${MONO}" == "1" ]; then
${SCONS} platform=linuxbsd ${OPTIONS} target=editor module_mono_enabled=yes

rm -rf /root/mono-glue/*
bin/godot.linuxbsd.editor.x86_64.mono --headless --generate-mono-glue /root/mono-glue
bin/redot.linuxbsd.editor.x86_64.mono --headless --generate-mono-glue /root/mono-glue
fi

echo "Mono glue generated successfully"
Loading