Update version_script to be handled as linkopt

This allows us to handle this consistently between cc_binary and
cc_library* types.

Test: build/bazel/ci/bp2build.sh
Change-Id: I996f42bbe591215217c3d561662e775925b871ff
This commit is contained in:
Liz Kammer
2021-10-04 13:54:37 -04:00
parent 06f00c33a7
commit d2871189b1
4 changed files with 40 additions and 61 deletions

View File

@@ -361,7 +361,8 @@ cc_library_shared {
}`,
expectedBazelTargets: []string{`cc_library_shared(
name = "foo_shared",
version_script = "version_script",
additional_linker_inputs = ["version_script"],
linkopts = ["-Wl,--version-script,$(location version_script)"],
)`},
})
}