From 10486eda6bf19cec3f0de8463adc3b48f0108b75 Mon Sep 17 00:00:00 2001 From: Chen Weihang Date: Wed, 30 Nov 2022 09:41:49 +0000 Subject: [PATCH] Revert "[Cherry-pick] Fix python link error (#47811)" This reverts commit ff642c68d6681596844b5c1bae695a81d1baf3da. --- paddle/fluid/pybind/CMakeLists.txt | 6 ------ 1 file changed, 6 deletions(-) diff --git a/paddle/fluid/pybind/CMakeLists.txt b/paddle/fluid/pybind/CMakeLists.txt index 652a835cbc807..0a59caae2bbe8 100755 --- a/paddle/fluid/pybind/CMakeLists.txt +++ b/paddle/fluid/pybind/CMakeLists.txt @@ -262,10 +262,6 @@ if(WITH_PYTHON) list(APPEND OP_FUNCTION_GENERETOR_DEPS cncl_context) endif() - if(NOT ((NOT WITH_PYTHON) AND ON_INFER)) - list(APPEND OP_FUNCTION_GENERETOR_DEPS ${PYTHON_LIBRARIES}) - endif() - add_executable(op_function_generator op_function_generator.cc) target_link_libraries(op_function_generator ${OP_FUNCTION_GENERETOR_DEPS}) add_executable(eager_legacy_op_function_generator @@ -605,6 +601,4 @@ if(WITH_PYTHON) get_property(os_dependency_modules GLOBAL PROPERTY OS_DEPENDENCY_MODULES) target_link_libraries(${SHARD_LIB_NAME} ${os_dependency_modules}) add_dependencies(${SHARD_LIB_NAME} op_function_generator_cmd) - - target_link_libraries(${SHARD_LIB_NAME} ${PYTHON_LIBRARIES}) endif()