diff --git a/ports/xdigest/portfile.cmake b/ports/xdigest/portfile.cmake new file mode 100644 index 00000000000000..373fa0767adc45 --- /dev/null +++ b/ports/xdigest/portfile.cmake @@ -0,0 +1,34 @@ +vcpkg_from_github( + OUT_SOURCE_PATH SOURCE_PATH + REPO rinrab/xdigest + REF "${VERSION}" + SHA512 9bb3ceaca9a3cf35b5dd562589158dc50ad3692c3d17d4b39e1f4a36a00861e30913de5ae3052836deb3ef76a45ad69c7822e2fb14a27c6d73dfcd6115a76d15 + HEAD_REF trunk +) + +vcpkg_check_features( + OUT_FEATURE_OPTIONS FEATURE_OPTIONS + FEATURES + asm USE_ASM +) + +if (VCPKG_TARGET_IS_WINDOWS AND USE_ASM) + vcpkg_find_acquire_program(NASM) + list(APPEND OPTIONS "-DCMAKE_ASM_NASM_COMPILER=${NASM}") +endif() + +vcpkg_cmake_configure( + SOURCE_PATH "${SOURCE_PATH}" + OPTIONS + -DENABLE_TESTS=OFF + ${FEATURE_OPTIONS} + ${OPTIONS} +) +vcpkg_cmake_install() +vcpkg_copy_pdbs() +vcpkg_fixup_pkgconfig() +vcpkg_cmake_config_fixup(CONFIG_PATH "lib/cmake/xdigest") + +file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include") + +vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE") diff --git a/ports/xdigest/vcpkg.json b/ports/xdigest/vcpkg.json new file mode 100644 index 00000000000000..cb04dcedc82855 --- /dev/null +++ b/ports/xdigest/vcpkg.json @@ -0,0 +1,26 @@ +{ + "name": "xdigest", + "version": "0.3.0", + "description": "Extremely fast digest algorithms packaged into a lightweight library.", + "homepage": "https://github.com/rinrab/xdigest", + "license": "Apache-2.0", + "dependencies": [ + { + "name": "vcpkg-cmake", + "host": true + }, + { + "name": "vcpkg-cmake-config", + "host": true + } + ], + "default-features": [ + "asm" + ], + "features": { + "asm": { + "description": "Assembly-backed implementation for maximum performance.", + "supports": "!(windows & arm) & !android" + } + } +} diff --git a/versions/baseline.json b/versions/baseline.json index 9449822978fecc..cca82c5e988249 100644 --- a/versions/baseline.json +++ b/versions/baseline.json @@ -10832,6 +10832,10 @@ "baseline": "0.4.2", "port-version": 1 }, + "xdigest": { + "baseline": "0.3.0", + "port-version": 0 + }, "xerces-c": { "baseline": "3.3.0", "port-version": 0 diff --git a/versions/x-/xdigest.json b/versions/x-/xdigest.json new file mode 100644 index 00000000000000..0f49fd45169a23 --- /dev/null +++ b/versions/x-/xdigest.json @@ -0,0 +1,9 @@ +{ + "versions": [ + { + "git-tree": "d57a52c9ad30ded8e6a64bcb276b6ca07ef8645a", + "version": "0.3.0", + "port-version": 0 + } + ] +}