Skip to content

Commit 3f752a5

Browse files
Merge pull request #578 from swiftwasm/update-base-tag/main-swift-DEVELOPMENT-SNAPSHOT-2025-04-12-a
Update base tag for main to swift-DEVELOPMENT-SNAPSHOT-2025-04-12-a
2 parents 2b119b0 + 6dd6dc6 commit 3f752a5

File tree

4 files changed

+38
-3
lines changed

4 files changed

+38
-3
lines changed

schemes/main/manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"base-tag": "swift-DEVELOPMENT-SNAPSHOT-2025-04-03-a",
2+
"base-tag": "swift-DEVELOPMENT-SNAPSHOT-2025-04-12-a",
33
"icu4c": [],
44
"libxml2": [
55
"https://github.com/swiftwasm/libxml2-wasm/releases/download/2.0.0/libxml2-wasm32-unknown-wasi.tar.gz",
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
From 3828fe6d24735d59d53f073d9021b954d28e5750 Mon Sep 17 00:00:00 2001
2+
From: Yuta Saito <[email protected]>
3+
Date: Mon, 14 Apr 2025 18:20:25 +0000
4+
Subject: [PATCH] [wasm] Stop requiring `TZDIR` and `TZDEFAULT` on WASI
5+
6+
Those constants are not used on WASI in Swift side, so there's no
7+
need to require them in the C headers.
8+
---
9+
Sources/_FoundationCShims/include/_CStdlib.h | 2 +-
10+
1 file changed, 1 insertion(+), 1 deletion(-)
11+
12+
diff --git a/Sources/_FoundationCShims/include/_CStdlib.h b/Sources/_FoundationCShims/include/_CStdlib.h
13+
index 405febc..408a924 100644
14+
--- a/Sources/_FoundationCShims/include/_CStdlib.h
15+
+++ b/Sources/_FoundationCShims/include/_CStdlib.h
16+
@@ -156,7 +156,7 @@
17+
#ifndef TZDEFAULT
18+
#define TZDEFAULT "/etc/localtime"
19+
#endif /* !defined TZDEFAULT */
20+
-#elif TARGET_OS_WINDOWS
21+
+#elif TARGET_OS_WINDOWS || TARGET_OS_WASI
22+
/* not required */
23+
#else
24+
#error "possibly define TZDIR and TZDEFAULT for this platform"
25+
--
26+
2.48.1
27+

test/lit.cfg

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,11 @@ config.test_exec_root = lit_config.params.get(
2121
"/tmp/swift-extra-integration-tests")
2222

2323
config.available_features.add("platform="+platform.system())
24-
config.available_features.add("scheme="+lit_config.params.get("scheme", "main"))
24+
25+
# --param scheme=<scheme>
26+
scheme = lit_config.params.get("scheme", "main")
27+
config.scheme = scheme
28+
config.available_features.add("scheme="+scheme)
2529

2630
# --param swift-sdk=<swift-sdk-id>
2731
swift_sdk = lit_config.params.get("swift-sdk")

test/swift-sdk/lit.local.cfg

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,15 @@ else:
1515
target_swift_build = f"{swift} build {swift_sdk_options}"
1616
config.substitutions.append(("%{target_swift_build}", target_swift_build))
1717

18+
copy_cmd = 'cp %s %t.dir/Sources/Check/Check.swift'
19+
if config.root.scheme in ["release-6.0", "release-6.1", "release-6.2"]:
20+
copy_cmd = 'cp %s %t.dir/Sources/main.swift'
21+
1822
simple_swift_build_steps = [
1923
'rm -rf %t.dir',
2024
'mkdir -p %t.dir',
2125
f'{swift} package init --package-path %t.dir --name Check --type executable',
22-
'cp %s %t.dir/Sources/main.swift',
26+
copy_cmd,
2327
f'{target_swift_build} --package-path %t.dir',
2428
]
2529
config.substitutions.append(("%{target_simple_swift_build}", " && ".join(simple_swift_build_steps)))

0 commit comments

Comments
 (0)