Skip to content

Commit

Permalink
Expose main_output on cc_common.link
Browse files Browse the repository at this point in the history
This field is useful for many situations, such as when you want to
create a native python extension, which doesn't follow the standard
library naming conventions.
  • Loading branch information
keith committed Oct 1, 2024
1 parent 99434b1 commit 03fc3c0
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -596,7 +596,6 @@ Tuple compile(
+ "`output_type`",
positional = false,
named = true,
documented = false,
defaultValue = "unbound",
allowedTypes = {@ParamType(type = FileApi.class), @ParamType(type = NoneType.class)}),
@Param(
Expand Down
5 changes: 1 addition & 4 deletions src/main/starlark/builtins_bzl/common/cc/cc_common.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ def _link(
always_link = _UNBOUND,
only_for_dynamic_libs = _UNBOUND,
link_artifact_name_suffix = _UNBOUND,
main_output = _UNBOUND,
main_output = None,
use_shareable_artifact_factory = _UNBOUND,
build_config = _UNBOUND,
emit_interface_shared_library = _UNBOUND):
Expand All @@ -93,7 +93,6 @@ def _link(
always_link != _UNBOUND or \
only_for_dynamic_libs != _UNBOUND or \
link_artifact_name_suffix != _UNBOUND or \
main_output != _UNBOUND or \
use_shareable_artifact_factory != _UNBOUND or \
build_config != _UNBOUND or \
emit_interface_shared_library != _UNBOUND:
Expand All @@ -117,8 +116,6 @@ def _link(
only_for_dynamic_libs = False
if link_artifact_name_suffix == _UNBOUND:
link_artifact_name_suffix = ""
if main_output == _UNBOUND:
main_output = None
if use_shareable_artifact_factory == _UNBOUND:
use_shareable_artifact_factory = False
if build_config == _UNBOUND:
Expand Down

0 comments on commit 03fc3c0

Please sign in to comment.