Looks like I may have missed a couple options (-R and -KPIC).  As far as I can tell, the compiler should work exactly like the already supported SunOS version of the compiler.  Just copy the options from the already included 
SunOS.cmake file, which are almost the same as the file I sent you.<br><br><div><span class="gmail_quote">On 10/23/06, <b class="gmail_sendername">Brad King</b> &lt;<a href="mailto:brad.king@kitware.com">brad.king@kitware.com
</a>&gt; wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Doug Henry wrote:<br>&gt; I am trying to use the sun studio compiler under linux and I am having a
<br>&gt; terrible time getting past the cmake compiler tests.&nbsp;&nbsp;I'm not sure what<br>&gt; the error messages are telling me, but it looks like some incorrect<br>&gt; flags are being passed in.&nbsp;&nbsp;I extracted the short test program from
<br>&gt; CMakeTestCXXCompiler.cmake and it of course compiles/links just fine<br>&gt; with CC.&nbsp;&nbsp;Output follows:<br>[snip]<br>&gt; -- Check for working CXX compiler: /opt/sun/sunstudiomars/bin/CC -- broken<br>[snip]<br>&gt; /opt/sun/sunstudiomars/bin/CC&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; -fPIC
<br>&gt; &quot;CMakeFiles/cmTryCompileExec.dir/testCXXCompiler.o&quot;&nbsp;&nbsp; -o<br>&gt; cmTryCompileExec -rdynamic<br>&gt; CC: Warning: Option -fPIC passed to ld, if ld is invoked, ignored otherwise<br>&gt; CC: Warning: Option -rdynamic passed to ld, if ld is invoked, ignored
<br>&gt; otherwise<br>&gt; /usr/bin/ld: bad -rpath option<br><br>AFAIK no one has tried CMake with this compiler before.<br><br>CMake is invoking the compiler assuming that it accepts the flags other<br>Linux compilers (such as GNU and Intel) accept.&nbsp;&nbsp;Nothing has told it
<br>otherwise.&nbsp;&nbsp;You'll have to setup a platform file to configure this<br>compiler.&nbsp;&nbsp;Look in share/CMake/Modules/Platform for similar files.&nbsp;&nbsp;For<br>this case there should be a file called Linux-CC.cmake that overrides<br>
some of the settings in Linux.cmake.&nbsp;&nbsp;Some of the settings in<br>Modules/CMakeCXXInformation.cmake may need to be overridden also.<br><br>If you get this working we'll include the files in upstream CMake to<br>make support for the compiler permanent.
<br><br>FYI, supported platforms all have nightly testing:<br><br><a href="http://public.kitware.com/dashboard.php?name=cmake">http://public.kitware.com/dashboard.php?name=cmake</a><br><br>If a platform isn't here it probably doesn't work.
<br><br>-Brad<br></blockquote></div><br>