[CMake] Question about add_library with IMPORTED
Alexander Neundorf
a.neundorf-work at gmx.net
Tue Mar 9 14:03:31 EST 2010
On Tuesday 09 March 2010, Benoit Thomas wrote:
> Hello,
>
> I have a library which is a Visual Studio project only (which will be
> converted to cmake in the future).
>
> In my current cmake project, I try adding this library using the
> following code:
>
> set (IMPORTED_LOCATION "../farfaraway/lib")
> add_library ("mylib" STATIC IMPORTED)
Does that work ?
I thought you have to set target properties.
How about this:
add_library(mylib UNKNOWN IMPORTED)
set_target_properties(mylib PROPERTIES IMPORTED_LOCATION "../faraway/foo.lib"
Alex
More information about the CMake
mailing list