CMake and Conan: past, present and future - Diego Rodriguez-Losada - Meeting C++ 2023

Поділитися
Вставка
  • Опубліковано 26 сер 2024
  • CMake and Conan: past, present and future - Diego Rodriguez-Losada - Meeting C++ 2023
    From legacy variable-based dependencies to Common Package Specification (CPS)
    CMake and Conan have been continuously evolving since their origin. Specifically, dependency management in CMake has evolved from using variables defined in find modules, to using usage requirements in imported targets defined in config files. More recently, toolchain files, CMake presets, the new CMake dependency providers and the preliminary work towards a Common Package Specification (CPS) are creating new integration possibilities. In parallel to this, the Conan package manager and CMake integrations have also greatly changed over years to provide an improved and transparent CMake integration and better developer experience.
    This talk will quickly review the past approaches, their pitfalls, and how modern CMake and Conan integrations have improved over them:
    From variables, to targets, to transparent targets integration with modern Conan generators
    Better separation of concerns to align binary configurations using CMake toolchains
    Improving the developer experience with CMake presets
    The new CMake-Conan integration using CMake’s new dependency providers feature for transparent installation of dependencies
    The talk will finalize with an overview of ongoing work over a Common Package Specification (CPS) proposal, how CMake and Conan already have early partial implementations, and it will finish summarizing future steps.

КОМЕНТАРІ • 11

  • @richjohnson8261
    @richjohnson8261 6 місяців тому +5

    I hope to see more example and tutorial resources for conan v2 and cmake on the web. It seems lacking at this time. I really struggle to get a new project started. For example, bringing Fakeit into my project is a challenge perhaps because it is a header-only. Not sure.

    • @MsJavaWolf
      @MsJavaWolf 3 місяці тому

      I spent the whole day trying to configure a Qt project, I'm still not done xD

  • @dmitryyudin4990
    @dmitryyudin4990 7 місяців тому +1

    Very informative talk. Thank you soo much!

  • @shaulfridman4444
    @shaulfridman4444 5 місяців тому

    Great talk, thanks 🙏

  • @GaryOberbrunner
    @GaryOberbrunner 7 місяців тому +2

    Is there a repo with the demo you're giving in this talk? I'm trying to set up a new project using conan2 and cmake with cmake as the driver, but cannot figure out how to make a single "cmake" command work like in your first demo.

    • @andyhome5009
      @andyhome5009 2 місяці тому

      I would like to know this as well. I can’t find this example in the repository

  • @zxcaaq
    @zxcaaq 7 місяців тому

    thanks for the talk but I need to be able to take cmake project and output the actual fucking command that is used to compile it. gcc clang etc..

    • @Mindfak224
      @Mindfak224 3 місяці тому

      did you try this?
      mkdir build
      cd build
      cmake .. (path to your sourcecode)
      cmake --build .
      CMake is the easiest thing there is. There is only configuring and building. If it doesn't build then your config is wrong. you do not have to care about the compiler since this is handled by the generator

    • @blipojones2114
      @blipojones2114 28 днів тому

      The calmest c++ dev

    • @dragoscosma84
      @dragoscosma84 20 годин тому

      @@Mindfak224 the funny thing is, there are development environments in which something built by cmake is used, but it is not used in the same way the cmake project developers are using it.
      you can have some binary built by the "generator" but i am debugging a version of the project that builds the binary, in some way, i dont want to sit around until the whole thing is built and i just want to "compiler,linker" command that builds that target.