mkmkme commented on code in PR #3299:
URL: https://github.com/apache/avro/pull/3299#discussion_r1930137523
##########
lang/c++/CMakeLists.txt:
##########
@@ -202,15 +196,16 @@ if (AVRO_BUILD_EXECUTABLES)
gen (union_redundant_types redundant_types)
add_executable (avrogencpp impl/avrogencpp.cc)
- target_link_libraries (avrogencpp avrocpp_s ${Boost_LIBRARIES})
+ target_link_libraries (avrogencpp avrocpp_s)
+ target_compile_definitions(avrogencpp PRIVATE
AVRO_VERSION="${AVRO_VERSION}")
endif ()
if (AVRO_BUILD_TESTS)
enable_testing()
macro (unittest name)
add_executable (${name} test/${name}.cc)
- target_link_libraries (${name} avrocpp_s ${Boost_LIBRARIES}
${SNAPPY_LIBRARIES} ${ZLIB_LIBRARIES})
+ target_link_libraries (${name} avrocpp_s Boost::system ZLIB::ZLIB
$<$<TARGET_EXISTS:Snappy::snappy>:Snappy::snappy>)
Review Comment:
Can't we use `$<TARGET_NAME_IF_EXISTS:Snappy::snappy>` here as well instead
of `$<$<TARGET_EXISTS:Snappy::snappy>:Snappy::snappy>`?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]