mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-11-30 19:09:00 +08:00
ac0d90f680
* [proj4] Update to version 6.2.1; disable exporting symbols for static libraries * Remove deprecated function Co-authored-by: Jack·Boos·Yu <47264268+JackBoosY@users.noreply.github.com>
27 lines
822 B
Diff
27 lines
822 B
Diff
diff --git a/src/geodesic.h b/src/geodesic.h
|
|
index 11484ec7..479a9462 100644
|
|
--- a/src/geodesic.h
|
|
+++ b/src/geodesic.h
|
|
@@ -158,7 +158,7 @@
|
|
GEODESIC_VERSION_PATCH)
|
|
|
|
#ifndef GEOD_DLL
|
|
-#if defined(_MSC_VER)
|
|
+#if defined(_MSC_VER) && defined(PROJ_MSVC_DLL_EXPORT)
|
|
#define GEOD_DLL __declspec(dllexport)
|
|
#elif defined(__GNUC__)
|
|
#define GEOD_DLL __attribute__ ((visibility("default")))
|
|
diff --git a/src/lib_proj.cmake b/src/lib_proj.cmake
|
|
index bad60324..2e90f98f 100644
|
|
--- a/src/lib_proj.cmake
|
|
+++ b/src/lib_proj.cmake
|
|
@@ -443,7 +443,7 @@ endif()
|
|
include_directories(${SQLITE3_INCLUDE_DIR})
|
|
target_link_libraries(${PROJ_CORE_TARGET} ${SQLITE3_LIBRARY})
|
|
|
|
-if(MSVC)
|
|
+if(MSVC AND BUILD_LIBPROJ_SHARED)
|
|
target_compile_definitions(${PROJ_CORE_TARGET}
|
|
PRIVATE PROJ_MSVC_DLL_EXPORT=1)
|
|
endif()
|