Swift build: "The system cannot find the path specified."

Vanilla Swift app on a fresh Windows installation (VM).

"The system cannot find the path specified." pops up always, ina full build or a no-op build. Whether I copy the modulemap/apinotes files or not doesn't make a difference.

Has anyone seen this?

C:\Users\Phil\dev\SwiftApp>rmdir /q /s .build

C:\Users\Phil\dev\SwiftApp>swift build
The system cannot find the path specified.
[1/3] Compiling SwiftApp main.swift
[2/4] Merging module SwiftApp
[3/4] Wrapping AST for SwiftApp for debugging
[4/4] Linking C:\Users\Phil\dev\SwiftApp\.build\x86_64-unknown-windows-msvc\debug\SwiftApp.exe
[4/4] Build complete!

C:\Users\Phil\dev\SwiftApp>swift build
[1/1] Planning build
The system cannot find the path specified.
[0/0] Build complete!

C:\Users\Phil\dev\SwiftApp>swift build
The system cannot find the path specified.
[0/0] Build complete!

C:\Users\Phil\dev\SwiftApp>swift build
The system cannot find the path specified.
[0/0] Build complete!

App seems to be working just fine:

C:\Users\Phil\dev\SwiftApp>.build\debug\SwiftApp.exe
Hello, world!

Here's the verbose output:

C:\Users\Phil\dev\SwiftApp>rmdir /q /s .build

