Skip to content

Commit 21c351b

Browse files
committed
add DUCKDB_STATIC_BUILD to compile defs
1 parent b69cab3 commit 21c351b

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

CMakeLists.txt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,11 @@ target_include_directories(
5757
INTERFACE $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/src/duckdb_py/include>
5858
)
5959

60+
# We link duckdb_static. Without this define, duckdb.h marks C API symbols
61+
# __declspec(dllimport) on Windows, producing unresolvable __imp_* references at
62+
# link time. No-op on non-Windows.
63+
target_compile_definitions(_duckdb_dependencies INTERFACE DUCKDB_STATIC_BUILD)
64+
6065
# ────────────────────────────────────────────
6166
# Descend into the real DuckDB‑Python sources
6267
# ────────────────────────────────────────────

0 commit comments

Comments
 (0)