<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">

<head>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii">
<meta name=Generator content="Microsoft Word 12 (filtered medium)">
<style>
<!--
 /* Font Definitions */
 @font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
 /* Style Definitions */
 p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
p
        {mso-style-priority:99;
        mso-margin-top-alt:auto;
        margin-right:0in;
        mso-margin-bottom-alt:auto;
        margin-left:0in;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
span.EmailStyle18
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;}
@page Section1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.Section1
        {page:Section1;}
-->
</style>
<!--[if gte mso 9]><xml>
 <o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
 <o:shapelayout v:ext="edit">
  <o:idmap v:ext="edit" data="1" />
 </o:shapelayout></xml><![endif]-->
</head>

<body lang=EN-US link=blue vlink=purple>

<div class=Section1>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>Hi Elizabeta,<o:p></o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p>&nbsp;</o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>Just adding the generated *.h and *_i.c to add_library worked
for me.<b><o:p></o:p></b></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p>&nbsp;</o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>--<o:p></o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>Daniel<o:p></o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p>&nbsp;</o:p></span></p>

<div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in'>

<p class=MsoNormal><b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>From:</span></b><span
style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'> elizabeta petreska
[mailto:elizabeta.petreska@gmail.com] <br>
<b>Sent:</b> Thursday, June 11, 2009 11:52 PM<br>
<b>To:</b> Daniel Tavares<br>
<b>Cc:</b> CMake ML<br>
<b>Subject:</b> Re: [CMake] ATL support<o:p></o:p></span></p>

</div>

<p class=MsoNormal><o:p>&nbsp;</o:p></p>

<p class=MsoNormal style='margin-bottom:12.0pt'>Hi Daniel<br>
<br>
I tried to add_custom_command to compile the idl file, and then add the
generated files to add_library. It&nbsp; obviously does not work when I just
put the idl file with the rest of my sources :)<br>
It seems to work this way even can't tell for sure cause I am total newbie to
COM and ATL. <br>
I'm not sure which generated files to add to add_library , all or just
ComProba1.tlb and ComProba1_i.c<br>
<br>
ADD_CUSTOM_COMMAND(<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
OUTPUT &quot;${CMAKE_BINARY_DIR}/ComProba1.h&quot;
&quot;${CMAKE_BINARY_DIR}/ComProba1.tlb&quot; &quot;${CMAKE_BINARY_DIR}/ComProba1_i.c&quot;
&quot;${CMAKE_BINARY_DIR}/ComProba1_p.c&quot;&nbsp;&nbsp;
&quot;${CMAKE_BINARY_DIR}/dlldata.c&quot;<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
COMMAND&nbsp; midl.exe ${CMAKE_SOURCE_DIR}/ComProba1.idl<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
DEPENDS &quot;${CMAKE_SOURCE_DIR}/ComProba1.idl&quot; )&nbsp;&nbsp;
&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <br>
&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <br>
&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <br>
&nbsp;ADD_LIBRARY(ComProba1 SHARED<br>
&nbsp;&nbsp; ${R_SRCS}&nbsp;<br>
&nbsp;&nbsp; &quot;${CMAKE_BINARY_DIR}/ComProba1.tlb&quot;<br>
&nbsp;&nbsp; &quot;${CMAKE_BINARY_DIR}/ComProba1_i.c&quot;&nbsp;<br>
&nbsp; )&nbsp;&nbsp;&nbsp; <o:p></o:p></p>

<div>

<p class=MsoNormal>On Thu, Jun 11, 2009 at 7:59 PM, Daniel Tavares &lt;<a
href="mailto:daniel.tavares@slipg8.com">daniel.tavares@slipg8.com</a>&gt;
wrote:<o:p></o:p></p>

<div>

<div>

<p><span style='font-size:11.0pt;color:#1F497D'>I&#8217;m having similar issues.
Although I tried removing the \&#8221; or the entire CMAKE_INTDIR=\&#8221;Debug\&#8221;,
mentioned on <a href="http://www.mail-archive.com/cmake@cmake.org/msg16041.html"
target="_blank">this</a> post, but it didn&#8217;t make any difference.</span><o:p></o:p></p>

<p><span style='font-size:11.0pt;color:#1F497D'>&nbsp;</span><o:p></o:p></p>

<p><span style='font-size:11.0pt;color:#1F497D'>This is what I get when I try
to build a project that uses ATL</span><o:p></o:p></p>

<p><span style='font-size:11.0pt;color:#1F497D'>&nbsp;</span><o:p></o:p></p>

<p><span style='font-size:8.0pt;font-family:"Courier New"'>1&gt;Creating Type
Library...</span><o:p></o:p></p>

<p><span style='font-size:8.0pt;font-family:"Courier New"'>1&gt;midl : command
line warning MIDL1009 : unknown argument ignored
&quot;..\..\..\..\foo\bar\test.idl&quot;</span><o:p></o:p></p>

