<div dir="ltr">Thank you Parag. <div><br></div><div>I realized that I was missing the following:<div><br></div><div><span style="color:rgb(128,128,0)">set</span>(Boost_USE_STATIC_LIBS<span style="color:rgb(192,192,192)"> </span>True)</div><div><br></div><div><div>And also I needed to set BOOST_ROOT instead of BOOST_INCLUDEDIR.</div></div><div><br></div><div>Regards,</div><div><br></div><div>Daniel</div><div><br></div></div></div><div class="gmail_extra"><br><div class="gmail_quote">2015-02-20 17:20 GMT+00:00 Parag Chandra <span dir="ltr"><<a href="mailto:parag@ionicsecurity.com" target="_blank">parag@ionicsecurity.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">



<div style="word-wrap:break-word;color:rgb(0,0,0);font-size:14px;font-family:Calibri,sans-serif">
<div>
<div>
<div>Hi Daniel,</div>
<div><br>
</div>
<div>I had some trouble with this myself a while back. You may want to refer to the Boost module documentation for some help:</div>
<div><br>
</div>
<div><a href="http://www.cmake.org/cmake/help/v3.1/module/FindBoost.html" target="_blank">http://www.cmake.org/cmake/help/v3.1/module/FindBoost.html</a></div>
<div><br>
</div>
<div>There are some additional flags you can set which will help CMake locate Boost for you; I’m sorry I don’t remember exactly which ones I set to locate it on Windows. In the end though, I needed to locate boost for many operating systems, so I compiled boost
 with system layout into individual configuration/architecture/operating system subdirectories, and then using the generic ‘find_library’ command.</div>
<div>
<div><br>
</div>
<br>
<strong style="font-family:Calibri">Parag Chandra<br>
</strong><span style="font-family:Calibri">Software Engineer, Mobile Team</span><br style="font-family:Calibri">
<span style="font-family:Calibri">Mobile: <a href="tel:%2B1.919.824.1410" value="+19198241410" target="_blank">+1.919.824.1410</a></span><br style="font-family:Calibri">
<br style="font-family:Calibri">
<a href="https://ionic.com" style="font-family:Calibri" target="_blank"><img border="0" src="https://www.ionicsecurity.com/IonicSigHz.png"></a><span style="font-family:Calibri"> </span><br style="font-family:Calibri">
<br style="font-family:Calibri">
<span style="font-family:Calibri">Ionic Security Inc.</span><br style="font-family:Calibri">
<span style="font-family:Calibri">1170 Peachtree St. NE STE 400, Atlanta, GA 30309</span>
<table style="color:rgb(51,51,51);font-family:Arial,sans-serif;font-size:14px;line-height:20px;background-color:rgb(255,255,255)">
<tbody>
<tr>
<td nowrap valign="middle"><br>
</td>
<td nowrap valign="top"><br>
</td>
<td nowrap valign="middle"><br>
</td>
<td nowrap valign="middle"><br>
</td>
</tr>
<tr>
<td width="5" nowrap valign="middle"><br>
</td>
<td width="70" nowrap valign="top"><br>
</td>
<td width="5" nowrap valign="middle"><br>
</td>
<td width="287" nowrap valign="top"><br>
</td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
<div><br>
</div>
<span>
<div style="font-family:Calibri;font-size:11pt;text-align:left;color:black;BORDER-BOTTOM:medium none;BORDER-LEFT:medium none;PADDING-BOTTOM:0in;PADDING-LEFT:0in;PADDING-RIGHT:0in;BORDER-TOP:#b5c4df 1pt solid;BORDER-RIGHT:medium none;PADDING-TOP:3pt">
<span style="font-weight:bold">From: </span>Daniel Sáez <<a href="mailto:danst.18@gmail.com" target="_blank">danst.18@gmail.com</a>><br>
<span style="font-weight:bold">Date: </span>Friday, February 20, 2015 at 11:31 AM<br>
<span style="font-weight:bold">To: </span>"<a href="mailto:cmake@cmake.org" target="_blank">cmake@cmake.org</a>" <<a href="mailto:cmake@cmake.org" target="_blank">cmake@cmake.org</a>><br>
<span style="font-weight:bold">Subject: </span>[CMake] Cmake error when adding Boost library<br>
</div>
<div><br>
</div>
<div>
<div>
<div dir="ltr">
<h1 style="margin:0px 0px 0.5em;padding:0px;border:0px;font-size:22px;line-height:1.3;font-family:'Helvetica Neue',Helvetica,Arial,sans-serif"><span class="">
<p style="font-weight:normal;margin:0px 0px 1em;padding:0px;border:0px;font-size:15px;clear:both;line-height:19.5px">
Hello,</p>
<p style="font-weight:normal;margin:0px 0px 1em;padding:0px;border:0px;font-size:15px;clear:both;line-height:19.5px">
I am trying to add Boost library to my project using the CMakeLists.txt in the follwing way:</p>
</span><pre style="white-space:pre-wrap;font-weight:normal;line-height:normal;margin-top:0px;padding:5px;border:0px;font-size:13px;overflow:auto;width:auto;max-height:600px;font-family:Consolas,Menlo,Monaco,'Lucida Console','Liberation Mono','DejaVu Sans Mono','Bitstream Vera Sans Mono','Courier New',monospace,sans-serif;color:rgb(57,51,24);word-wrap:normal;background-color:rgb(238,238,238)"><code style="margin:0px;padding:0px;border:0px;font-family:Consolas,Menlo,Monaco,'Lucida Console','Liberation Mono','DejaVu Sans Mono','Bitstream Vera Sans Mono','Courier New',monospace,sans-serif;white-space:inherit"><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,139)">set</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">(</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">BOOST_INCLUDEDIR </span><span style="margin:0px;padding:0px;border:0px;color:rgb(128,0,0)">"C:/boost_1_57_0"</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">)</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)"></span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,139)">set</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">(</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">BOOST_LIBRARYDIR </span><span style="margin:0px;padding:0px;border:0px;color:rgb(128,0,0)">"C:/boost_1_57_0/stage/lib"</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">)</span><span class=""><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">

find_package</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">(</span><span style="margin:0px;padding:0px;border:0px;color:rgb(43,145,175)">Boost</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)"> </span><span style="margin:0px;padding:0px;border:0px;color:rgb(128,0,0)">1.57</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">.</span><span style="margin:0px;padding:0px;border:0px;color:rgb(128,0,0)">0</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)"> COMPONENTS filesystem</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">)</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">
include_directories</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">(</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">$</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">{</span><span style="margin:0px;padding:0px;border:0px;color:rgb(43,145,175)">Boost_INCLUDE_DIRS</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">})</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">
add_executable</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">(</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">test test</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">.</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">cpp</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">)</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">
target_link_libraries</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">(</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">test $</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">{</span><span style="margin:0px;padding:0px;border:0px;color:rgb(43,145,175)">Boost_LIBRARIES</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">})</span></span></code></pre><span class="">
<p style="font-weight:normal;margin:0px 0px 1em;padding:0px;border:0px;font-size:15px;clear:both;line-height:19.5px">
However, I get the followng error: <code style="margin:0px;padding:1px 5px;border:0px;font-size:13px;font-family:Consolas,Menlo,Monaco,'Lucida Console','Liberation Mono','DejaVu Sans Mono','Bitstream Vera Sans Mono','Courier New',monospace,sans-serif;white-space:pre-wrap;background-color:rgb(238,238,238)">LINK
 : fatal error LNK1104: cannot open file 'libboost_filesystem-vc120-mt-1_57.lib'</code></p>
<p style="font-weight:normal;margin:0px 0px 1em;padding:0px;border:0px;font-size:15px;clear:both;line-height:19.5px">
<code style="margin:0px;padding:1px 5px;border:0px;font-size:13px;font-family:Consolas,Menlo,Monaco,'Lucida Console','Liberation Mono','DejaVu Sans Mono','Bitstream Vera Sans Mono','Courier New',monospace,sans-serif;white-space:pre-wrap;background-color:rgb(238,238,238)">libboost_filesystem-vc120-mt-1_57.lib</code> is
 located in the <code style="margin:0px;padding:1px 5px;border:0px;font-size:13px;font-family:Consolas,Menlo,Monaco,'Lucida Console','Liberation Mono','DejaVu Sans Mono','Bitstream Vera Sans Mono','Courier New',monospace,sans-serif;white-space:pre-wrap;background-color:rgb(238,238,238)">stage/lib</code> folder,
 so I don't know what is going on. I am compiling with Visual Studio 2013.</p>
<p style="font-weight:normal;margin:0px 0px 1em;padding:0px;border:0px;font-size:15px;clear:both;line-height:19.5px">
Any thoughts?</p>
<p style="font-weight:normal;margin:0px 0px 1em;padding:0px;border:0px;font-size:15px;clear:both;line-height:19.5px">
Thank you,</p>
<p style="font-weight:normal;margin:0px 0px 1em;padding:0px;border:0px;font-size:15px;clear:both;line-height:19.5px">
Daniel</p>
</span></h1>
</div>
</div>
</div>
</span>
</div>

</blockquote></div><br></div>