diff options
| author | Long Huan <8551701+longhuan2018@users.noreply.github.com> | 2019-08-20 23:41:32 +0800 |
|---|---|---|
| committer | Curtis J Bezault <curtbezault@gmail.com> | 2019-08-20 08:41:32 -0700 |
| commit | 3173e5516a6f495404c17311bedb8927369f2959 (patch) | |
| tree | 860d1ebedf9546def3f59df9f87e1b686743b963 /ports/libspatialindex/static.patch | |
| parent | 48598bcb6d50640b27a555647c8cf5690d9a035a (diff) | |
| download | vcpkg-3173e5516a6f495404c17311bedb8927369f2959.tar.gz vcpkg-3173e5516a6f495404c17311bedb8927369f2959.zip | |
[libspatialindex]Add new port (#7762)
* new port libspatialindex
* Update portfile.cmake
* support static build
Diffstat (limited to 'ports/libspatialindex/static.patch')
| -rw-r--r-- | ports/libspatialindex/static.patch | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/ports/libspatialindex/static.patch b/ports/libspatialindex/static.patch new file mode 100644 index 000000000..bf783bcca --- /dev/null +++ b/ports/libspatialindex/static.patch @@ -0,0 +1,21 @@ +diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt +index e6b733bd..8f227ab0 100644 +--- a/src/CMakeLists.txt ++++ b/src/CMakeLists.txt +@@ -194,9 +194,13 @@ if (NOT WITH_STATIC_LASZIP) + endif() + endif() + +-add_library(${SIDX_LIB_NAME} SHARED ${SIDX_SOURCES}) +- +-add_library(${SIDX_C_LIB_NAME} SHARED ${SIDX_CAPI_CPP}) ++if(BUILD_SHARED_LIBS) ++ add_library(${SIDX_LIB_NAME} SHARED ${SIDX_SOURCES}) ++ add_library(${SIDX_C_LIB_NAME} SHARED ${SIDX_CAPI_CPP}) ++else(BUILD_SHARED_LIBS) ++ add_library(${SIDX_LIB_NAME} STATIC ${SIDX_SOURCES}) ++ add_library(${SIDX_C_LIB_NAME} STATIC ${SIDX_CAPI_CPP}) ++endif(BUILD_SHARED_LIBS) + + target_link_libraries(${SIDX_C_LIB_NAME} + ${SIDX_LIB_NAME} |
