vcpkg/ports/parmetis/portfile.cmake
Billy O'Neal 63d08e949d
[gklib,metis,parmetis] Update sources for metis et al. to GitHub (#26020)
* Remove bogus arguments in the `vcpkg create` template.

* [gklib] Add new port in support of metis and parmetis.

New port checklist:
* Review the code :)
* Check the name against https://repology.org/ There are 2 packages, both of which seem to be the same thing
* Check the name against Bing/Google. It's the first entry.
* Check the source code for optional `find_package`s There are none.
* Check that the versioning scheme and license match what upstream says They have none.
* Check that the source code comes from the upstream project's authoritative source. We did.
* Check that the generated usage is accurate.
* Check that the reported license is accurate. We hope so.

* [metis] Update source to github.

Resolves https://github.com/microsoft/vcpkg/issues/25764

Competes with https://github.com/microsoft/vcpkg/pull/25953

* [parmetis] Update source to github.

* Add licenses.

* Fix GKlib case.

* Fix metis install.
2022-08-03 18:59:36 -07:00

28 lines
871 B
CMake

vcpkg_check_linkage(ONLY_STATIC_LIBRARY)
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO KarypisLab/ParMETIS
REF 44fadbf58c71a74b39abb110a7691355d2a760ca
SHA512 d07e2ccb358948b728be3d282841ad42a8358908a4f1ab3342d4c3016e71a06c1b5966640a06e713f4c773365d7dba4f0c68795d615802f3af07194c0778f362
PATCHES
build-fixes.patch
)
vcpkg_cmake_configure(
SOURCE_PATH "${SOURCE_PATH}"
OPTIONS
-DSHARED=OFF
)
vcpkg_cmake_install()
vcpkg_copy_pdbs()
vcpkg_cmake_config_fixup()
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
file(INSTALL "${SOURCE_PATH}/LICENSE" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
file(WRITE "${CURRENT_PACKAGES_DIR}/share/${PORT}/usage" [=[
parmetis provides CMake targets:
find_package(parmetis CONFIG REQUIRED)
target_link_libraries(main PRIVATE parmetis)
]=])