Skip to content

Library name difference between conan hosted package and provided by CMake #951

@pblxptr

Description

@pblxptr

Hello, I'm using mqtt_cpp in my project. While developing I've been using it through conan package which is here: https://conan.io/center/redboltz-mqtt_cpp

but when I deliver the whole product to my target I build it using Yocto ecosystem.
In Yocto I've defined a recipe that downloads sources, compiles it, and puts in the rootfs and that's fine.

The problem is that when you look at "Use it" section on conan.io it says, that in order to use this package you have to use:
find_package(mqtt_cpp) and then link to mqtt_cpp::mqtt_cpp

but when you look at the "Usage in cmake project" section on github it says that you should use:
find_package(mqtt_cpp_iface REQUIRED) and link to mqtt_cpp_iface::mqtt_cpp_iface

Do you see the difference in names?

This creates confusion and because of this, depending on which suggestion I use, it makes the other target unable to build.
Why is there such confusion?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions