未验证 提交 9b2b3dad 编写于 作者: R risemeup1 提交者: GitHub

fix ninja error (#50617)

* fix ninja error

* fix_ninja_error

* fix ninja error

* fix r-200 ci ninja error
上级 f59c5d8b
......@@ -99,6 +99,16 @@ file(
"install(DIRECTORY xpu/include xpu/lib \n"
" DESTINATION ${XPU_INSTALL_DIR})\n")
if(WITH_XPU_BKCL)
message(STATUS "Compile with XPU BKCL!")
add_definitions(-DPADDLE_WITH_XPU_BKCL)
set(XPU_BKCL_LIB_NAME "libbkcl.so")
set(XPU_BKCL_LIB "${XPU_LIB_DIR}/${XPU_BKCL_LIB_NAME}")
set(XPU_BKCL_INC_DIR "${THIRD_PARTY_PATH}/install/xpu/include")
include_directories(${XPU_BKCL_INC_DIR})
endif()
ExternalProject_Add(
${XPU_PROJECT}
${EXTERNAL_PROJECT_LOG_ARGS}
......@@ -116,7 +126,8 @@ ExternalProject_Add(
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${XPU_INSTALL_ROOT}
CMAKE_CACHE_ARGS -DCMAKE_INSTALL_PREFIX:PATH=${XPU_INSTALL_ROOT}
BUILD_BYPRODUCTS ${XPU_API_LIB}
BUILD_BYPRODUCTS ${XPU_RT_LIB})
BUILD_BYPRODUCTS ${XPU_RT_LIB}
BUILD_BYPRODUCTS ${XPU_BKCL_LIB})
include_directories(${XPU_INC_DIR})
add_library(shared_xpuapi SHARED IMPORTED GLOBAL)
......@@ -128,16 +139,6 @@ generate_dummy_static_lib(LIB_NAME "xpulib" GENERATOR "xpu.cmake")
target_link_libraries(xpulib ${XPU_API_LIB} ${XPU_RT_LIB})
if(WITH_XPU_BKCL)
message(STATUS "Compile with XPU BKCL!")
add_definitions(-DPADDLE_WITH_XPU_BKCL)
set(XPU_BKCL_LIB_NAME "libbkcl.so")
set(XPU_BKCL_LIB "${XPU_LIB_DIR}/${XPU_BKCL_LIB_NAME}")
set(XPU_BKCL_INC_DIR "${THIRD_PARTY_PATH}/install/xpu/include")
include_directories(${XPU_BKCL_INC_DIR})
endif()
if(WITH_XPU_XFT)
message(STATUS "Compile with XPU XFT!")
add_definitions(-DPADDLE_WITH_XPU_XFT)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册