PodToBUILD icon indicating copy to clipboard operation
PodToBUILD copied to clipboard

Support in-tree podspecs

Open jerrymarino opened this issue 6 years ago • 1 comments

This enables people to use local podspecs as the source of truth for target definition and build settings instead of a BUILD file.

It introduces a single repository_rule to generates a BUILD files for every podspec in the source tree adjacent to the podspec.

Example repository_rule

# WORKSPACE
gen_pod_build_files()

Considerations:

  • the rule must be a repository rule, to fit into bazels evaluation model

  • it may glob all the *.podspecs as an input and use these inputs for cache invalidation

  • the BUILD file compiler needs to be updated to manage the local podspecs

  • </> and @ import support needs to be updated to hmaps or symlinking to the right directory.

jerrymarino avatar Aug 16 '19 20:08 jerrymarino

it may glob all the *.podspecs as an input and use these inputs for cache invalidation

would be super if it took in a list of files, so we could write a glob with excludes

use these inputs for cache invalidation

since podspecs can contain arbitrary ruby, would also like to be able to pass in a list of other files to consider as dependencies of the podspecs

updated to hmaps or symlinking to the right directory

and if symlinking, ideally do that as part of the build process, rather than when evaluating the repository rule

segiddins avatar Aug 16 '19 21:08 segiddins