Use gflags ALIAS instead of ${gflags_XXX} vars
The gflags project updated their CMake config last year with a
`gflags` ALIAS target. This can be used instead of the legacy
`${gflags_LIBRARIES}` and `${gflags_INCLUDE_DIRS}` variables. It also
looks cleaner.
Fixes #198
This commit is contained in:
parent
77a0e36b7a
commit
e1cae334a1
@ -397,8 +397,7 @@ if (WIN32 AND HAVE_SNPRINTF)
|
||||
endif (WIN32 AND HAVE_SNPRINTF)
|
||||
|
||||
if (gflags_FOUND)
|
||||
target_include_directories (glog PUBLIC $<BUILD_INTERFACE:${gflags_INCLUDE_DIR}>)
|
||||
target_link_libraries (glog PUBLIC ${gflags_LIBRARIES})
|
||||
target_link_libraries (glog PUBLIC gflags)
|
||||
|
||||
if (NOT BUILD_SHARED_LIBS)
|
||||
# Don't use __declspec(dllexport|dllimport) if this is a static build
|
||||
|
||||
Loading…
Reference in New Issue
Block a user