<p><span style='font-size:8.0pt;font-family:"Courier New"'>1&gt;Processing
Debug\&quot;&quot;</span><o:p></o:p></p>

<p><span style='font-size:8.0pt;font-family:"Courier New"'>1&gt;Debug&quot;&quot;</span><o:p></o:p></p>

<p><span style='font-size:8.0pt;font-family:"Courier New"'>1&gt;c1 : fatal
error C1083: Cannot open source file: 'Debug&quot;&quot;': Invalid argument</span><o:p></o:p></p>

<p><span style='font-size:8.0pt;font-family:"Courier New"'>1&gt;midl : command
line error MIDL1003 : error returned by the C preprocessor (2)</span><o:p></o:p></p>

<p><span style='font-size:11.0pt;color:#1F497D'>&nbsp;</span><o:p></o:p></p>

<p><span style='font-size:11.0pt;color:#1F497D'>--</span><o:p></o:p></p>

<p><span style='font-size:11.0pt;color:#1F497D'>Daniel</span><o:p></o:p></p>

<p><span style='font-size:11.0pt;color:#1F497D'>&nbsp;</span><o:p></o:p></p>

<div style='border:none;border-top:solid windowtext 1.0pt;padding:3.0pt 0in 0in 0in;
border-color:-moz-use-text-color -moz-use-text-color'>

<p><b><span style='font-size:10.0pt'>From:</span></b><span style='font-size:
10.0pt'> <a href="mailto:cmake-bounces@cmake.org" target="_blank">cmake-bounces@cmake.org</a>
[mailto:<a href="mailto:cmake-bounces@cmake.org" target="_blank">cmake-bounces@cmake.org</a>]
<b>On Behalf Of </b>elizabeta petreska<br>
<b>Sent:</b> Thursday, June 11, 2009 3:26 AM<br>
<b>To:</b> CMake ML<br>
<b>Subject:</b> Re: [CMake] ATL support</span><o:p></o:p></p>

</div>

<div>

<div>

<p>&nbsp;<o:p></o:p></p>

<p style='margin-bottom:12.0pt'>&nbsp;<o:p></o:p></p>

<div>

<p>On Thu, Jun 11, 2009 at 8:55 AM, Eric Noulard &lt;<a
href="mailto:eric.noulard@gmail.com" target="_blank">eric.noulard@gmail.com</a>&gt;
wrote:<o:p></o:p></p>

<p>2009/6/11 elizabeta petreska &lt;<a
href="mailto:elizabeta.petreska@gmail.com" target="_blank">elizabeta.petreska@gmail.com</a>&gt;:<o:p></o:p></p>

<div>

<div>

<p style='margin-bottom:12.0pt'>&gt;<br>
&gt;<br>
&gt; On Thu, Jun 11, 2009 at 8:43 AM, elizabeta petreska<br>
&gt; &lt;<a href="mailto:elizabeta.petreska@gmail.com" target="_blank">elizabeta.petreska@gmail.com</a>&gt;
wrote:<br>
&gt;&gt;<br>
&gt;&gt; The ATL (Active Template Library) is project template in Visual Studio<br>
&gt;&gt; that simplifies creation of COM objects.<br>
&gt;&gt; <a href="http://en.wikipedia.org/wiki/Active_Template_Library"
target="_blank">http://en.wikipedia.org/wiki/Active_Template_Library</a><br>
&gt;&gt;<br>
&gt;&gt; I was hoping that in Cmake exsist some variable for ATL like for MFC
i.e<br>
&gt;&gt; CMAKE_MFC_FLAG<br>
&gt;<br>
&gt;<br>
&gt; the thread that I mentioned<br>
&gt; <a href="http://www.mail-archive.com/cmake@cmake.org/msg09945.html"
target="_blank">http://www.mail-archive.com/cmake@cmake.org/msg09945.html</a><o:p></o:p></p>

</div>

</div>

<p>Ok Thank you for those informations,<br>
however I would personnally be out of this question loop because I'm<br>
not a day-to-day Windows user :-(<br>
<br>
May be that's why I didn't understand the question in the first place :-)<br>
<br>
Good luck for help with others.<br>
<span style='color:#888888'><br>
--<br>
Erk</span><o:p></o:p></p>

</div>

<p><br>
Ok now I came to the problem as described in the following post<br>
<a href="http://www.mail-archive.com/cmake@cmake.org/msg16041.html"
target="_blank">http://www.mail-archive.com/cmake@cmake.org/msg16041.html</a><o:p></o:p></p>

</div>

</div>

</div>

</div>

<p class=MsoNormal><br>
_______________________________________________<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a
href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the CMake FAQ at: <a
href="http://www.cmake.org/Wiki/CMake_FAQ" target="_blank">http://www.cmake.org/Wiki/CMake_FAQ</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.cmake.org/mailman/listinfo/cmake" target="_blank">http://www.cmake.org/mailman/listinfo/cmake</a><o:p></o:p></p>

</div>

<p class=MsoNormal><o:p>&nbsp;</o:p></p>

</div>

</body>

</html>