Skip to content
Merged
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
11 changes: 10 additions & 1 deletion cpp/src/parquet/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -413,11 +413,20 @@ add_parquet_test(arrow-reader-writer-test
arrow/variant_test.cc)

if(ARROW_WITH_OPENTELEMETRY)
if(opentelemetry-cpp_SOURCE STREQUAL "SYSTEM")
# System OpenTelemetry is not bundled with libarrow.
# We need to link against it explicitly otherwise we get missing symbols.
set(EXTRA_TEST_LINK_LIBS ${ARROW_OPENTELEMETRY_LIBS})
else()
# Bundled OpenTelemetry is statically linked into libarrow; linking it
# again duplicates globals and causes a double free at exit.
set(EXTRA_TEST_LINK_LIBS opentelemetry-cpp::sdk)
endif()
add_parquet_test(arrow-reader-writer-tracing-test
SOURCES
arrow/arrow_reader_writer_tracing_test.cc
EXTRA_LINK_LIBS
opentelemetry-cpp::sdk)
${EXTRA_TEST_LINK_LIBS})
endif()

add_parquet_test(arrow-index-test SOURCES arrow/index_test.cc)
Expand Down
Loading