Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revert "Always quote path arguments when resolving command-lines for libSwiftScan queries" #1337

Closed

Conversation

compnerd
Copy link
Collaborator

Reverts #1335

I believe that this is breaking SPM on Windows:

C:\Library\Developer\Toolchains\unknown-Asserts-development.xctoolchain\usr\bin\swift-frontend.exe -frontend -c -primary-file "C:\Users\WDAGUT~1\AppData\Local\Temp\TemporaryDirectory.odLA64\manifest.swift" -target x86_64-unknown-windows-msvc -disable-objc-interop -sdk "'C:\Library\Developer\Platforms\Windows.platform\Developer\SDKs\Windows.sdk'" -I C:\Library\Developer\Platforms\Windows.platform\Developer\Library\XCTest-development\usr\lib\swift\windows -I C:\Library\Developer\Platforms\Windows.platform\Developer\Library\XCTest-development\usr\lib\swift\windows\x86_64 -I C:\Library\Developer\Toolchains\unknown-Asserts-development.xctoolchain\usr\lib\swift\pm\ManifestAPI -swift-version 5 -package-description-version 5.8.0 -disable-implicit-concurrency-module-import -disable-implicit-string-processing-module-import -empty-abi-descriptor -plugin-path C:\Library\Developer\Toolchains\unknown-Asserts-development.xctoolchain\usr\lib\swift\host\plugins -plugin-path C:\Library\Developer\Toolchains\unknown-Asserts-development.xctoolchain\usr\local\lib\swift\host\plugins -resource-dir C:\Library\Developer\Toolchains\unknown-Asserts-development.xctoolchain\usr\lib\swift -module-name main -o "C:\Users\WDAGUT~1\AppData\Local\Temp\TemporaryDirectory.FFxF6q\manifest-1.o"

Note the quoting on SDKROOT. The quoting style is an issue.

@compnerd
Copy link
Collaborator Author

@swift-ci please test

@artemcm
Copy link
Contributor

artemcm commented Apr 25, 2023

I doubt that this change is the culprit here. The example given is a compile command, whereas the change being reverted here only affects command lines for -print-target-info and -scan-dependencies queries to libSwiftScan.

@compnerd
Copy link
Collaborator Author

Verified that replacing swiftc.exe with the C++ driver seems to repair the ability to build with SPM.

@artemcm
Copy link
Contributor

artemcm commented Apr 26, 2023

Verified that replacing swiftc.exe with the C++ driver seems to repair the ability to build with SPM.

While it does seem like there is a bug here in the driver, we still don't quite have enough information to deem this particular change to be the culprit and need to revert it.

@compnerd
Copy link
Collaborator Author

Verified locally that just adding the revert with the current state of the tree does work.

@artemcm
Copy link
Contributor

artemcm commented Apr 27, 2023

apple/swift#60581 just built a Windows Toolchain successfully without this revert:
https://ci-external.swift.org/job/swift-PR-build-toolchain-windows/567/

@compnerd
Copy link
Collaborator Author

@artemcm that I had already verified does exhibit the issue. Note that building the toolchain is not the issue, the issue is only visible after you install the toolchain via the generated installer and try to build something with SPM.

@compnerd
Copy link
Collaborator Author

This should no longer be needed as @artemcm put in a fix for the quoting.

@compnerd compnerd closed this Apr 29, 2023
@compnerd compnerd deleted the revert-1335-ResolveLibScanQueryCommandLinePaths branch April 29, 2023 16:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants