diff options
| author | Ethan Morgan <ethan@gweithio.com> | 2026-02-14 16:44:06 +0000 |
|---|---|---|
| committer | Ethan Morgan <ethan@gweithio.com> | 2026-02-14 16:44:06 +0000 |
| commit | 54409423f767d8b1cf30cb7d0efca6b4ca138823 (patch) | |
| tree | d915ac7828703ce4b963efdd9728a1777ba18c1e /vcpkg/ports/libosmium | |
Diffstat (limited to 'vcpkg/ports/libosmium')
| -rw-r--r-- | vcpkg/ports/libosmium/portfile.cmake | 23 | ||||
| -rw-r--r-- | vcpkg/ports/libosmium/usage | 4 | ||||
| -rw-r--r-- | vcpkg/ports/libosmium/vcpkg.json | 20 |
3 files changed, 47 insertions, 0 deletions
diff --git a/vcpkg/ports/libosmium/portfile.cmake b/vcpkg/ports/libosmium/portfile.cmake new file mode 100644 index 0000000..d86406b --- /dev/null +++ b/vcpkg/ports/libosmium/portfile.cmake @@ -0,0 +1,23 @@ +set(VCPKG_BUILD_TYPE release) # header-only
+
+vcpkg_from_github(
+ OUT_SOURCE_PATH SOURCE_PATH
+ REPO osmcode/libosmium
+ REF "v${VERSION}"
+ SHA512 0d2b5e8e316d05c8e2d05b58d1c79136b1d78fffb116cb39987d007a4c68b325d8d7551e4c55b67e5c46927c92df720a0360c9abbc8784b9af9f86846297dae2
+)
+
+vcpkg_cmake_configure(
+ SOURCE_PATH "${SOURCE_PATH}"
+ OPTIONS
+ -DBUILD_TESTING=OFF
+ -DBUILD_EXAMPLES=OFF
+ -DCMAKE_DISABLE_FIND_PACKAGE_GDAL=ON
+ # for transitive dependencies via pkgconf
+ -DPKG_CONFIG_USE_CMAKE_PREFIX_PATH=1
+ -DVCPKG_HOST_TRIPLET=${HOST_TRIPLET}
+)
+vcpkg_cmake_install()
+
+file(INSTALL "${CURRENT_PORT_DIR}/usage" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}")
+vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE")
diff --git a/vcpkg/ports/libosmium/usage b/vcpkg/ports/libosmium/usage new file mode 100644 index 0000000..813a705 --- /dev/null +++ b/vcpkg/ports/libosmium/usage @@ -0,0 +1,4 @@ +libosmium is header-only and can be used from CMake via: + + find_path(OSMIUM_INCLUDE_DIRS "osmium/version.hpp") + target_include_directories(main PRIVATE ${OSMIUM_INCLUDE_DIRS}) diff --git a/vcpkg/ports/libosmium/vcpkg.json b/vcpkg/ports/libosmium/vcpkg.json new file mode 100644 index 0000000..bd59599 --- /dev/null +++ b/vcpkg/ports/libosmium/vcpkg.json @@ -0,0 +1,20 @@ +{ + "name": "libosmium", + "version-semver": "2.22.0", + "description": "A fast and flexible C++ library for working with OpenStreetMap data", + "homepage": "https://osmcode.org/libosmium/", + "license": "BSL-1.0", + "dependencies": [ + "boost-crc", + "boost-variant", + "bzip2", + "expat", + "lz4", + "protozero", + { + "name": "vcpkg-cmake", + "host": true + }, + "zlib" + ] +} |