Open luispadron opened 2 days ago
As a workaround (and potentially helps narrow down the issue): manually changing the target in the scheme from LibTwo (Static Framework)
to LibTwo (Library)
fixes the build.
If I remove use of transitive_deps from the merging logic then target merging works as expected and the build also passes.
However, indexing seems to fail when making changes:
examples/rules_ios/LibTwo/Sources/LibTwo.swift:1:8 No such module 'External'
Description
Given the following BUILD file:
With the following rules_xcodeproj scheme:
When generating the project the
LibTwo_Scheme
'sLibTwo
target does not merge and we end up with a scheme that looks like:With LibTwo making up two targets:
LibTwo (Static Framework)
andLibTwo (Library)
. I would expect these to be merged into a singleLibTwo
target in Xcode as is the case when usingapple_framework
as deps.I tested both
2.7.0
and2.5.2
and both seem to have the same issue. I added a reproducing example in: https://github.com/MobileNativeFoundation/rules_xcodeproj/pull/3093Reproduction steps
cd examples/rules_ios
bazel run //:xcodeproj-incremental
xed rules_ios.xcodeproj
Observe the failure:
Expected behavior
The
LibTwo
target is merged into a single target so that building it succeeds.rules_xcodeproj version
2.7.0
Xcode version
15.4
Bazel version
7.2.0
rules_apple version
3.9.2
rules_swift version
2.1.1
Additional information
No response