Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Provide MetisConfig.cmake #10

Open
gruenich opened this issue May 13, 2020 · 6 comments · May be fixed by #79
Open

Provide MetisConfig.cmake #10

gruenich opened this issue May 13, 2020 · 6 comments · May be fixed by #79

Comments

@gruenich
Copy link

Providing a cmake config file makes it easier to find and use Metis. Metis should create such a config file.
CMake offers some functions to do this without much effort: https://cmake.org/cmake/help/latest/module/CMakePackageConfigHelpers.html

@karypis
Copy link
Contributor

karypis commented Jul 9, 2020

What is the benefit for doing that?

@gruenich
Copy link
Author

gruenich commented Jul 9, 2020

It simplifies the way projects can include and use Metis. If Metis would provide a Metis-cmake.config, all it has to do is to add Find_package(Metis) and if the file is found, all flags and includes are included in the CMake project.
Cf. https://cmake.org/cmake/help/latest/manual/cmake-packages.7.html?highlight=config#config-file-packages

@codecircuit
Copy link

I agree with gruenich. It simplifies the usage a lot. I just implemented that in my PR of METIS here. To use METIS in another CMake configured project you can now just write:

find_package(METIS REQUIRED)
...
target_link_libraries(myproject PUBLIC METIS::metis)

@gruenich
Copy link
Author

@codecircuit Creating a merge request here seems more helpful to me. Then karpys gets a proper diff. Also from a copyright point of view, for projects where I am maintainer, I would prefer an MR instead of copying code myself.
Could you be so kind?

@spiani
Copy link

spiani commented Jul 6, 2023

Are there any news on this? I was trying to write a Python library that embeds some C++ code that calls metis and a cmake config file would make my life easier. At a first glance, the code written by @codecircuit seems still compatible with the current version of the file. Could it be implemented?

@LecrisUT
Copy link

See #79

@LecrisUT LecrisUT linked a pull request Oct 26, 2023 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants