v2.3.3 release: cross-platform driver in docs (makeDefaultAudioDriver)

This commit is contained in:
2026-12-01 21:32:39 -08:00
parent 56726223f6
commit a175c437de
23 changed files with 54 additions and 43 deletions
+7 -1
View File
@@ -253,9 +253,15 @@ def modules_dir(root: Path) -> Path:
proc = subprocess.run(["swift", "build", "--show-bin-path"], cwd=root,
capture_output=True, text=True)
if proc.returncode == 0 and proc.stdout.strip():
d = Path(proc.stdout.strip()) / "Modules"
bin_dir = Path(proc.stdout.strip())
d = bin_dir / "Modules"
if d.is_dir():
return d
# Newer SwiftPM build layouts (e.g. .build/out/Products/Debug) drop the
# Modules/ subdir and place the .swiftmodule bundles directly in the bin
# dir. Use the bin dir itself as the import search path in that case.
if any(bin_dir.glob("*.swiftmodule")):
return bin_dir
raise RuntimeError("could not locate the built Modules dir; run `swift build` first")