Automatically created conanfile.txt shows different generators
See original GitHub issueI’m using the CMake wrapper by downloading the conan.cmake
-file and I’m calling
conan_cmake_run(REQUIRES <PACKAGE>/<VERSION>
BASIC_SETUP
CMAKE_TARGETS
GENERATORS cmake_find_package cmake_paths
OPTIONS ${CONAN_OPTIONS}
BUILD missing
)
This leads to the creation of several files in my output folder. The CMake output shows:
conanfile.txt:
Generator cmake created conanbuildinfo.cmake
conanfile.txt:
Generator txt created conanbuildinfo.txt
conanfile.txt:
Generator cmake_paths created conan_paths.cmake
conanfile.txt:
Generator cmake_find_package created Find<PACKAGE>.cmake
conanfile.txt:
Generated conaninfo.txt
conanfile.txt:
Generated graphinfo
In my output folder I find the conanfile.txt
, which is “the recipe” created by the wrapper for my <PACKAGE>
, I guess. Now when I open this file, I see the following:
[generators]
cmake
[requires]
<PACKAGE>/<VERSION>
[options]
...
some options
...
[imports]
I was wondering why [generators]
is set to cmake
and not cmake_find_package
and cmake_paths
?
Issue Analytics
- State:
- Created 3 years ago
- Comments:11 (6 by maintainers)
Top Results From Across the Web
Creating a custom generator - Conan Docs
Use the txt generator, that generates a plain text file easy to parse, which you might be able to use. Use conanfile.py data,...
Read more >[question] Problems combining Conan packages with CMake ...
In my top-level CMakeLists.txt -file I use the mentioned CMake Conan ... Automatically created conanfile.txt shows different generators ...
Read more >Introduction to Conan package manager - Kuba Sejdak
Installing packages. Conan packages can be installed in at least three different ways: manually,; automatically with conanfile.txt , ...
Read more >How do I make conan generate a FindXXX.cmake?
Conan donesn't create FindXXX.cmake automatically. ... for all settings conan can handle or library package libraries with different names, ...
Read more >Conan Package Manager for C++ in Practice - YouTube
... and a more complete demo showing how to create and upload a package including different binaries for different platforms to a private ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hi @akalali, Thanks for the feedback, that’s probably something we can do for future releases, anyway, if you want not to load the
conanbuildinfo.cmake
by default you can use theNO_LOAD
argument inconan_cmake_run
(it will be generated but not loaded).I’m closing this as for the future we are moving in the direction of deprecating the use of
conan_cmake_run
and using separate calls toconan_cmake_configure
,conan_cmake_autodetect
andconan_cmake_install
proposed here: https://github.com/conan-io/cmake-conan/pull/310. This is more explicit and can use latest Conan features because you can skip the auto-detection part if you want. Also, that way you can use just what you need without having nothing generated as default.