scivision / mumps

MUMPS via CMake
http://mumps-solver.org
MIT License
115 stars 46 forks source link

Change name of exported cmake configuration files #31

Closed Rickbude closed 2 years ago

Rickbude commented 2 years ago

In "Config mode", CMake's find_package will look for two files:

<lowercasePackageName>-config.cmake and <PackageName>Config.cmake

(See CMake documentation: https://cmake.org/cmake/help/latest/command/find_package.html)

However, the MUMPS configuration files were named "MUMPS-config.cmake", which is none of the above.

This commit changes the names of the configuration files to MUMPSConfig.cmake and MUMPSConfigVersion.cmake. CMake now seems to correctly pick up these configuration files in "Config mode".

scivision commented 2 years ago

Thanks! I like the generic PROJECT_NAME as I reuse between projects. Now I need to fix other projects I made this mistake in! Thanks.

scivision commented 2 years ago

For general reference, before this change, MUMPS would never have been found in fast, reliable find_package(MUMPS CONFIG). Now, MUMPS can be found that way and via the slower, less reliable find_package(MUMPS)