Skip to content
This repository has been archived by the owner on Nov 14, 2024. It is now read-only.

Commit

Permalink
Merge pull request #29 from V-Sekai/debug
Browse files Browse the repository at this point in the history
Build debug symbols.
  • Loading branch information
fire authored Nov 6, 2024
2 parents 269ca17 + 0c6f1bb commit 155304b
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 9 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ jobs:
fail-fast: false
matrix:
precision: [double]
platform: [linux, windows, android, web]
platform: [linuxbsd, windows, android, web]
target: [editor, template_release, template_debug]

concurrency:
Expand Down
25 changes: 17 additions & 8 deletions Justfile
Original file line number Diff line number Diff line change
Expand Up @@ -143,18 +143,28 @@ build-platform-target platform target precision="double":
source "$EMSDK_ROOT/emsdk_env.sh"
cd godot
export EXTRA_FLAGS=""
case "{{platform}}" in \
macos) \
EXTRA_FLAGS="vulkan=yes arch=arm64 werror=no vulkan_sdk_path=$VULKAN_SDK_ROOT/MoltenVK/MoltenVK/static/MoltenVK.xcframework osxcross_sdk=darwin24 generate_bundle=yes"
case "{{platform}}" in
macos)
EXTRA_FLAGS=("vulkan=yes" "arch=arm64" "werror=no" "vulkan_sdk_path=$VULKAN_SDK_ROOT/MoltenVK/MoltenVK/static/MoltenVK.xcframework" "osxcross_sdk=darwin24" "generate_bundle=yes" "debug_symbol=yes")
if [ "$(uname)" = "Darwin" ]; then
unset OSXCROSS_ROOT
fi
;;
windows)
EXTRA_FLAGS=("use_llvm=yes" "use_mingw=yes" "linkflags=-Wl,-pdb=" "ccflags=-g -gcodeview" "debug_symbols=no")
;;
android)
EXTRA_FLAGS=("debug_symbol=yes")
;;
linuxbsd)
EXTRA_FLAGS=("debug_symbol=yes")
;;
web)
EXTRA_FLAGS="dlink_enabled=yes"
EXTRA_FLAGS=("dlink_enabled=yes" "debug_symbol=yes")
;;
*)
EXTRA_FLAGS="use_llvm=yes use_mingw=yes"
echo "Unsupported platform: {{platform}}"
exit 1
;;
esac
scons platform={{platform}} \
Expand All @@ -163,8 +173,7 @@ build-platform-target platform target precision="double":
precision={{precision}} \
target={{target}} \
test=yes \
debug_symbol=yes \
$EXTRA_FLAGS
"${EXTRA_FLAGS[@]}"
just handle-special-cases {{platform}} {{target}}
if [[ "{{target}}" == "editor" ]]; then
mkdir -p $WORLD_PWD/editors
Expand All @@ -177,7 +186,7 @@ build-platform-target platform target precision="double":
all-build-platform-target:
#!/usr/bin/env bash
parallel --ungroup --jobs 1 'just build-platform-target {1} {2}' \
::: windows linux macos android web \
::: windows linuxbsd macos android web \
::: editor template_debug template_release
handle-special-cases platform target:
Expand Down

0 comments on commit 155304b

Please sign in to comment.