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

BUILD: dont force stripping #19599

Merged
merged 2 commits into from
Jun 1, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
5 changes: 5 additions & 0 deletions configure.py
Original file line number Diff line number Diff line change
Expand Up @@ -1427,6 +1427,10 @@ def set_grpc_build_flags():
write_to_bazelrc('build --define grpc_no_ares=true')


def set_build_strip_flag():
write_to_bazelrc('build --strip=always')


def set_windows_build_flags():
if is_windows():
# The non-monolithic build is not supported yet
Expand Down Expand Up @@ -1549,6 +1553,7 @@ def main():

set_grpc_build_flags()
set_cc_opt_flags(environ_cp)
set_build_strip_flag()
set_windows_build_flags()

if workspace_has_any_android_rule():
Expand Down
4 changes: 1 addition & 3 deletions tensorflow/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -471,7 +471,7 @@ tf_cc_shared_object(
# excludes all but a subset of function names.
# On MacOS, the linker does not support version_script, but has an
# an "-exported_symbols_list" command. -z defs disallows undefined
# symbols in object files and -s strips the output.
# symbols in object files.

tf_cc_shared_object(
name = "libtensorflow.so",
Expand All @@ -485,7 +485,6 @@ tf_cc_shared_object(
"//tensorflow:windows_msvc": [],
"//conditions:default": [
"-z defs",
"-s",
"-Wl,--version-script", # This line must be directly followed by the version_script.lds file
"$(location //tensorflow/c:version_script.lds)",
],
Expand All @@ -511,7 +510,6 @@ tf_cc_shared_object(
"//tensorflow:windows_msvc": [],
"//conditions:default": [
"-z defs",
"-s",
"-Wl,--version-script", # This line must be directly followed by the version_script.lds file
"$(location //tensorflow:tf_version_script.lds)",
],
Expand Down