bazel-xcode / bazel-xcode/PodToBUILD
Header visibility issue for the added Cocoapods dependency
- Dominant language
- Swift
- Stars
- 330
- Forks
- 68
- PR merge metrics
- No merged PRs in 30d
Description
I tried Integrating CocoaPods dependency using PodToBuild, added `new_pod_repository` rule to my Workspace file as mentioned in the ReadMe section.
When I run bazel build, getting this header visibility error
`ERROR: /Users/sanju/TestProjects/BazelDemoApp/BUILD:13:14: in swift_library rule //:BazelDemoAppTarget: target '@Alamofire//:Alamofire' is not visible from target '//:BazelDemoAppTarget'. Check the visibility declaration of the former target if you think the dependency is legitimate
ERROR: Analysis of target '//:BazelDemoApp' failed; build aborted: Analysis of target '//:BazelDemoAppTarget' failed
INFO: Elapsed time: 8.222s`
Then I checked into the BUILD.bazel file generated by PodToBuild [for the Pod I am integrating]. It doesn't mention visibility so the pod package has become private.
I got it working by manually adding below line to the Build.bazel file of the cocoapod.
`package(default_visibility = ["//visibility:public"])`
But I believe this should be taken care of by the PodToBuild plugin. Am I missing any config or parameter while setting up `new_pod_repository`? Any help on this would be appreciated. Thanks in advance.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.