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

1.3.1 fails to configure with maeparser-1.2.1 #37

Open
yurivict opened this issue Sep 21, 2019 · 6 comments
Open

1.3.1 fails to configure with maeparser-1.2.1 #37

yurivict opened this issue Sep 21, 2019 · 6 comments

Comments

@yurivict
Copy link

-- Found Boost: /usr/local/include (found version "1.71.0") found components:  iostreams regex
CMake Error at CMakeLists.txt:25 (find_package):
  By not providing "Findmaeparser.cmake" in CMAKE_MODULE_PATH this project
  has asked CMake to find a package configuration file provided by
  "maeparser", but CMake did not find one.

  Could not find a package configuration file provided by "maeparser" with
  any of the following names:

    maeparserConfig.cmake
    maeparser-config.cmake

  Add the installation prefix of "maeparser" to CMAKE_PREFIX_PATH or set
  "maeparser_DIR" to a directory containing one of the above files.  If
  "maeparser" provides a separate development package or SDK, be sure it has
  been installed.

FreeBSD 12

@d-b-w
Copy link
Collaborator

d-b-w commented Sep 26, 2019

Thanks for the report, @yurivict

@ricrogz
Copy link
Collaborator

ricrogz commented Sep 26, 2019

Hi, @yurivict.

To build coordgenlibs, first you need to build and install maeparser (you can specify the install path adding the flag -DCMAKE_INSTALL_PREFIX=[install path] to the cmake command).

Once that is done, you have to tell CMake where maeparsers ".cmake" files were installed by passing the right path to CMake using the "maeparser_DIR" flag, i.e., adding -Dmaeparser_DIR=[install path]/lib/cmake to your cmake command.

Please let me know if you have any more trouble!

d-b-w pushed a commit that referenced this issue Oct 18, 2019
This aims at improving the way that the maeparser dependency is handled when building coordgen, and also makes it easier to include both in other projects. Also, it provides some documentation on how to build.
I brought in the CMake module we wrote to allow using find_package() to find maeparser compiled libraries, and also added another module to download maeparser from github if the library cannot be found.

Some details:

The maeparser_DIR option now points to the install path, instead of the .cmake files, which was a bit obscure if you don't know how CMake works (this effectively changes the recommended solution from #37).

If maeparser_DIR was specified (if it is not an empty string), maeparser's sources will NOT be used, and cmake will fail (since we expected to find a compiled library).

If there is a copy of maeparser at the download location (inside a maeparser-{version} directory in coordgen's source dir), the download will be skipped, and the already present sources will be built.

A specific branch/tag/commit may be specified to be downloaded. By default, the master branch will be used.

Travis and Appveyor scripts have been updated, since we no longer need to build maeparser in advance.
@ricrogz
Copy link
Collaborator

ricrogz commented Oct 21, 2019

Please note that the behavior I mentioned in my previous comment has been changed in #41.

Please check the README for updated build instructions and notes.

@yurivict
Copy link
Author

yurivict commented Jan 3, 2020

Normally this shouldn't be needed because {prefix}/lib/cmake is a standard location.

@ricrogz
Copy link
Collaborator

ricrogz commented Jan 14, 2020

Normally this shouldn't be needed because {prefix}/lib/cmake is a standard location.

Yes, that is true, but only in case maeparser and coordgen use the same prefix path. In case they are installed into different, non standard prefix paths, coordgen needs to be told where to find maeparser's cmake file.

@yurivict
Copy link
Author

They are installed into the same prefix.

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

No branches or pull requests

3 participants