Skip to content

Instantly share code, notes, and snippets.

@Calinou
Last active November 11, 2023 18:52
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Calinou/d3b327516fa11d424bc6cac625ac9c10 to your computer and use it in GitHub Desktop.
Save Calinou/d3b327516fa11d424bc6cac625ac9c10 to your computer and use it in GitHub Desktop.
Update, build and install Godot from source on Linux
#!/usr/bin/env bash
set -euo pipefail
IFS=$'\n\t'
SCONS_FLAGS=(
"lto=full"
"progress=no"
"debug_symbols=no"
)
cd "$HOME/Documents/Git/godotengine/godot-3.x/"
git pull
scons target=release_debug "${SCONS_FLAGS[@]}" || true
strip "bin/godot.x11.opt.tools.64" || true
cp "bin/godot.x11.opt.tools.64" "$HOME/.local/bin/godot-3.3" || true
scons tools=no target=release_debug "${SCONS_FLAGS[@]}" || true
strip "bin/godot.x11.opt.debug.64" || true
cp "bin/godot.x11.opt.debug.64" "$HOME/.local/bin/godot-runner-debug-3.3" || true
scons tools=no target=release "${SCONS_FLAGS[@]}" || true
strip "bin/godot.x11.opt.64" || true
cp "bin/godot.x11.opt.64" "$HOME/.local/bin/godot-runner-3.3" || true
#scons platform=server target=release_debug "${SCONS_FLAGS[@]}" || true
#strip "bin/godot_server.x11.opt.tools.64" || true
#cp "bin/godot_server.x11.opt.tools.64" "$HOME/.local/bin/godot-headless-3.3" || true
#scons platform=server tools=no target=release "${SCONS_FLAGS[@]}" || true
#strip "bin/godot_server.x11.opt.64" || true
#cp "bin/godot_server.x11.opt.64" "$HOME/.local/bin/godot-server-3.3" || true
#!/usr/bin/env bash
set -euo pipefail
IFS=$'\n\t'
SCONS_FLAGS=(
"lto=none"
"optimize=speed"
"progress=no"
"debug_symbols=yes"
)
cd "$HOME/Documents/Git/godotengine/godot"
git pull
scons target=editor "${SCONS_FLAGS[@]}" || true
#strip "bin/godot.linuxbsd.editor.x86_64" || true
cp "bin/godot.linuxbsd.editor.x86_64" "$HOME/.local/bin/godot" || true
scons target=template_debug "${SCONS_FLAGS[@]}" || true
#strip "bin/godot.linuxbsd.template_debug.x86_64" || true
cp "bin/godot.linuxbsd.template_debug.x86_64" "$HOME/.local/bin/godot-runner-debug" || true
scons target=template_release "${SCONS_FLAGS[@]}" || true
#strip "bin/godot.linuxbsd.template_release.x86_64" || true
cp "bin/godot.linuxbsd.template_release.x86_64" "$HOME/.local/bin/godot-runner" || true
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment