tulsi
tulsi copied to clipboard
[Issue#74] Expand location template/macro if found in copts
Bazel supports location template and provides an API to expand location, with the path of the corresponding output file, if and when the context is accessible.
Tulsi currently doesn't support the location template and messes up the paths/ flags by splitting the template by space. Refer to https://github.com/bazelbuild/tulsi/issues/74 for more details.
\cc @DavidGoldman @reinhillmann @dierksen @googlebot
Change-Id: I397590c93a05918206fe9d78867095336d6532ae
Also created this - https://bazel-review.googlesource.com/c/tulsi/+/89190
Thanks to @ob for chipping in for this change.
@DavidGoldman @dierksen Can you please take a look at this? \cc @reinhillmann
Posted this to #74, when I meant to post it here, but anyway, can you provide an example that we could add for an integration test?
@dierksen I simplified the location expansion logic as per your suggestion. Also modified the .gitignore to exclude Tulsi's own Xcode project files and tulsi-workspace symlink. Please take a look.
Friendly ping
@DavidGoldman I think @ravimandala is waiting for https://github.com/bazelbuild/bazel/issues/7083 to be resolved before adding this change as it can potentially break valid builds if people add an actual call to $(location)...
https://github.com/bazelbuild/bazel/issues/7083 is fixed. @ravimandala can you add the comment/example that @DavidGoldman requested?
@DavidGoldman, @ob has an example in https://github.com/bazelbuild/bazel/issues/7083 in the form of a repro.sh to reproduce this issue. Does that help with integration test?
@DavidGoldman, Can you please take a look?
[Gentle reminder] @dierksen, @DavidGoldman - can you please review the changes? TIA.
@DavidGoldman, @ob has an example in bazelbuild/bazel#7083 in the form of a
repro.shto reproduce this issue. Does that help with integration test?
It would you be good to modify the AspectTests to check that this works as intended (you can add some new copts to an existing target).
Ahh, now I see what you mean. Let me add a test for this feature.
@ravimandala Friendly ping—any update? :)
Anyone know the state of this one?
Related: https://github.com/bazelbuild/tulsi/pull/157
Thanks for submitting this PR but this repository is being deprecated. Please switch to rules_xcodeproj as a more complete and maintained alternative.