This is similar to a thread a while back:<br><br><a href="http://www.cmake.org/pipermail/cmake/2009-April/028419.html">http://www.cmake.org/pipermail/cmake/2009-April/028419.html</a><br><br>I suggested comparing the CMakeCache.txt files before and after a configure to get a list of relevant configuration changes and adding them to the command line.<br>

<br>James<br><br><div class="gmail_quote">On Fri, Jul 17, 2009 at 7:54 AM, David E DeMarle <span dir="ltr">&lt;<a href="mailto:dave.demarle@kitware.com">dave.demarle@kitware.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">

I think you can write a starter cmakecache in an empty build directory<br>
consisting of just the non-default options you want and and then run<br>
cmake on that. It will fill in the rest of what it needs if you&#39;ve<br>
provided a consistent set that doesn&#39;t need to ask you anything.<br>
<br>
That is what dashboards do.<br>
<div class="im"><br>
David E DeMarle<br>
Kitware, Inc.<br>
R&amp;D Engineer<br>
28 Corporate Drive<br>
Clifton Park, NY 12065-8662<br>
Phone: 518-371-3971 x109<br>
<br>
<br>
<br>
</div><div><div></div><div class="h5">On Fri, Jul 17, 2009 at 4:12 AM, Alin M Elena&lt;<a href="mailto:alinm.elena@googlemail.com">alinm.elena@googlemail.com</a>&gt; wrote:<br>
&gt; Hi Bill and Eric,<br>
&gt;<br>
&gt; I see your points about the implementation but I think you are thinking to<br>
&gt; something different that I have  in my mind.<br>
&gt;<br>
&gt; I am not interested in portability. When I try to compile a big project (eg<br>
&gt; paraview) the -gui is a very good tool, due to its incremental support. Then I<br>
&gt; go let us say to a production environment where I am command line and I want a<br>
&gt; one-go approach.<br>
&gt;<br>
&gt; The programmatic set variables are of no value to me as they will be set the<br>
&gt; same in the command line environment. I need a track of all the variables that<br>
&gt; I set. The only thing that I want to keep track of are my changes, as they are<br>
&gt; the only one that change the flow of the compilation process.<br>
&gt;<br>
&gt; regards,<br>
&gt;<br>
&gt; Alin<br>
&gt; --<br>
&gt;  ______________________________________________________________________<br>
&gt;  &quot;If the Universities will not study useless subjects, who will?&quot;<br>
&gt;                             G. F. FitzGerald, Nature, 45/46, 392 (1892)<br>
&gt;  ______________________________________________________________________<br>
&gt;  Mr  Alin M ELENA<br>
&gt;  Irish Centre for High-End Computing -- <a href="http://www.ichec.ie" target="_blank">www.ichec.ie</a><br>
&gt;  The Design Tower, Trinity Technology &amp; Enterprise Campus<br>
&gt;  Grand Canal Quay,  Dublin 2, Ireland<br>
&gt;  Tel:   +353 (0) 1 5241608 ext 29<br>
&gt;  Fax: +353 (0) 1 7645845<br>
&gt;  <a href="http://alin.elenaworld.net" target="_blank">http://alin.elenaworld.net</a><br>
&gt;  <a href="mailto:alin.elena@ichec.ie">alin.elena@ichec.ie</a><br>
&gt;  <a href="mailto:alinm.elena@gmail.com">alinm.elena@gmail.com</a><br>
&gt;  ______________________________________________________________________<br>
&gt; On Thursday 16 July 2009 20:21:02 you wrote:<br>
&gt;&gt; 2009/7/16 Bill Hoffman &lt;<a href="mailto:bill.hoffman@kitware.com">bill.hoffman@kitware.com</a>&gt;:<br>
&gt;&gt; &gt; Alin M Elena wrote:<br>
&gt;&gt; &gt;&gt;&gt; I think the previous posts are missing the question....   I think what<br>
&gt;&gt; &gt;&gt;&gt; is wanted is a way to run cmake-gui pick some options, and then<br>
&gt;&gt; &gt;&gt;&gt; generate a -D command line equivalent to the options that were picked<br>
&gt;&gt; &gt;&gt;&gt; in cmake-gui.  This is not possible, and would be difficult to<br>
&gt;&gt; &gt;&gt;&gt; implement.<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; Thanks Bill, exactly what I wanted to know.  Why is that difficult?<br>
&gt;&gt; &gt;<br>
&gt;&gt; &gt; All options in the cache are stored together, some are set from the<br>
&gt;&gt; &gt; cmakelists.txt files and some are set by users.  I suppose camke-gui<br>
&gt;&gt; &gt; could try and track all changes made by the user and collect them up. I<br>
&gt;&gt; &gt; am not sure that the set of options would be portable to a different<br>
&gt;&gt; &gt; machine.<br>
&gt;&gt;<br>
&gt;&gt; I may add some other similar possible issues.<br>
&gt;&gt;<br>
&gt;&gt; Sometimes as Bill said some options do appear on a specific machine basis<br>
&gt;&gt; like in<br>
&gt;&gt; IF (WIN32)<br>
&gt;&gt;      OPTION(WHATEVER &quot;You know&quot;  FALSE)<br>
&gt;&gt; ENDIF(WIN32)<br>
&gt;&gt;<br>
&gt;&gt; of<br>
&gt;&gt;<br>
&gt;&gt; FIND_PACKAGE(Doxygen)<br>
&gt;&gt; IF (DOXYGEN_FOUND)<br>
&gt;&gt;      OPTION(BUILD_DOC &quot;Build documentation using Doxygen&quot; OFF)<br>
&gt;&gt; ENDIF(DOXYGEN_FOUND)<br>
&gt;&gt;<br>
&gt;&gt; or even more, one option may trigger another one<br>
&gt;&gt;<br>
&gt;&gt; OPTION(LEVEL1 &quot;level1&quot; OFF)<br>
&gt;&gt; IF (LEVEL1)<br>
&gt;&gt;     OPTION(LEVEL2 &quot;level2&quot; OFF)<br>
&gt;&gt; ENDIF(LEVEL1)<br>
&gt;&gt;<br>
&gt;&gt; in this second case the GUI will show you the LEVEL2 option<br>
&gt;&gt; only if you set LEVEL1 to ON and hit configure.<br>
&gt;&gt;<br>
&gt;&gt; The CMake gui (QT or curse) have an iterative usage pattern<br>
&gt;&gt;<br>
&gt;&gt; 1) configure<br>
&gt;&gt; 2) select change<br>
&gt;&gt; 3) eventually go to 1<br>
&gt;&gt; 4) generate<br>
&gt;&gt;<br>
&gt;&gt; The pure command line is usually &quot;one-shot&quot; trying to get the<br>
&gt;&gt; &quot;preferred&quot; configuration.<br>
&gt;&gt;<br>
&gt;&gt; Like Bill said a possible way to do it would be to track user-modified<br>
&gt;&gt; values vs programmatically chosen ones. But you&#39;ll have to deal with<br>
&gt;&gt; user-modified values depending on programmatically chosen path,<br>
&gt;&gt; not that easy to do.<br>
&gt; _______________________________________________<br>
&gt; Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
&gt;<br>
&gt; 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>
&gt;<br>
&gt; 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>
&gt;<br>
&gt; Follow this link to subscribe/unsubscribe:<br>
&gt; <a href="http://www.cmake.org/mailman/listinfo/cmake" target="_blank">http://www.cmake.org/mailman/listinfo/cmake</a><br>
&gt;<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><br>
</div></div></blockquote></div><br>