[CMake] Specifying name of library file on CMake command line?

Kyle Edwards kyle.edwards at kitware.com
Mon Jun 17 09:49:39 EDT 2019


On Mon, 2019-06-17 at 13:47 +0000, Osman Zakir wrote:
> I want to know how to specify the name of a library I file I want to
> link against.  How do I do this?  I wanted to build a library with a
> static runtime and static libs; it requires linking against a Boost
> library which I did build with static runtime but when I tried to
> build it, I had linker errors because the dynamic version of the
> library was used instead of the static one.  I want to somehow make
> it use the static one.  So yeah, how do I do this?  Is there a way?

Are you using the FindBoost module?

https://cmake.org/cmake/help/v3.14/module/FindBoost.html​

Kyle


More information about the CMake mailing list