2020-07-13 22:06:54 +08:00
|
|
|
set(glog_CXXFLAGS "-D_FORTIFY_SOURCE=2 -O2 ${SECURE_CXX_FLAGS} -D_GLIBCXX_USE_CXX11_ABI=0")
|
2020-03-27 14:49:12 +08:00
|
|
|
set(glog_CFLAGS "-D_FORTIFY_SOURCE=2 -O2")
|
2020-10-20 14:58:59 +08:00
|
|
|
if (ENABLE_GITEE)
|
|
|
|
set(REQ_URL "https://gitee.com/mirrors/glog/repository/archive/v0.4.0.tar.gz")
|
|
|
|
set(MD5 "22fe340ddc231e6c8e46bc295320f8ee")
|
|
|
|
else()
|
|
|
|
set(REQ_URL "https://github.com/google/glog/archive/v0.4.0.tar.gz")
|
|
|
|
set(MD5 "0daea8785e6df922d7887755c3d100d0")
|
|
|
|
endif ()
|
2020-03-27 14:49:12 +08:00
|
|
|
mindspore_add_pkg(glog
|
|
|
|
VER 0.4.0
|
|
|
|
LIBS glog
|
2020-10-20 14:58:59 +08:00
|
|
|
URL ${REQ_URL}
|
|
|
|
MD5 ${MD5}
|
2020-09-24 19:16:33 +08:00
|
|
|
CMAKE_OPTION -DBUILD_TESTING=OFF -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DBUILD_SHARED_LIBS=ON -DWITH_GFLAGS=OFF)
|
2020-03-27 14:49:12 +08:00
|
|
|
include_directories(${glog_INC})
|
|
|
|
add_library(mindspore::glog ALIAS glog::glog)
|