Fwd: [CMake] MSVC project names
Eric Noulard
eric.noulard at gmail.com
Fri Aug 3 04:25:59 EDT 2007
Another Forget cc CMake-ML...
Complement: When using other CMake macro you should use
the primary name e.g:
TARGET_LINK_LIBRARY(gammu-exe Gammu-Lib)
---------- Forwarded message ----------
From: Eric Noulard <eric.noulard at gmail.com>
Date: 3 août 2007 10:23
Subject: Re: [CMake] MSVC project names
To: Michal Čihař <michal at cihar.com>
2007/8/3, Michal Čihař <michal at cihar.com>:
> Hi
>
> I'm using CMake on Gammu project [1] and now when first user wants to
> natively compile it using MSVC on Windows I came to problems because
> both library and executable projects share same name. Currently result
> of build process is libGammu library and gammu program. This is
> basically done by following:
>
> add_library(Gammu ...)
> add_executable(gammu ...)
>
> What results in having two projects in MSVC both with same name (as
> project names are not case sensitive) and this obviously fails. Is there
> some workaround for this so that I can produce library and executable of
> same name in one build tree?
You should (for example):
add_library(Gammu-Lib ...)
then
set_target_properties(Gammu-Lib PROPERTIES OUTPUT_NAME Gammu)
and/or
add_executable(gammu-exe ...)
set_target_properties(gammu-exe PROPERTIES OUTPUT_NAME gammu)
--
Erk
--
Erk
More information about the CMake
mailing list