<div><span class="gmail_quote">On 12/12/07, <b class="gmail_sendername">Martin Lütken</b> &lt;<a href="mailto:mlu@danware.dk">mlu@danware.dk</a>&gt; wrote:</span><blockquote class="gmail_quote" style="margin:0;margin-left:0.8ex;border-left:1px #ccc solid;padding-left:1ex">







<div>


<p><font size="2">Anyone who knows wheter it&#39;s possible to calculate logarithms in MATH expressions in CMake?</font></p></div></blockquote><blockquote class="gmail_quote" style="margin:0;margin-left:0.8ex;border-left:1px #ccc solid;padding-left:1ex">
<div><p><font size="2">Would like a log2 or alternatively &quot;ln&quot; (natural).<br></font></p></div></blockquote></div><div><br class="webkit-block-placeholder"></div><div>Not directly, no.</div><div><br class="webkit-block-placeholder">
</div><div><br class="webkit-block-placeholder"></div>The CMake MATH EXPR parser handles the following tokens:<div><br class="webkit-block-placeholder"></div><div>Decimal numbers:</div><div><p style="margin: 0.0px 0.0px 0.0px 32.0px; text-indent: -32.0px; font: 14.0px Monaco">
[<span style="color: #0000ff">0-9</span>][<span style="color: #0000ff">0-9</span>]*</p>
<p style="margin: 0.0px 0.0px 0.0px 32.0px; text-indent: -32.0px; font: 14.0px Monaco; min-height: 19.0px"><br></p><div>And the basic C/C++ math, bit-operation and grouping operators:</div><div></div><p style="margin: 0.0px 0.0px 0.0px 32.0px; text-indent: -32.0px; font: 14.0px Monaco">
<span style="color: #891315">&quot;+&quot;</span></p>
<p style="margin: 0.0px 0.0px 0.0px 32.0px; text-indent: -32.0px; font: 14.0px Monaco"><span style="color: #891315">&quot;-&quot;</span></p>
<p style="margin: 0.0px 0.0px 0.0px 32.0px; text-indent: -32.0px; font: 14.0px Monaco"><span style="color: #891315">&quot;*&quot;</span></p>
<p style="margin: 0.0px 0.0px 0.0px 32.0px; text-indent: -32.0px; font: 14.0px Monaco"><span style="color: #891315">&quot;/&quot;</span></p>
<p style="margin: 0.0px 0.0px 0.0px 32.0px; text-indent: -32.0px; font: 14.0px Monaco"><span style="color: #891315">&quot;%&quot;</span></p>
<p style="margin: 0.0px 0.0px 0.0px 32.0px; text-indent: -32.0px; font: 14.0px Monaco"><span style="color: #891315">&quot;\|&quot;</span></p>
<p style="margin: 0.0px 0.0px 0.0px 32.0px; text-indent: -32.0px; font: 14.0px Monaco"><span style="color: #891315">&quot;&amp;&quot;</span></p>
<p style="margin: 0.0px 0.0px 0.0px 32.0px; text-indent: -32.0px; font: 14.0px Monaco"><span style="color: #891315">&quot;^&quot;</span></p>
<p style="margin: 0.0px 0.0px 0.0px 32.0px; text-indent: -32.0px; font: 14.0px Monaco"><span style="color: #891315">&quot;~&quot;</span></p>
<p style="margin: 0.0px 0.0px 0.0px 32.0px; text-indent: -32.0px; font: 14.0px Monaco"><span style="color: #891315">&quot;&lt;&lt;&quot;</span></p>
<p style="margin: 0.0px 0.0px 0.0px 32.0px; text-indent: -32.0px; font: 14.0px Monaco"><span style="color: #891315">&quot;&gt;&gt;&quot;</span></p>
<p style="margin: 0.0px 0.0px 0.0px 32.0px; text-indent: -32.0px; font: 14.0px Monaco"><span style="color: #891315">&quot;(&quot;</span></p>
<p style="margin: 0.0px 0.0px 0.0px 32.0px; text-indent: -32.0px; font: 14.0px Monaco"><span style="color: #891315">&quot;)&quot;</span></p><p style="margin: 0.0px 0.0px 0.0px 32.0px; text-indent: -32.0px; font: 14.0px Monaco">
<br class="webkit-block-placeholder"></p><p style="margin: 0.0px 0.0px 0.0px 32.0px; text-indent: -32.0px; font: 14.0px Monaco"><span class="Apple-style-span" style="font-family: arial; font-size: 13px; "><div>See the files CMake/Source/cmExpr* for more info...
</div><div><br class="webkit-block-placeholder"></div><div>HTH,</div><div>David</div><div><br class="webkit-block-placeholder"></div><div></div></span></p>
</div>