diff options
| author | AgustÃn RodrÃguez <me@agurodriguez.net> | 2018-10-22 13:04:13 -0300 |
|---|---|---|
| committer | Robert Schumacher <roschuma@microsoft.com> | 2018-10-22 09:04:13 -0700 |
| commit | 0720fd246322539a16a7574840f5fe9715ecac15 (patch) | |
| tree | ee8060dc2c3f220ffa61e39548a16d4c63690316 | |
| parent | 03266cc498138f026cbcf5754c8ff18a31c118d7 (diff) | |
| download | vcpkg-0720fd246322539a16a7574840f5fe9715ecac15.tar.gz vcpkg-0720fd246322539a16a7574840f5fe9715ecac15.zip | |
[libtins-4.0] new port (#4495)
* added libtins port
* [libtins] Modernize
* [libtins] Add missing winpcap dependency. Build static libs.
| -rw-r--r-- | ports/libtins/CONTROL | 4 | ||||
| -rw-r--r-- | ports/libtins/portfile.cmake | 30 |
2 files changed, 34 insertions, 0 deletions
diff --git a/ports/libtins/CONTROL b/ports/libtins/CONTROL new file mode 100644 index 000000000..e2a7f43a2 --- /dev/null +++ b/ports/libtins/CONTROL @@ -0,0 +1,4 @@ +Source: libtins +Version: 4.0-2 +Description: High-level, multiplatform C++ network packet sniffing and crafting library +Build-Depends: winpcap (windows) diff --git a/ports/libtins/portfile.cmake b/ports/libtins/portfile.cmake new file mode 100644 index 000000000..6890fe64c --- /dev/null +++ b/ports/libtins/portfile.cmake @@ -0,0 +1,30 @@ +include(vcpkg_common_functions) + +vcpkg_from_github( + OUT_SOURCE_PATH SOURCE_PATH + REPO mfontanini/libtins + REF v4.0 + SHA512 8a497617ca68f4bad331452778b92c51ce87e42d1ceae493ecd6799cabbe71609214ca962c4a8c83d205f76277f2a82f92d3d17341984caa1592cf237eb3cf3b + HEAD_REF master +) + +string(COMPARE EQUAL "${VCPKG_LIBRARY_LINKAGE}" "dynamic" LIBTINS_BUILD_SHARED) + +vcpkg_configure_cmake( + SOURCE_PATH ${SOURCE_PATH} + PREFER_NINJA + OPTIONS + -DLIBTINS_BUILD_SHARED=${LIBTINS_BUILD_SHARED} +) + +vcpkg_install_cmake() + +vcpkg_fixup_cmake_targets(CONFIG_PATH CMake TARGET_PATH share/libtins) + +file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include) + +# Handle copyright +configure_file(${SOURCE_PATH}/LICENSE ${CURRENT_PACKAGES_DIR}/share/libtins/copyright COPYONLY) + +# Post-build test for cmake libraries +vcpkg_test_cmake(PACKAGE_NAME libtins) |
