Skip to content
Merged
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
1 change: 0 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,6 @@ The following environment variables can be set to customize dependency URLs:
- `ICEBERG_NANOARROW_URL`: Nanoarrow tarball URL
- `ICEBERG_CROARING_URL`: CRoaring tarball URL
- `ICEBERG_NLOHMANN_JSON_URL`: nlohmann-json tarball URL
- `ICEBERG_SPDLOG_URL`: spdlog tarball URL
- `ICEBERG_CPR_URL`: cpr tarball URL

Example usage:
Expand Down
57 changes: 0 additions & 57 deletions cmake_modules/IcebergThirdpartyToolchain.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ set(ICEBERG_ARROW_INSTALL_INTERFACE_LIBS)
# ICEBERG_NANOARROW_URL - Nanoarrow tarball URL
# ICEBERG_CROARING_URL - CRoaring tarball URL
# ICEBERG_NLOHMANN_JSON_URL - nlohmann-json tarball URL
# ICEBERG_SPDLOG_URL - spdlog tarball URL
# ICEBERG_CPR_URL - cpr tarball URL
#
# Example usage:
Expand Down Expand Up @@ -427,61 +426,6 @@ function(resolve_nlohmann_json_dependency)
PARENT_SCOPE)
endfunction()

# ----------------------------------------------------------------------
# spdlog

function(resolve_spdlog_dependency)
prepare_fetchcontent()

find_package(Threads REQUIRED)

set(SPDLOG_USE_STD_FORMAT
ON
CACHE BOOL "" FORCE)
set(SPDLOG_BUILD_PIC
ON
CACHE BOOL "" FORCE)

if(DEFINED ENV{ICEBERG_SPDLOG_URL})
set(SPDLOG_URL "$ENV{ICEBERG_SPDLOG_URL}")
else()
set(SPDLOG_URL "https://github.com/gabime/spdlog/archive/refs/tags/v1.15.3.tar.gz")
endif()

fetchcontent_declare(spdlog
${FC_DECLARE_COMMON_OPTIONS}
URL ${SPDLOG_URL}
FIND_PACKAGE_ARGS
NAMES
spdlog
CONFIG)
fetchcontent_makeavailable(spdlog)

if(spdlog_SOURCE_DIR)
set_target_properties(spdlog PROPERTIES OUTPUT_NAME "iceberg_vendored_spdlog"
POSITION_INDEPENDENT_CODE ON)
target_link_libraries(spdlog INTERFACE Threads::Threads)
install(TARGETS spdlog
EXPORT iceberg_targets
RUNTIME DESTINATION "${ICEBERG_INSTALL_BINDIR}"
ARCHIVE DESTINATION "${ICEBERG_INSTALL_LIBDIR}"
LIBRARY DESTINATION "${ICEBERG_INSTALL_LIBDIR}")
set(SPDLOG_VENDORED TRUE)
else()
set(SPDLOG_VENDORED FALSE)
list(APPEND ICEBERG_SYSTEM_DEPENDENCIES spdlog)
endif()

list(APPEND ICEBERG_SYSTEM_DEPENDENCIES Threads)

set(ICEBERG_SYSTEM_DEPENDENCIES
${ICEBERG_SYSTEM_DEPENDENCIES}
PARENT_SCOPE)
set(SPDLOG_VENDORED
${SPDLOG_VENDORED}
PARENT_SCOPE)
endfunction()

# ----------------------------------------------------------------------
# zlib

Expand Down Expand Up @@ -575,7 +519,6 @@ resolve_zlib_dependency()
resolve_nanoarrow_dependency()
resolve_croaring_dependency()
resolve_nlohmann_json_dependency()
resolve_spdlog_dependency()

if(ICEBERG_BUILD_BUNDLE)
resolve_arrow_dependency()
Expand Down
8 changes: 2 additions & 6 deletions src/iceberg/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -107,27 +107,23 @@ list(APPEND
nanoarrow::nanoarrow_static
nlohmann_json::nlohmann_json
roaring::roaring
spdlog::spdlog
ZLIB::ZLIB)
list(APPEND
ICEBERG_SHARED_BUILD_INTERFACE_LIBS
nanoarrow::nanoarrow_shared
nlohmann_json::nlohmann_json
roaring::roaring
spdlog::spdlog
ZLIB::ZLIB)
list(APPEND
ICEBERG_STATIC_INSTALL_INTERFACE_LIBS
"$<IF:$<BOOL:${NANOARROW_VENDORED}>,iceberg::nanoarrow_static,$<IF:$<TARGET_EXISTS:nanoarrow::nanoarrow_static>,nanoarrow::nanoarrow_static,nanoarrow::nanoarrow_shared>>"
"$<IF:$<BOOL:${NLOHMANN_JSON_VENDORED}>,iceberg::nlohmann_json,$<IF:$<TARGET_EXISTS:nlohmann_json::nlohmann_json>,nlohmann_json::nlohmann_json,nlohmann_json::nlohmann_json>>"
"$<IF:$<BOOL:${CROARING_VENDORED}>,iceberg::roaring,roaring::roaring>"
"$<IF:$<BOOL:${SPDLOG_VENDORED}>,iceberg::spdlog,spdlog::spdlog>")
"$<IF:$<BOOL:${CROARING_VENDORED}>,iceberg::roaring,roaring::roaring>")
list(APPEND
ICEBERG_SHARED_INSTALL_INTERFACE_LIBS
"$<IF:$<BOOL:${NANOARROW_VENDORED}>,iceberg::nanoarrow_shared,$<IF:$<TARGET_EXISTS:nanoarrow::nanoarrow_shared>,nanoarrow::nanoarrow_shared,nanoarrow::nanoarrow_static>>"
"$<IF:$<BOOL:${NLOHMANN_JSON_VENDORED}>,iceberg::nlohmann_json,$<IF:$<TARGET_EXISTS:nlohmann_json::nlohmann_json>,nlohmann_json::nlohmann_json,nlohmann_json::nlohmann_json>>"
"$<IF:$<BOOL:${CROARING_VENDORED}>,iceberg::roaring,roaring::roaring>"
"$<IF:$<BOOL:${SPDLOG_VENDORED}>,iceberg::spdlog,spdlog::spdlog>")
"$<IF:$<BOOL:${CROARING_VENDORED}>,iceberg::roaring,roaring::roaring>")

add_iceberg_lib(iceberg
SOURCES
Expand Down
9 changes: 1 addition & 8 deletions src/iceberg/meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -128,16 +128,9 @@ croaring_needs_static = (
croaring_dep = dependency('croaring', static: croaring_needs_static)
nanoarrow_dep = dependency('nanoarrow')
nlohmann_json_dep = dependency('nlohmann_json')
spdlog_dep = dependency('spdlog')
zlib_dep = dependency('zlib')

iceberg_deps = [
croaring_dep,
nanoarrow_dep,
nlohmann_json_dep,
spdlog_dep,
zlib_dep,
]
iceberg_deps = [croaring_dep, nanoarrow_dep, nlohmann_json_dep, zlib_dep]

iceberg_lib = library(
'iceberg',
Expand Down
30 changes: 0 additions & 30 deletions subprojects/spdlog.wrap

This file was deleted.

Loading