Skip to content
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

incompatible_disallow_native_in_build_file: Forbid native module in BUILD files #7513

Open
laurentlb opened this Issue Feb 22, 2019 · 1 comment

Comments

Projects
None yet
2 participants
@laurentlb
Copy link
Contributor

commented Feb 22, 2019

The native module was created to access BUILD file functions in bzl files.

The native module has been exposed by accident to BUILD files. We are going to remove it from BUILD files, and keep it only in bzl files.
Fixing the issue should be trivial, e.g.

- native.cc_library(
+ cc_library(
-    srcs = native.glob(["*.java"])
+    srcs = glob(["*.java"])

The fix is mechanical, it can be fixed automatically using:
buildifier --lint=fix file.bzl

bazel-io pushed a commit that referenced this issue Feb 22, 2019

Introduce --incompatible_disallow_native_in_build_file to forbid nati…
…ve module in BUILD files

#7513

RELNOTES:
  Using the `native` module in BUILD files is deprecated. It will be forbidden with --incompatible_disallow_native_in_build_file.
PiperOrigin-RevId: 235207912

irengrig added a commit to irengrig/bazel that referenced this issue Feb 26, 2019

Introduce --incompatible_disallow_native_in_build_file to forbid nati…
…ve module in BUILD files

bazelbuild#7513

RELNOTES:
  Using the `native` module in BUILD files is deprecated. It will be forbidden with --incompatible_disallow_native_in_build_file.
PiperOrigin-RevId: 235207912

@laurentlb laurentlb self-assigned this Feb 28, 2019

@katre

This comment has been minimized.

Copy link
Member

commented Mar 1, 2019

I am assuming the migration window is one release: if this is not the case please let me know.

@katre katre removed the migration-ready label Mar 1, 2019

emusand added a commit to emusand/bazel that referenced this issue Apr 16, 2019

Introduce --incompatible_disallow_native_in_build_file to forbid nati…
…ve module in BUILD files

bazelbuild#7513

RELNOTES:
  Using the `native` module in BUILD files is deprecated. It will be forbidden with --incompatible_disallow_native_in_build_file.
PiperOrigin-RevId: 235207912
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.