Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ORC-1751: [C++] fix syntax error in ThirdpartyToolchain #1994

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions cmake_modules/FindZSTD.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -86,13 +86,13 @@ mark_as_advanced (
)

if(ZSTD_FOUND)
if(NOT TARGET zstd::libzstd_static AND ${ZSTD_STATIC_LIB})
if(NOT TARGET zstd::libzstd_static AND ZSTD_STATIC_LIB)
add_library(zstd::libzstd_static STATIC IMPORTED)
set_target_properties(zstd::libzstd_static
PROPERTIES IMPORTED_LOCATION "${ZSTD_STATIC_LIB}"
INTERFACE_INCLUDE_DIRECTORIES "${ZSTD_INCLUDE_DIR}")
endif()
if(NOT TARGET zstd::libzstd_shared AND NOT ${ZSTD_STATIC_LIB})
if(NOT TARGET zstd::libzstd_shared AND NOT ZSTD_STATIC_LIB)
add_library(zstd::libzstd_shared SHARED IMPORTED)
set_target_properties(zstd::libzstd_shared
PROPERTIES IMPORTED_LOCATION "${ZSTD_LIBRARY}"
Expand Down
14 changes: 7 additions & 7 deletions cmake_modules/ThirdpartyToolchain.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ if (ORC_PACKAGE_KIND STREQUAL "conan")
list (APPEND ORC_INSTALL_INTERFACE_TARGETS "$<INSTALL_INTERFACE:Snappy::snappy>")
elseif (NOT "${SNAPPY_HOME}" STREQUAL "")
find_package (Snappy REQUIRED)
if (ORC_PREFER_STATIC_SNAPPY AND ${SNAPPY_STATIC_LIB})
if (ORC_PREFER_STATIC_SNAPPY AND SNAPPY_STATIC_LIB)
add_resolved_library (orc_snappy ${SNAPPY_STATIC_LIB} ${SNAPPY_INCLUDE_DIR})
else ()
add_resolved_library (orc_snappy ${SNAPPY_LIBRARY} ${SNAPPY_INCLUDE_DIR})
Expand Down Expand Up @@ -199,7 +199,7 @@ if (ORC_PACKAGE_KIND STREQUAL "conan")
list (APPEND ORC_INSTALL_INTERFACE_TARGETS "$<INSTALL_INTERFACE:ZLIB::ZLIB>")
elseif (NOT "${ZLIB_HOME}" STREQUAL "")
find_package (ZLIB REQUIRED)
if (ORC_PREFER_STATIC_ZLIB AND ${ZLIB_STATIC_LIB})
if (ORC_PREFER_STATIC_ZLIB AND ZLIB_STATIC_LIB)
add_resolved_library (orc_zlib ${ZLIB_STATIC_LIB} ${ZLIB_INCLUDE_DIR})
else ()
add_resolved_library (orc_zlib ${ZLIB_LIBRARY} ${ZLIB_INCLUDE_DIR})
Expand Down Expand Up @@ -251,7 +251,7 @@ if (ORC_PACKAGE_KIND STREQUAL "conan")
list (APPEND ORC_INSTALL_INTERFACE_TARGETS "$<INSTALL_INTERFACE:$<IF:$<TARGET_EXISTS:zstd::libzstd_shared>,zstd::libzstd_shared,zstd::libzstd_static>>")
elseif (NOT "${ZSTD_HOME}" STREQUAL "")
find_package (ZSTD REQUIRED)
if (ORC_PREFER_STATIC_ZSTD AND ${ZSTD_STATIC_LIB})
if (ORC_PREFER_STATIC_ZSTD AND ZSTD_STATIC_LIB)
add_resolved_library (orc_zstd ${ZSTD_STATIC_LIB} ${ZSTD_INCLUDE_DIR})
list (APPEND ORC_INSTALL_INTERFACE_TARGETS "$<INSTALL_INTERFACE:zstd::libzstd_static>")
else ()
Expand Down Expand Up @@ -310,7 +310,7 @@ if (ORC_PACKAGE_KIND STREQUAL "conan")
list (APPEND ORC_INSTALL_INTERFACE_TARGETS "$<INSTALL_INTERFACE:LZ4::lz4>")
elseif (NOT "${LZ4_HOME}" STREQUAL "")
find_package (LZ4 REQUIRED)
if (ORC_PREFER_STATIC_LZ4 AND ${LZ4_STATIC_LIB})
if (ORC_PREFER_STATIC_LZ4 AND LZ4_STATIC_LIB)
add_resolved_library (orc_lz4 ${LZ4_STATIC_LIB} ${LZ4_INCLUDE_DIR})
else ()
add_resolved_library (orc_lz4 ${LZ4_LIBRARY} ${LZ4_INCLUDE_DIR})
Expand Down Expand Up @@ -434,7 +434,7 @@ if (BUILD_CPP_TESTS)
add_library (orc::gmock ALIAS orc_gmock)
add_library (orc_gtest INTERFACE)
add_library (orc::gtest ALIAS orc_gtest)
if (ORC_PREFER_STATIC_GMOCK AND ${GMOCK_STATIC_LIB})
if (ORC_PREFER_STATIC_GMOCK AND GMOCK_STATIC_LIB)
target_link_libraries (orc_gmock INTERFACE ${GMOCK_STATIC_LIB})
target_link_libraries (orc_gtest INTERFACE ${GTEST_STATIC_LIB})
else ()
Expand Down Expand Up @@ -466,13 +466,13 @@ if (ORC_PACKAGE_KIND STREQUAL "conan")
elseif (NOT "${PROTOBUF_HOME}" STREQUAL "")
find_package (Protobuf REQUIRED)

if (ORC_PREFER_STATIC_PROTOBUF AND ${PROTOBUF_STATIC_LIB})
if (ORC_PREFER_STATIC_PROTOBUF AND PROTOBUF_STATIC_LIB)
add_resolved_library (orc_protobuf ${PROTOBUF_STATIC_LIB} ${PROTOBUF_INCLUDE_DIR})
else ()
add_resolved_library (orc_protobuf ${PROTOBUF_LIBRARY} ${PROTOBUF_INCLUDE_DIR})
endif ()

if (ORC_PREFER_STATIC_PROTOBUF AND ${PROTOC_STATIC_LIB})
if (ORC_PREFER_STATIC_PROTOBUF AND PROTOC_STATIC_LIB)
add_resolved_library (orc_protoc ${PROTOC_STATIC_LIB} ${PROTOBUF_INCLUDE_DIR})
else ()
add_resolved_library (orc_protoc ${PROTOC_LIBRARY} ${PROTOBUF_INCLUDE_DIR})
Expand Down
Loading