C:\Users\Phil\dev\SwiftApp>swift build --verbose
C:\Library\Developer\Toolchains\unknown-Asserts-development.xctoolchain\usr\bin\swiftc.exe -print-target-info
C:\Library\Developer\Toolchains\unknown-Asserts-development.xctoolchain\usr\bin\swiftc.exe -print-target-info
The system cannot find the path specified.
C:\Library\Developer\Toolchains\unknown-Asserts-development.xctoolchain\usr\bin\swiftc.exe -module-name SwiftApp -incremental -emit-dependencies -emit-module -emit-module-path C:\Users\Phil\dev\SwiftApp\.build\x86_64-unknown-windows-msvc\debug\SwiftApp.build\SwiftApp.swiftmodule -output-file-map C:\Users\Phil\dev\SwiftApp\.build\x86_64-unknown-windows-msvc\debug\SwiftApp.build\output-file-map.json -c C:\Users\Phil\dev\SwiftApp\Sources\SwiftApp\main.swift -I C:\Users\Phil\dev\SwiftApp\.build\x86_64-unknown-windows-msvc\debug -target x86_64-unknown-windows-msvc -swift-version 5 -enable-batch-mode -index-store-path C:\Users\Phil\dev\SwiftApp\.build\x86_64-unknown-windows-msvc\debug\index\store -sdk C:\Library\Developer\Platforms\Windows.platform\Developer\SDKs\Windows.sdk -libc MD -I C:\Library\Developer\Platforms\Windows.platform\Developer\Library\XCTest-development\usr\lib\swift\windows\x86_64 -L C:\Library\Developer\Platforms\Windows.platform\Developer\Library\XCTest-development\usr\lib\swift\windows -use-ld=lld -Onone -enable-testing -g -j2 -DSWIFT_PACKAGE -DDEBUG -module-cache-path C:\Users\Phil\dev\SwiftApp\.build\x86_64-unknown-windows-msvc\debug\ModuleCache -parseable-output
C:\Library\Developer\Toolchains\unknown-Asserts-development.xctoolchain\usr\bin\swiftc.exe -frontend -c -primary-file C:\Users\Phil\dev\SwiftApp\Sources\SwiftApp\main.swift -emit-module-path C:\Users\Phil\dev\SwiftApp\.build\x86_64-unknown-windows-msvc\debug\SwiftApp.build\main~partial.swiftmodule -emit-module-doc-path C:\Users\Phil\dev\SwiftApp\.build\x86_64-unknown-windows-msvc\debug\SwiftApp.build\main~partial.swiftdoc -emit-module-source-info-path C:\Users\Phil\dev\SwiftApp\.build\x86_64-unknown-windows-msvc\debug\SwiftApp.build\main~partial.swiftsourceinfo -emit-dependencies-path C:\Users\Phil\dev\SwiftApp\.build\x86_64-unknown-windows-msvc\debug\SwiftApp.build\main.d -emit-reference-dependencies-path C:\Users\Phil\dev\SwiftApp\.build\x86_64-unknown-windows-msvc\debug\SwiftApp.build\main.swiftdeps -target x86_64-unknown-windows-msvc -disable-objc-interop -sdk C:\Library\Developer\Platforms\Windows.platform\Developer\SDKs\Windows.sdk -I C:\Users\Phil\dev\SwiftApp\.build\x86_64-unknown-windows-msvc\debug -I C:\Library\Developer\Platforms\Windows.platform\Developer\Library\XCTest-development\usr\lib\swift\windows\x86_64 -enable-testing -g -module-cache-path C:\Users\Phil\dev\SwiftApp\.build\x86_64-unknown-windows-msvc\debug\ModuleCache -swift-version 5 -Onone -D SWIFT_PACKAGE -D DEBUG -enable-anonymous-context-mangled-names -autolink-library oldnames -autolink-library msvcrt -Xcc -D_MT -Xcc -D_DLL -module-name SwiftApp -o C:\Users\Phil\dev\SwiftApp\.build\x86_64-unknown-windows-msvc\debug\SwiftApp.build\main.swift.o -index-store-path C:\Users\Phil\dev\SwiftApp\.build\x86_64-unknown-windows-msvc\debug\index\store -index-system-modules
C:\Library\Developer\Toolchains\unknown-Asserts-development.xctoolchain\usr\bin\swiftc.exe -frontend -merge-modules -emit-module C:\Users\Phil\dev\SwiftApp\.build\x86_64-unknown-windows-msvc\debug\SwiftApp.build\main~partial.swiftmodule -parse-as-library -disable-diagnostic-passes -disable-sil-perf-optzns -target x86_64-unknown-windows-msvc -warn-on-potentially-unavailable-enum-case -disable-objc-interop -sdk C:\Library\Developer\Platforms\Windows.platform\Developer\SDKs\Windows.sdk -I C:\Users\Phil\dev\SwiftApp\.build\x86_64-unknown-windows-msvc\debug -I C:\Library\Developer\Platforms\Windows.platform\Developer\Library\XCTest-development\usr\lib\swift\windows\x86_64 -enable-testing -g -module-cache-path C:\Users\Phil\dev\SwiftApp\.build\x86_64-unknown-windows-msvc\debug\ModuleCache -swift-version 5 -Onone -D SWIFT_PACKAGE -D DEBUG -enable-anonymous-context-mangled-names -autolink-library oldnames -autolink-library msvcrt -Xcc -D_MT -Xcc -D_DLL -emit-module-doc-path C:\Users\Phil\dev\SwiftApp\.build\x86_64-unknown-windows-msvc\debug\SwiftApp.build\SwiftApp.swiftdoc -emit-module-source-info-path C:\Users\Phil\dev\SwiftApp\.build\x86_64-unknown-windows-msvc\debug\SwiftApp.build\SwiftApp.swiftsourceinfo -module-name SwiftApp -o C:\Users\Phil\dev\SwiftApp\.build\x86_64-unknown-windows-msvc\debug\SwiftApp.build\SwiftApp.swiftmodule
C:\Library\Developer\Toolchains\unknown-Asserts-development.xctoolchain\usr\bin\swiftc.exe -modulewrap C:\Users\Phil\dev\SwiftApp\.build\x86_64-unknown-windows-msvc\debug\SwiftApp.build\SwiftApp.swiftmodule -o C:\Users\Phil\dev\SwiftApp\.build\x86_64-unknown-windows-msvc\debug\SwiftApp.build\SwiftApp.swiftmodule.o -target x86_64-unknown-windows-msvc
C:\Library\Developer\Toolchains\unknown-Asserts-development.xctoolchain\usr\bin\swiftc.exe -sdk C:\Library\Developer\Platforms\Windows.platform\Developer\SDKs\Windows.sdk -libc MD -I C:\Library\Developer\Platforms\Windows.platform\Developer\Library\XCTest-development\usr\lib\swift\windows\x86_64 -L C:\Library\Developer\Platforms\Windows.platform\Developer\Library\XCTest-development\usr\lib\swift\windows -use-ld=lld -L C:\Users\Phil\dev\SwiftApp\.build\x86_64-unknown-windows-msvc\debug -o C:\Users\Phil\dev\SwiftApp\.build\x86_64-unknown-windows-msvc\debug\SwiftApp.exe -module-name SwiftApp -emit-executable @C:\Users\Phil\dev\SwiftApp\.build\x86_64-unknown-windows-msvc\debug\SwiftApp.product\Objects.LinkFileList -target x86_64-unknown-windows-msvc
[0/0] Build complete!

I get the same message and have been wondering what it means as well.

Terms of Service

Privacy Policy

Cookie Policy