Skip to content

Commit afca9af

Browse files
committed
Only apply SPM patch for SQLite to trunk on CI
1 parent 388ed5d commit afca9af

File tree

3 files changed

+15
-11
lines changed

3 files changed

+15
-11
lines changed

.github/workflows/sdks.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ jobs:
113113
sed -i "s%cross_compile_config%cross_compile_config, '-Xlinker', '-landroid-spawn'%" sourcekit-lsp/Utilities/build-script-helper.py
114114
115115
if [ ${{ matrix.version }} = 'trunk' ]; then
116-
git apply package-patches/sourcekit-lsp-sqlite.patch
116+
git apply package-patches/swiftpm-sqlite.patch
117117
else
118118
git apply swift-android-clang.patch
119119
fi

package-patches/sourcekit-lsp-sqlite.patch renamed to package-patches/swiftpm-sqlite.patch

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,3 +12,17 @@ index 17ad9e3..953fffd 100755
1212
return env
1313

1414

15+
diff --git a/swiftpm/Utilities/bootstrap b/swiftpm/Utilities/bootstrap
16+
index 085056de..1ded1a90 100755
17+
--- a/swiftpm/Utilities/bootstrap
18+
+++ b/swiftpm/Utilities/bootstrap
19+
@@ -615,6 +615,9 @@
20+
"SWIFT_DRIVER_SWIFT_EXEC=" + args.swiftc_path,
21+
]
22+
23+
+ if args.cross_compile_hosts and re.match('android-', args.cross_compile_hosts):
24+
+ swiftpm_args.append("PKG_CONFIG_PATH=" + os.path.join(os.path.split(args.cross_compile_config)[0], "lib/pkgconfig"))
25+
+
26+
if args.bootstrap:
27+
note("Building SwiftPM (with a freshly built swift-bootstrap)")
28+
swiftpm_args.append("SWIFTPM_CUSTOM_LIBS_DIR=" + os.path.join(args.bootstrap_dir, "pm"))

swift-android-ci.patch

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -50,16 +50,6 @@ diff --git a/swiftpm/Utilities/bootstrap b/swiftpm/Utilities/bootstrap
5050
index 085056de..1ded1a90 100755
5151
--- a/swiftpm/Utilities/bootstrap
5252
+++ b/swiftpm/Utilities/bootstrap
53-
@@ -615,6 +615,9 @@
54-
"SWIFT_DRIVER_SWIFT_EXEC=" + args.swiftc_path,
55-
]
56-
57-
+ if args.cross_compile_hosts and re.match('android-', args.cross_compile_hosts):
58-
+ swiftpm_args.append("PKG_CONFIG_PATH=" + os.path.join(os.path.split(args.cross_compile_config)[0], "lib/pkgconfig"))
59-
+
60-
if args.bootstrap:
61-
note("Building SwiftPM (with a freshly built swift-build)")
62-
swiftpm_args.append("SWIFTPM_CUSTOM_LIBS_DIR=" + os.path.join(args.bootstrap_dir, "pm"))
6353
@@ -803,6 +806,7 @@
6454
if 'ANDROID_DATA' in os.environ or (args.cross_compile_hosts and re.match(
6555
'android-', args.cross_compile_hosts)):

0 commit comments

Comments
 (0)