@@ -99,7 +99,7 @@ function(resolve_arrow_dependency)
9999 fetchcontent_declare(VendoredArrow
100100 ${FC_DECLARE_COMMON_OPTIONS}
101101 GIT_REPOSITORY https://github.com/apache/arrow.git
102- GIT_TAG 5f0aeb5de53fb25b59a52661a80071faef99a4a4
102+ GIT_TAG f12356adaaabea86638407e995e73215dbb58bb2
103103 #URL ${ARROW_SOURCE_URL}
104104 #URL_HASH "SHA256=${ICEBERG_ARROW_BUILD_SHA256_CHECKSUM}"
105105 SOURCE_SUBDIR
@@ -282,6 +282,55 @@ function(resolve_nlohmann_json_dependency)
282282 LIBRARY DESTINATION "${ICEBERG_INSTALL_LIBDIR} " )
283283endfunction ()
284284
285+ # ----------------------------------------------------------------------
286+ # spdlog
287+
288+ function (resolve_spdlog_dependency)
289+ prepare_fetchcontent()
290+
291+ find_package (Threads REQUIRED)
292+
293+ set (SPDLOG_USE_STD_FORMAT
294+ ON
295+ CACHE BOOL "" FORCE)
296+ set (SPDLOG_BUILD_PIC
297+ ON
298+ CACHE BOOL "" FORCE)
299+
300+ fetchcontent_declare(spdlog
301+ ${FC_DECLARE_COMMON_OPTIONS}
302+ URL "https://github.com/gabime/spdlog/archive/refs/tags/v1.15.3.tar.gz"
303+ FIND_PACKAGE_ARGS
304+ NAMES
305+ spdlog
306+ CONFIG)
307+ fetchcontent_makeavailable(spdlog)
308+
309+ if (spdlog_SOURCE_DIR)
310+ set_target_properties (spdlog PROPERTIES OUTPUT_NAME "iceberg_vendored_spdlog"
311+ POSITION_INDEPENDENT_CODE ON )
312+ target_link_libraries (spdlog INTERFACE Threads::Threads)
313+ install (TARGETS spdlog
314+ EXPORT iceberg_targets
315+ RUNTIME DESTINATION "${ICEBERG_INSTALL_BINDIR} "
316+ ARCHIVE DESTINATION "${ICEBERG_INSTALL_LIBDIR} "
317+ LIBRARY DESTINATION "${ICEBERG_INSTALL_LIBDIR} " )
318+ set (SPDLOG_VENDORED TRUE )
319+ else ()
320+ set (SPDLOG_VENDORED FALSE )
321+ list (APPEND ICEBERG_SYSTEM_DEPENDENCIES spdlog)
322+ endif ()
323+
324+ list (APPEND ICEBERG_SYSTEM_DEPENDENCIES Threads)
325+
326+ set (ICEBERG_SYSTEM_DEPENDENCIES
327+ ${ICEBERG_SYSTEM_DEPENDENCIES}
328+ PARENT_SCOPE)
329+ set (SPDLOG_VENDORED
330+ ${SPDLOG_VENDORED}
331+ PARENT_SCOPE)
332+ endfunction ()
333+
285334# ----------------------------------------------------------------------
286335# zlib
287336
@@ -316,6 +365,7 @@ endfunction()
316365resolve_zlib_dependency()
317366resolve_nanoarrow_dependency()
318367resolve_nlohmann_json_dependency()
368+ resolve_spdlog_dependency()
319369
320370if (ICEBERG_BUILD_BUNDLE)
321371 resolve_arrow_dependency()
0 commit comments