Commit 644f83a6 authored by Ghislain MARY's avatar Ghislain MARY

Use compile definition instead of .def file for symbols export on Windows.

parent e9657129
......@@ -28,9 +28,6 @@ option(ENABLE_STATIC "Build static library (default is shared library)." OFF)
set(SOURCE_FILES sqlite3.c)
if(WIN32)
list(APPEND SOURCE_FILES sqlite3.def)
endif()
if(CMAKE_SYSTEM_NAME STREQUAL "WindowsPhone" OR CMAKE_SYSTEM_NAME STREQUAL "WindowsStore")
add_definitions(
......@@ -45,6 +42,7 @@ if(ENABLE_STATIC)
else()
add_library(sqlite3 SHARED ${SOURCE_FILES})
if(MSVC)
add_definitions("-DSQLITE_API=__declspec(dllexport)")
if(CMAKE_BUILD_TYPE STREQUAL "Debug")
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/Debug/sqlite3.pdb
DESTINATION bin
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment