Search code examples
c++clinuxpackage-managersconan

Building a project with Conan C/C++ Package Manager


Hy all,

I want to build a project with Conan C/C++ Package manager, i have some issues... it can't find the Conanfile but the Conanfile exists! ...

CentOs ...

I have a folder "mytimer" :

[user mytimer]$ ls
build  CMakeLists.txt  Conanfile.txt  LICENSE  README.md  timer.cpp

and I want to build in "build" folder :

[user mytimer]$ cd build
[user build]$ conan install --file ../Conanfile.txt ..
**ERROR: Conanfile not found!**

How can I fix this ? thank you :)


Solution

  • You have an extra leading path. Use either:

    [user build]$ conan install --file ../Conanfile.txt
    

    or

    [user build]$ conan install --file Conanfile.txt ..