<div class="gmail_quote">On Tue, Feb 24, 2009 at 6:45 PM, Neal Meyer <span dir="ltr"><<a href="mailto:nmeyer@dottedzebra.com">nmeyer@dottedzebra.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Philip,<div><br></div><div>Ok... so it works with the Build_Type thing set, but now with out it. I also I'm using XCode sometimes and it doesn't use the linker flags at all.</div></blockquote><div><br>set(CMAKE_EXE_LINKER_FLAGS "-L/no/build/type") ?<br>
<br>Don't know much about xcode, unfortunately. Post a clear example of what you're trying to do and what Xcode isn't doing for you and hopefully someone else can help with that.<br><br><br></div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div><font color="#888888">-Neal</font><div class="Ih2E3d"><br><br><div class="gmail_quote">
<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div class="gmail_quote"><div>
</div><div><br>It could be something simple like<br>1. The CMAKE_EXE_LINKER_FLAGS_<config> variable is somehow not in scope when you're calling add_executable()<br>2. Setting CMAKE_EXE_LINKER_FLAGS_MinSizeRel (uppercase config names seems to be the only thing that works for me).<br>
3. You forgot to set CMAKE_BUILD_TYPE at configure time<br><br>Could you try the following small CMakeLists.txt on your system and see if it works OK?<br><br>====<br>
project(Foo)<br>
cmake_minimum_required(VERSION 2.6)<br>
<br>
set(CMAKE_EXE_LINKER_FLAGS_DEBUG "-L/FOO_DEBUG_OK")<br>
set(CMAKE_EXE_LINKER_FLAGS_RELEASE "-L/FOO_RELEASE_OK")<br>
set(CMAKE_EXE_LINKER_FLAGS_MINSIZEREL "-L/FOO_MINSIZEREL_OK")<br>
set(CMAKE_EXE_LINKER_FLAGS_RELWITHDEBINFO "-L/FOO_RELWITHDEBINFO_OK")<div><br>
<br>
add_executable(foo foo.cc)<br></div>
====<br>cmake -DCMAKE_BUILD_TYPE=Debug<br></div></div><br><br clear="all"><br>-- <br><font color="#888888">Philip Lowman<br>
</font></blockquote></div><br></div></div>
</blockquote></div><br><br clear="all"><br>-- <br>Philip Lowman<br>