Skip to content

Cannot build with MSYS2, possibly due to incorrect find of libzmq #645

Open
@themightyoarfish

Description

@themightyoarfish

I'm linking a cmake project against cppzmq 4.7.1, and the build steps fails with

ninja: error: 'libzmq-NOTFOUND', needed by '<binary>.exe', missing and no known rule to make it

I discovered that libzmq is found fine, however the file <prefix>/share/cmake/cppzmq/cppzmqTargets.cmake includes this code

set_target_properties(cppzmq PROPERTIES
  INTERFACE_INCLUDE_DIRECTORIES "${_IMPORT_PREFIX}/include"
  INTERFACE_LINK_LIBRARIES "libzmq"
)

so it is declaring a linked library "libzmq". Imo, this should be "zmq", as the "lib" prefix is automatically added. If I change "libzmq" to just "zmq", the problem goes away.

Is this related to the use of "libzmq" here or here maybe?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions