diff --git a/cmake/external_libs/gflags.cmake b/cmake/external_libs/gflags.cmake index 87a7422..bd14398 100755 --- a/cmake/external_libs/gflags.cmake +++ b/cmake/external_libs/gflags.cmake @@ -35,4 +35,5 @@ target_link_libraries(gflags INTERFACE gflags_static) add_dependencies(gflags gflags_build) -set(HAVE_GFLAGS TRUE CACHE BOOL "gflags build add") +#set(HAVE_GFLAGS TRUE CACHE BOOL "gflags build add") +set(HAVE_GFLAGS TRUE) diff --git a/cmake/external_libs/json.cmake b/cmake/external_libs/json.cmake index ac259a4..01ed33f 100755 --- a/cmake/external_libs/json.cmake +++ b/cmake/external_libs/json.cmake @@ -20,4 +20,5 @@ add_library(json INTERFACE) target_include_directories(json INTERFACE ${JSON_SRC_DIR}) add_dependencies(json json_build) -set(HAVE_JSON TRUE CACHE BOOL "json build add") +#set(HAVE_JSON TRUE CACHE BOOL "json build add") +set(HAVE_JSON TRUE) diff --git a/cmake/external_libs/protobuf_shared.cmake b/cmake/external_libs/protobuf_shared.cmake index bb4250c..f2cbf99 100755 --- a/cmake/external_libs/protobuf_shared.cmake +++ b/cmake/external_libs/protobuf_shared.cmake @@ -14,10 +14,10 @@ endif() set(protobuf_CXXFLAGS "-Wno-maybe-uninitialized -Wno-unused-parameter -fPIC -fstack-protector-all -D_FORTIFY_SOURCE=2 -D_GLIBCXX_USE_CXX11_ABI=0 -O2") set(protobuf_LDFLAGS "-Wl,-z,relro,-z,now,-z,noexecstack") ExternalProject_Add(protobuf_build - URL https://github.com/protocolbuffers/protobuf/archive/v3.8.0.tar.gz + #URL https://github.com/protocolbuffers/protobuf/archive/v3.8.0.tar.gz #URL /home/txd/workspace/linux_cmake/pkg/protobuf-3.8.0.tar.gz - #SOURCE_DIR ${PARSER_DIR}/../../third_party/protobuf/src/protobuf-3.8.0 - DOWNLOAD_COMMAND ${CMAKE_COMMAND} -E copy_directory ${PARSER_DIR}/../../third_party/protobuf/src/protobuf-3.8.0 + #SOURCE_DIR ${PARSER_DIR}/../third_party/protobuf/src/protobuf-3.8.0 + DOWNLOAD_COMMAND ${CMAKE_COMMAND} -E copy_directory ${PARSER_DIR}/../third_party/protobuf/src/protobuf-3.8.0 #CONFIGURE_COMMAND ${CMAKE_COMMAND} #-DCMAKE_INSTALL_LIBDIR=${CMAKE_INSTALL_LIBDIR} #-DCMAKE_C_COMPILER=${CMAKE_C_COMPILER} diff --git a/cmake/external_libs/protoc.cmake b/cmake/external_libs/protoc.cmake index 00ec951..3f44768 100755 --- a/cmake/external_libs/protoc.cmake +++ b/cmake/external_libs/protoc.cmake @@ -15,9 +15,9 @@ endif() set(protobuf_CXXFLAGS "-Wno-maybe-uninitialized -Wno-unused-parameter -fPIC -fstack-protector-all -D_FORTIFY_SOURCE=2 -D_GLIBCXX_USE_CXX11_ABI=0 -O2") set(protobuf_LDFLAGS "-Wl,-z,relro,-z,now,-z,noexecstack") ExternalProject_Add(protoc_build - URL https://github.com/protocolbuffers/protobuf/archive/v3.8.0.tar.gz + #URL https://github.com/protocolbuffers/protobuf/archive/v3.8.0.tar.gz #URL /home/txd/workspace/linux_cmake/pkg/protobuf-3.8.0.tar.gz - SOURCE_DIR ${PARSER_DIR}/../../third_party/protobuf/src/protobuf-3.8.0 + SOURCE_DIR ${PARSER_DIR}/../third_party/protobuf/src/protobuf-3.8.0 CONFIGURE_COMMAND ${CMAKE_COMMAND} -Dprotobuf_WITH_ZLIB=OFF -Dprotobuf_BUILD_TESTS=OFF -DBUILD_SHARED_LIBS=OFF -DCMAKE_CXX_FLAGS=${protobuf_CXXFLAGS} -DCMAKE_CXX_LDFLAGS=${protobuf_LDFLAGS} -DCMAKE_INSTALL_PREFIX=${CMAKE_INSTALL_PREFIX}/protoc /cmake BUILD_COMMAND $(MAKE) INSTALL_COMMAND $(MAKE) install diff --git a/cmake/external_libs/securec.cmake b/cmake/external_libs/securec.cmake index d88862d..3c1bdf4 100755 --- a/cmake/external_libs/securec.cmake +++ b/cmake/external_libs/securec.cmake @@ -14,7 +14,7 @@ ExternalProject_Add(c_sec_build URL https://gitee.com/openeuler/libboundscheck/repository/archive/v1.1.10.tar.gz #URL /home/txd/workspace/linux_cmake/pkg/protobuf-3.8.0.tar.gz #SOURCE_DIR ${PARSER_DIR}/../libc_sec - PATCH_COMMAND patch -p1 < ${METADEF_DIR}/third_party/patch/securec/0001-add-securec-cmake-script.patch + PATCH_COMMAND patch -p1 < ${PARSER_DIR}/metadef/third_party/patch/securec/0001-add-securec-cmake-script.patch CONFIGURE_COMMAND ${CMAKE_COMMAND} -DCMAKE_C_COMPILER=${CMAKE_C_COMPILER} -DCMAKE_CXX_COMPILER=${CMAKE_CXX_COMPILER} @@ -58,4 +58,5 @@ target_link_libraries(c_sec_static INTERFACE c_sec_static_lib) add_dependencies(c_sec_static c_sec_build) -set(HAVE_C_SEC TRUE CACHE BOOL "c_sec build add") +#set(HAVE_C_SEC TRUE CACHE BOOL "c_sec build add") +set(HAVE_C_SEC TRUE) diff --git a/cmake/intf_pub_linux.cmake b/cmake/intf_pub_linux.cmake index a98fee0..40c6bca 100755 --- a/cmake/intf_pub_linux.cmake +++ b/cmake/intf_pub_linux.cmake @@ -29,4 +29,5 @@ target_link_libraries(intf_pub INTERFACE -lpthread ) -set(HAVE_PUB TRUE CACHE BOOL "pub add") +#set(HAVE_PUB TRUE CACHE BOOL "pub add") +set(HAVE_PUB TRUE) diff --git a/parser/CMakeLists.txt b/parser/CMakeLists.txt index 8f33842..79976bf 100644 --- a/parser/CMakeLists.txt +++ b/parser/CMakeLists.txt @@ -71,6 +71,12 @@ target_include_directories(fmk_parser PRIVATE ${METADEF_DIR}/inc/external ${METADEF_DIR}/inc/external/graph ${METADEF_DIR}/inc/external/register + #### independent compile ##### + ${METADEF_DIR}/third_party/ge + ${METADEF_DIR}/third_party/ge/inc + ${METADEF_DIR}/third_party/ge/inc/framework + ${METADEF_DIR}/third_party/ge/inc/external + ${METADEF_DIR}/third_party/fwkacllib/inc #### temp #### ${PARSER_DIR}/../graphengine/inc/common/util ${PARSER_DIR}/../graphengine/inc/external diff --git a/parser/common/CMakeLists.txt b/parser/common/CMakeLists.txt index c852008..8469c87 100644 --- a/parser/common/CMakeLists.txt +++ b/parser/common/CMakeLists.txt @@ -53,6 +53,12 @@ target_include_directories(parser_common PRIVATE ${METADEF_DIR}/inc/external ${METADEF_DIR}/inc/external/graph ${METADEF_DIR}/inc/external/register + #### independent compile ##### + ${METADEF_DIR}/third_party/ge + ${METADEF_DIR}/third_party/ge/inc + ${METADEF_DIR}/third_party/ge/inc/framework + ${METADEF_DIR}/third_party/ge/inc/external + ${METADEF_DIR}/third_party/fwkacllib/inc #### temp #### ${PARSER_DIR}/../graphengine/inc/common/util ${PARSER_DIR}/../graphengine/inc/external diff --git a/parser/onnx/CMakeLists.txt b/parser/onnx/CMakeLists.txt index 9e3ebfb..7537eb3 100644 --- a/parser/onnx/CMakeLists.txt +++ b/parser/onnx/CMakeLists.txt @@ -41,6 +41,12 @@ target_include_directories(fmk_onnx_parser PRIVATE ${METADEF_DIR}/inc/external ${METADEF_DIR}/inc/external/graph ${METADEF_DIR}/inc/external/register + #### independent compile ##### + ${METADEF_DIR}/third_party/ge + ${METADEF_DIR}/third_party/ge/inc + ${METADEF_DIR}/third_party/ge/inc/framework + ${METADEF_DIR}/third_party/ge/inc/external + ${METADEF_DIR}/third_party/fwkacllib/inc #### temp #### ${PARSER_DIR}/../graphengine/inc/common/util ${PARSER_DIR}/../graphengine/inc/external