-
Notifications
You must be signed in to change notification settings - Fork 4.1k
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
not possible to declare_file to genfiles_dir #4858
Comments
I would suggest |
cc @laurentlb |
Long-term plan is to get rid of the root and the distinction between We might add the feature for now, but it should be clear it will go away. |
We can add that knob, but instead, can you get by by putting that file under |
Maybe try to build your code with |
I didn't know the plan to remove the genfiles directory. Wich version will remove the separation and did you report this anywhere? |
It's unclear at the moment how we'll proceed. The separation is not useful and it adds complexity. I would be very happy if we could remove it. It's still here for legacy reasons, so we need to investigate and see how much work there is to do before we can switch the default. |
This moves the generated files to the bin directory due to bazelbuild/bazel#4858.
This moves the generated files to the bin directory due to bazelbuild/bazel#4858.
@laurentlb a ticket to be able to follow regarding this long term plan would be very beneficial. For me it was also a little bit hard to find in this ticket that this is the long term plan |
The |
Description of the problem / feature request:
since ctx.new_file() is deprecated ctx.actions.declare_file() should be a replacement.
with ctx.new_file() it was possible to generate files to genfiles_dir which I tried with ctx.actions.declare_file()
produces
Feature requests: what underlying problem are you trying to solve with this feature?
it must be possible to use a root dir (ctx.bin_dir and ctx.genfiles_dir) as sibling
or as different parameter e.g. root.
Bugs: what's the simplest, easiest way to reproduce this bug? Please provide a minimal example if possible.
rule.bzl:
BUILD:
bazel build xxx
What operating system are you running Bazel on?
macOS 10.12.6
What's the output of
bazel info release
?release 0.11.1-homebrew
The text was updated successfully, but these errors were encountered: