Skip to content

Commit d7625ee

Browse files
author
SirStig
committed
Bump project version and update Godot bridge build process
- Increment build number to 366. - Update bridge minimum macOS platform to v14. - Explicitly name the local NovaSwift package dependency. - Import Foundation in NovaWorld. - Copy SwiftGodot binary to the Godot output directory for runtime loading.
1 parent efc9193 commit d7625ee

4 files changed

Lines changed: 26 additions & 4 deletions

File tree

app/NovaSwift.xcodeproj/project.pbxproj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,7 @@
262262
ASSETCATALOG_COMPILER_INCLUDE_ALL_APPICON_ASSETS = YES;
263263
CODE_SIGN_ENTITLEMENTS = NovaSwift/NovaSwift.entitlements;
264264
CODE_SIGN_STYLE = Automatic;
265-
CURRENT_PROJECT_VERSION = 365;
265+
CURRENT_PROJECT_VERSION = 366;
266266
DEAD_CODE_STRIPPING = YES;
267267
ENABLE_APP_SANDBOX = YES;
268268
ENABLE_INCOMING_NETWORK_CONNECTIONS = NO;
@@ -320,7 +320,7 @@
320320
ASSETCATALOG_COMPILER_INCLUDE_ALL_APPICON_ASSETS = YES;
321321
CODE_SIGN_ENTITLEMENTS = NovaSwift/NovaSwift.entitlements;
322322
CODE_SIGN_STYLE = Automatic;
323-
CURRENT_PROJECT_VERSION = 365;
323+
CURRENT_PROJECT_VERSION = 366;
324324
DEAD_CODE_STRIPPING = YES;
325325
ENABLE_APP_SANDBOX = YES;
326326
ENABLE_INCOMING_NETWORK_CONNECTIONS = NO;

godot/bridge/Package.swift

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,14 +15,19 @@ import PackageDescription
1515
let package = Package(
1616
name: "NovaSwiftGodot",
1717
platforms: [
18-
.macOS(.v13),
18+
// Must be >= SwiftGodot's own minimum (macOS 14) even though the
19+
// root NovaSwift package (and the Apple SpriteKit app) target 13.
20+
.macOS(.v14),
1921
],
2022
products: [
2123
.library(name: "NovaSwiftGodot", type: .dynamic, targets: ["NovaSwiftGodot"]),
2224
],
2325
dependencies: [
2426
// The reusable Swift core (engine + data layer + story), by path.
25-
.package(path: "../.."),
27+
// NB: SwiftPM resolves a local path dependency's identity from its
28+
// manifest `name:` (here "NovaSwift"), not the checkout directory
29+
// name — but only if `name:` is passed explicitly here too.
30+
.package(name: "NovaSwift", path: "../.."),
2631
// SwiftGodot — the maintained Swift binding for Godot 4 GDExtensions.
2732
// Pinned to a branch because SwiftGodot tracks Godot releases on `main`;
2833
// pin to a tagged version once the frontend stabilises.

godot/bridge/Sources/NovaSwiftGodot/NovaWorld.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
//
2222
// See docs/GODOT_LAYER.md.
2323

24+
import Foundation
2425
import SwiftGodot
2526
import NovaSwiftEngine
2627
import NovaSwiftKit

scripts/build-gdextension.sh

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,4 +49,20 @@ if [ "$copied" -eq 0 ]; then
4949
exit 1
5050
fi
5151

52+
# The bridge links SwiftGodot as a dynamic library too (an @loader_path /
53+
# $ORIGIN rpath entry, not a static link), so it has to sit next to
54+
# libNovaSwiftGodot in godot/bin/ or the extension fails to dlopen at runtime.
55+
for f in \
56+
"$BIN_PATH/libSwiftGodot.so" \
57+
"$BIN_PATH/libSwiftGodot.dylib" \
58+
"$BIN_PATH/SwiftGodot.dll" \
59+
"$BIN_PATH/libSwiftGodot.dll"; do
60+
if [ -f "$f" ]; then
61+
base="$(basename "$f")"
62+
[ "$base" = "libSwiftGodot.dll" ] && base="SwiftGodot.dll"
63+
cp -f "$f" "$OUT_DIR/$base"
64+
echo "✓ copied $base$OUT_DIR/"
65+
fi
66+
done
67+
5268
echo "Done. Open godot/ in Godot 4.2+ (or run the exported build) to play the slice."

0 commit comments

Comments
 (0)