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

Pass compilation context via swift info in framework rule due to rules_swift 2.1.1 #907

Conversation

gyfelton
Copy link
Contributor

@gyfelton gyfelton commented Aug 28, 2024

same idea as #906 this time is for framework rule.

The CI error trying to fix in this PR is:

# Execution platform: @local_config_platform//:host
error: generate-pch command failed with exit code 1 (use -v to see invocation)
tests/ios/unit-test/test-imports-app/TestImports-App-Bridging-Header.h:1:9: error: 'TestImports-App/Header2.h' file not found
#import <TestImports-App/Header2.h>
        ^
1 error generated.
<unknown>:0: error: failed to emit precompiled header 'bazel-out/ios-sim_arm64-min12.0-applebin_ios-ios_sim_arm64-dbg-ST-c2aefc9133a8/bin/_pch_output_dir/TestImports-App-Bridging-Header-swift_28IU2BV1DK30K-clang_1FNSWCOAS4SUQ.pch' for bridging header 'tests/ios/unit-test/test-imports-app/TestImports-App-Bridging-Header.h'
2 errors generated.
error: fatalError

This time this header is brought in by the framework rule

The idea here is to create the clang_module based of the same compilation context as CcInfo and construct the final swift info based on it. With this no need to differentiate based on if VFS turned on or not

@gyfelton gyfelton marked this pull request as ready for review August 28, 2024 20:49
@gyfelton gyfelton force-pushed the yuanfeng/pass-compilation-context-via-swiftinfo-framework branch 3 times, most recently from 578af24 to 5d7a24b Compare August 29, 2024 03:45
@gyfelton gyfelton merged commit d399078 into luis/add-clang-attr-to-merged-swift-info-for-framework Aug 29, 2024
21 of 42 checks passed
@gyfelton gyfelton deleted the yuanfeng/pass-compilation-context-via-swiftinfo-framework branch August 29, 2024 17:18
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.

3 participants