<html><head><style type='text/css'>p { margin: 0; }</style></head><body><div style='font-family: times new roman,new york,times,serif; font-size: 12pt; color: #000000'>Hi,<br><br>If you do:<br><br>CC=icc ccmake ../<br><br>it will work. Note this is all one line, without a semi-colon. <br><br>As for the rest, I'll let somebody else answer.<br><br><hr id="zwchr"><div style="color:#000;font-weight:normal;font-style:normal;text-decoration:none;font-family:Helvetica,Arial,sans-serif;font-size:12pt;"><b>From: </b>"Mohammad Mirzadeh" &lt;mirzadeh@gmail.com&gt;<br><b>To: </b>cmake@cmake.org<br><b>Sent: </b>Thursday, May 10, 2012 8:21:23 PM<br><b>Subject: </b>[CMake] Intel compilers<br><br><div dir="ltr">Hi,<div><br></div><div>I have just started using CMake for my projects and have some problems getting it do exactly the things I want. So these are couple of&nbsp;questions&nbsp;I have:</div><div><br></div><div>1) How can I change the compiler from GNU g++ to my&nbsp;preferred&nbsp;compiler, in this case intel's icc? I have tried CC=icc; ccmake ../ but that again defaults to g++ and picks up wrong compiler flags</div>

<div><br></div><div>2) When I use the -ipo flag for icc, intel compiler&nbsp;complains&nbsp;that there are unresolved&nbsp;references&nbsp;whereas if I&nbsp;omit&nbsp;that, or just use g++, I don't have linking problems. Does the order of compilation (except main) matter when using target_link_libraries?</div>

<div><br></div><div>3) How can I change from creating static libraries to just simply create object files and link to them?&nbsp;</div><div><br></div><div>Thanks</div><div><br></div><div><br></div></div>
<br>--<br><br>Powered by www.kitware.com<br><br>Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html<br><br>Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ<br><br>Follow this link to subscribe/unsubscribe:<br>http://www.cmake.org/mailman/listinfo/cmake</div><br></div></body></html>