<div class="gmail_quote">On Tue, Nov 30, 2010 at 5:37 PM, Hicham Mouline <span dir="ltr">&lt;<a href="mailto:hicham@mouline.org">hicham@mouline.org</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">









<div lang="EN-GB" link="blue" vlink="purple">

<div>

<p class="MsoNormal">As boost libraries naming convention doesn&#39;t include in the
lib names whether they are built by msvc9 win32 or x64, I am forced on a winxp
64 box where I hold both versions to have a different lib directory under
boost_root.</p>

<p class="MsoNormal">I set BOOST_ROOT then call FIND_PACKAGE(Boost 1.44
COMPONENTS ...).</p>

<p class="MsoNormal">Am I supposed to detect which of vc9 32bit or 64bit am  I generating
for and then set BOOST_LIBRARYDIR depending on that before calling
FIND_PACKAGE?</p>

<p class="MsoNormal">How do I detect bitness?</p></div></div></blockquote><div><br></div><div>You could try something like this:</div><div><br></div><div><div>include(CheckTypeSize)</div><div>CHECK_TYPE_SIZE(void* SIZEOF_PTR)</div>
<div>message(&quot;size of pointer = ${SIZEOF_PTR}&quot;)</div></div><div><br></div><div>Then if SIZEOF_PTR is 4, you would set BOOST_LIBRARYDIR to be ${BOOST_ROOT}/lib32 and if it is 8, you set it to ${BOOST_ROOT}/lib64.</div>
<div><br></div></div>-- <br>Philip Lowman<br>