-
Notifications
You must be signed in to change notification settings - Fork 6
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
Add cantera to conancenter #191
Comments
Thanks for writing this up, @NelDav. I was not previously familiar with ConanCenter, but I think packaging Cantera here could be beneficial if you're interested in working on it. Several of the other Cantera packages, such as for Gentoo, Fedora, and FreeBSD, are also community maintained. If you haven't already looked at it, our recipe for conda-forge (here) might be of some use in structuring the recipe for Conan. If you have any questions as you're working on this, feel free to ask here! |
That is very nice. Thank you very much for the conda-forge recipe. I will check it. |
During the last few weeks, I made some progress, creating the conan package. The documentation states the following:
|
@speth, do you know a solution to statically link |
You can avoid needing the For |
Thanks for your answer. I think I made some mistakes before. That's why it didn't worked. However, your hint regarding |
Hi @speth, I have annother question. Probably, my bad knowledge about soncs is the problem. However, conan will also perform a debug build for the dependencies and will create |
There's nothing built into our SCons configuration to let you change the name of the libraries being linked to. If you use For |
Thanks for your answer. You are right, using headers only will fix the problem for fmt. I will ask at connancenter, if they have a solution for yaml-cpp. I cannot use the submodule, because the conancenter pipeline will not clone a repository but download an archive. |
I tried modifying the SConstruct file at different locations but still, the linker tries to link - env['CPPDEFINES'] = {}
+ env['CPPDEFINES'] = {'FMT_HEADER_ONLY': 1} - extraEnvArgs = {}
+ extraEnvArgs = {'FMT_HEADER_ONLY': 1} I am lost now. I look forward to your answer on how to do it right. |
Ah, I see the issue with if env["system_fmt"]:
- env["external_libs"].append("fmt")
+ env["external_libs"].append("fmtd")
# Usually need to link to fmt directly because of templated/inlined code that calls
# fmt
- env["cantera_shared_libs"].append("fmt")
+ env["cantera_shared_libs"].append("fmtd") For if env["system_yamlcpp"]:
- env["external_libs"].append("yaml-cpp")
+ env["external_libs"].append("yaml-cppd") Does this not also affect the other library dependencies, like SUNDIALS and HDF5? |
Yes, I already tried that. But unfortunately, the linker will not find certain functions. For now, I deactivated debug builds for the cantera conan package. Maybe we can implement them later.
Probably, but I haven't noticed any problems so far. |
Abstract
Conan is a system developed to add dependencies to c++ applicaitons.
It enables installation of the dependency and has a good integration with cmake.
Motivation
Providing an easy way to use cantera in your c++ applicaiton.
Conan is used by many people to maintian their dependencies.
Description
In order to add cantera to conan, a reciepe has to be written, that descibes the build process.
Cona will then use this reciepe to build cantera.
The reciepe as well as the binaries can then be downloaded by every conan user.
Alternatives
An alternative is
vcpkg
.But we are not limitted to one solution here.
It makes sense to add cantera to vcpkg and conancenter.
But I do not know, hwo to add packages to
vcpkg
.Question
Is it ok for you if I add cantera to conancenter?
The text was updated successfully, but these errors were encountered: