diff --git a/src/main/java/com/google/devtools/build/lib/rules/python/PyBinary.java b/src/main/java/com/google/devtools/build/lib/rules/python/PyBinary.java index 41e19c497cc20a..07a1213bcadcd8 100644 --- a/src/main/java/com/google/devtools/build/lib/rules/python/PyBinary.java +++ b/src/main/java/com/google/devtools/build/lib/rules/python/PyBinary.java @@ -164,7 +164,6 @@ protected void collect( CcLinkParams.Builder builder, boolean linkingStatically, boolean linkShared) { builder.addTransitiveTargets( ruleContext.getPrerequisites("deps", Mode.TARGET), - PyCcLinkParamsProvider.TO_LINK_PARAMS, CcLinkParamsStore.TO_LINK_PARAMS); } }; diff --git a/src/main/java/com/google/devtools/build/lib/rules/python/PyCcLinkParamsProvider.java b/src/main/java/com/google/devtools/build/lib/rules/python/PyCcLinkParamsProvider.java deleted file mode 100644 index 8a270ac30694e7..00000000000000 --- a/src/main/java/com/google/devtools/build/lib/rules/python/PyCcLinkParamsProvider.java +++ /dev/null @@ -1,43 +0,0 @@ -// Copyright 2014 The Bazel Authors. All rights reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -package com.google.devtools.build.lib.rules.python; - -import com.google.common.base.Function; -import com.google.devtools.build.lib.analysis.TransitiveInfoCollection; -import com.google.devtools.build.lib.analysis.TransitiveInfoProvider; -import com.google.devtools.build.lib.concurrent.ThreadSafety.Immutable; -import com.google.devtools.build.lib.rules.cpp.AbstractCcLinkParamsStore; -import com.google.devtools.build.lib.rules.cpp.CcLinkParamsStore; -import com.google.devtools.build.lib.skyframe.serialization.autocodec.AutoCodec; - -/** A target that provides C++ libraries to be linked into Python targets. */ -@Immutable -@AutoCodec -public final class PyCcLinkParamsProvider implements TransitiveInfoProvider { - private final CcLinkParamsStore store; - - public PyCcLinkParamsProvider(CcLinkParamsStore store) { - this.store = store; - } - - public AbstractCcLinkParamsStore getLinkParams() { - return store; - } - - public static final Function TO_LINK_PARAMS = - input -> { - PyCcLinkParamsProvider provider = input.getProvider(PyCcLinkParamsProvider.class); - return provider == null ? null : provider.getLinkParams(); - }; -} diff --git a/src/main/java/com/google/devtools/build/lib/rules/python/PyLibrary.java b/src/main/java/com/google/devtools/build/lib/rules/python/PyLibrary.java index e40a1ab9788266..97060f345cbe68 100644 --- a/src/main/java/com/google/devtools/build/lib/rules/python/PyLibrary.java +++ b/src/main/java/com/google/devtools/build/lib/rules/python/PyLibrary.java @@ -71,7 +71,6 @@ protected void collect( CcLinkParams.Builder builder, boolean linkingStatically, boolean linkShared) { builder.addTransitiveTargets( ruleContext.getPrerequisites("deps", Mode.TARGET), - PyCcLinkParamsProvider.TO_LINK_PARAMS, CcLinkParamsStore.TO_LINK_PARAMS); } };