|
|
|
@ -94,7 +94,7 @@ function(_protobuf_find_libraries name filename) |
|
|
|
|
elseif(${name}_LIBRARY) |
|
|
|
|
# Honor cache entry used by CMake 3.5 and lower. |
|
|
|
|
set(${name}_LIBRARIES "${${name}_LIBRARY}" PARENT_SCOPE) |
|
|
|
|
else() |
|
|
|
|
elseif(TARGET protobuf::lib${filename}) |
|
|
|
|
get_target_property(${name}_LIBRARY_RELEASE protobuf::lib${filename} |
|
|
|
|
LOCATION_RELEASE) |
|
|
|
|
get_target_property(${name}_LIBRARY_RELWITHDEBINFO protobuf::lib${filename} |
|
|
|
@ -134,6 +134,7 @@ get_target_property(Protobuf_INCLUDE_DIRS protobuf::libprotobuf |
|
|
|
|
INTERFACE_INCLUDE_DIRECTORIES) |
|
|
|
|
|
|
|
|
|
# Set the protoc Executable |
|
|
|
|
if(NOT Protobuf_PROTOC_EXECUTABLE AND TARGET protobuf::protoc) |
|
|
|
|
get_target_property(Protobuf_PROTOC_EXECUTABLE protobuf::protoc |
|
|
|
|
IMPORTED_LOCATION_RELEASE) |
|
|
|
|
if(NOT EXISTS "${Protobuf_PROTOC_EXECUTABLE}") |
|
|
|
@ -152,6 +153,7 @@ if(NOT EXISTS "${Protobuf_PROTOC_EXECUTABLE}") |
|
|
|
|
get_target_property(Protobuf_PROTOC_EXECUTABLE protobuf::protoc |
|
|
|
|
IMPORTED_LOCATION_NOCONFIG) |
|
|
|
|
endif() |
|
|
|
|
endif() |
|
|
|
|
|
|
|
|
|
# Version info variable |
|
|
|
|
set(Protobuf_VERSION "@protobuf_VERSION@") |
|
|
|
|