Skip to content

New configure script alters .bazelrc in the source tree #22762

Closed

Description

@DavidNorman

System information

  • Issue is when building from source
  • Linux Ubuntu 18
  • HEAD of master
  • python 3
  • bazel 0.16.1

Describe the problem

The issue is that the configure script now updates the contents of the .bazelrc file in place - thus changing the source code of the repo. This is very unhelpful for change management. There is a comment in the .bazelrc file which seems to suggest that the changes which are made should not be checked in.

Activity

  1. DavidNorman commented on Oct 5, 2018

    @DavidNorman
    ContributorAuthor
    diff --git a/.bazelrc b/.bazelrc
    index d5d20309df..c27c68ee02 100644
    --- a/.bazelrc
    +++ b/.bazelrc
    @@ -86,3 +86,4 @@ build --define=LIBDIR=$(PREFIX)/lib
     build --define=INCLUDEDIR=$(PREFIX)/include
     
     # Do not commit the tf_configure.bazelrc line
    +import %workspace%/.tf_configure.bazelrc
    

    The bottom line is being added by the configure script and causes the .bazelrc to be permanently modified.

  2. avijit-nervana commented on Oct 6, 2018

    @avijit-nervana
    Contributor

    The line containing .bazelrc was removed from the .gitignore - which is a recent change (post branching of r1.12) and just need to be reverted.

  3. assigned and unassigned on Oct 8, 2018
  4. added
    stat:awaiting tensorflower
    on Oct 8, 2018
  5. girving commented on Oct 13, 2018

    @girving
    Contributor

    Cc @perfinion. This makes TensorFlow development awkward for people outside Google. What was the motivation?

  6. removed
    stat:awaiting tensorflower
    on Oct 13, 2018
  7. perfinion commented on Oct 13, 2018

    @perfinion
    Member

    @girving Bazel-0.18.0 changes which files it reads. It originally dropped reading tools/bazel.rc so we had to move everything into .bazelrc. it will support a try-import so i'm gonna unconditionally add that to bazelrc and then the file wont change with and without configuring. Bazel-0.18.0 is due out on monday so I was gonna bump the minimum version and fix it then. Its pretty awkward yeah but it wont be for that long so hopefully not too bad.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions