diff options
| author | Alexander Karatarakis <alkarata@microsoft.com> | 2016-10-14 16:52:38 -0700 |
|---|---|---|
| committer | Alexander Karatarakis <alkarata@microsoft.com> | 2016-10-14 16:52:38 -0700 |
| commit | f52268db1add49377ff10c7bdf8a21878372fc3c (patch) | |
| tree | 26b74c30c89d2bda05fe07e544b64d5077645871 /ports/libbson | |
| parent | eb1cea1f4396677317eda5c8163203aff3054776 (diff) | |
| parent | 9517eeadbba6e0f491a2961cd359c4c4892ef93f (diff) | |
| download | vcpkg-f52268db1add49377ff10c7bdf8a21878372fc3c.tar.gz vcpkg-f52268db1add49377ff10c7bdf8a21878372fc3c.zip | |
Merge branch 'master' of https://github.com/Microsoft/vcpkg
Diffstat (limited to 'ports/libbson')
| -rw-r--r-- | ports/libbson/0001_cmake.patch | 35 | ||||
| -rw-r--r-- | ports/libbson/CONTROL | 3 | ||||
| -rw-r--r-- | ports/libbson/portfile.cmake | 26 |
3 files changed, 64 insertions, 0 deletions
diff --git a/ports/libbson/0001_cmake.patch b/ports/libbson/0001_cmake.patch new file mode 100644 index 000000000..af1f1a598 --- /dev/null +++ b/ports/libbson/0001_cmake.patch @@ -0,0 +1,35 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index d09a298..e64a6cd 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -12,7 +12,6 @@ include(CheckIncludeFile) + include(CheckStructHasMember) + include(CheckSymbolExists) + include(TestBigEndian) +-include(InstallRequiredSystemLibraries) + + set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${PROJECT_SOURCE_DIR}/build/cmake) + +@@ -47,13 +46,6 @@ TEST_BIG_ENDIAN(BSON_BIG_ENDIAN) + set (BSON_PTHREAD_ONCE_INIT_NEEDS_BRACES 0) + set (BSON_HAVE_DECIMAL128 0) + +-#librt needed on linux for clock_gettime +-find_library(RT_LIBRARY rt) +-if (RT_LIBRARY) +- #set required libraries for CHECK_FUNCTION_EXISTS +- set(CMAKE_REQUIRED_LIBRARIES ${RT_LIBRARY}) +-endif() +- + # See https://public.kitware.com/Bug/view.php?id=15659 + CHECK_SYMBOL_EXISTS(snprintf stdio.h BSON_HAVE_SNPRINTF) + if (NOT BSON_HAVE_SNPRINTF) +@@ -314,7 +306,7 @@ install( + ) + install( + FILES ${HEADERS} +- DESTINATION "include/libbson-${BSON_API_VERSION}" ++ DESTINATION "include" + ) + + set(VERSION "${BSON_VERSION}") diff --git a/ports/libbson/CONTROL b/ports/libbson/CONTROL new file mode 100644 index 000000000..71f48c354 --- /dev/null +++ b/ports/libbson/CONTROL @@ -0,0 +1,3 @@ +Source: libbson +Version: 1.4.2 +Description: libbson is a library providing useful routines related to building, parsing, and iterating BSON documents.
\ No newline at end of file diff --git a/ports/libbson/portfile.cmake b/ports/libbson/portfile.cmake new file mode 100644 index 000000000..efa147068 --- /dev/null +++ b/ports/libbson/portfile.cmake @@ -0,0 +1,26 @@ +include(${CMAKE_TRIPLET_FILE}) +include(vcpkg_common_functions) +find_program(POWERSHELL powershell) +set(SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/libbson-1.4.2) + +vcpkg_download_distfile(ARCHIVE + URLS "https://github.com/mongodb/libbson/releases/download/1.4.2/libbson-1.4.2.tar.gz" + FILENAME "libbson-1.4.2.tar.gz" + SHA512 4cc8f833978483af3dcbc30bede33f2a9b448930fabf7be2d5581c8368e875dc1707d31eae209c747e69be1f82fa525c7362c5ac9c4e0b6b3f3346dd5147860e +) +vcpkg_extract_source_archive(${ARCHIVE}) + +vcpkg_apply_patches( + SOURCE_PATH ${SOURCE_PATH} + PATCHES ${CMAKE_CURRENT_LIST_DIR}/0001_cmake.patch +) + +vcpkg_configure_cmake( + SOURCE_PATH ${SOURCE_PATH} +) + +vcpkg_install_cmake() +file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include) + +file(COPY ${SOURCE_PATH}/COPYING DESTINATION ${CURRENT_PACKAGES_DIR}/share/libbson) +file(RENAME ${CURRENT_PACKAGES_DIR}/share/libbson/COPYING ${CURRENT_PACKAGES_DIR}/share/libbson/copyright)
\ No newline at end of file |
