<div class="gmail_quote">On Thu, Aug 23, 2012 at 2:24 PM, Robert Dailey <span dir="ltr">&lt;<a href="mailto:rcdailey.lists@gmail.com" target="_blank">rcdailey.lists@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="HOEnZb"><div class="h5">On Thu, Aug 23, 2012 at 1:03 PM, David Cole &lt;<a href="mailto:david.cole@kitware.com">david.cole@kitware.com</a>&gt; wrote:<br>
&gt; On Thu, Aug 23, 2012 at 11:50 AM, Robert Dailey &lt;<a href="mailto:rcdailey.lists@gmail.com">rcdailey.lists@gmail.com</a>&gt;<br>
&gt; wrote:<br>
&gt;&gt;<br>
&gt;&gt; On Thu, Aug 23, 2012 at 10:48 AM, Robert Dailey<br>
&gt;&gt; &lt;<a href="mailto:rcdailey.lists@gmail.com">rcdailey.lists@gmail.com</a>&gt; wrote:<br>
&gt;&gt; &gt; On Thu, Aug 23, 2012 at 10:43 AM, John Drescher &lt;<a href="mailto:drescherjm@gmail.com">drescherjm@gmail.com</a>&gt;<br>
&gt;&gt; &gt; wrote:<br>
&gt;&gt; &gt;&gt;&gt; Is the separation between configuration &amp; generation really necessary<br>
&gt;&gt; &gt;&gt;&gt; for cmake-gui? I ask because several of my co-workers are confused<br>
&gt;&gt; &gt;&gt;&gt; between the differences in the two, even though I explain it.<br>
&gt;&gt; &gt;&gt;&gt;<br>
&gt;&gt; &gt;&gt;&gt; Honestly there isn&#39;t really a reason that I can think of to do a<br>
&gt;&gt; &gt;&gt;&gt; configure without a generate, unless you&#39;re testing the integrity of<br>
&gt;&gt; &gt;&gt;&gt; your CMake script changes maybe, but even then, if its broken<br>
&gt;&gt; &gt;&gt;&gt; generation won&#39;t take place.<br>
&gt;&gt; &gt;&gt;&gt;<br>
&gt;&gt; &gt;&gt;&gt; The command line program does not separate the two, so I simply think<br>
&gt;&gt; &gt;&gt;&gt; cmake-gui should eliminate the configure button, and simply have a<br>
&gt;&gt; &gt;&gt;&gt; generate button. Does this seem fair? Is there a reason why they are<br>
&gt;&gt; &gt;&gt;&gt; separated?<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; I can think of one use case that I use that the separation is a good<br>
&gt;&gt; &gt;&gt; thing. What about when you have options and variables that are<br>
&gt;&gt; &gt;&gt; conditional depending on other CMake variables so that setting the<br>
&gt;&gt; &gt;&gt; variables / options may take more than 1 configure.<br>
&gt;&gt; &gt;<br>
&gt;&gt; &gt; Well, think of this from the perspective of Linux users. They don&#39;t<br>
&gt;&gt; &gt; get to configure seperately, so only Windows users get special<br>
&gt;&gt; &gt; treatment here (and maybe Mac too, since it&#39;s using Qt). Basically, if<br>
&gt;&gt; &gt; two configures are necessary, you simply just hit the &quot;generate&quot;<br>
&gt;&gt; &gt; button twice, and the wait may be slightly longer because of the<br>
&gt;&gt; &gt; generation. However, usually it&#39;s the configure step that takes 99% of<br>
&gt;&gt; &gt; the time and generation is quick since it&#39;s just spitting out files to<br>
&gt;&gt; &gt; disk it seems.<br>
&gt;&gt; &gt;<br>
&gt;&gt; &gt; I would also argue that any CMake project should have appropriate<br>
&gt;&gt; &gt; defaults OR logic to calculate the defaults for you, so that even if a<br>
&gt;&gt; &gt; user decides to not modify any cache variables, generation should<br>
&gt;&gt; &gt; always succeed. CMake can&#39;t assume that 2 passes will be necessary<br>
&gt;&gt; &gt; (and it really shouldn&#39;t).<br>
&gt;&gt;<br>
&gt;&gt; Oh and also, if two configures are necessary (say that, a library or<br>
&gt;&gt; package can&#39;t be found intelligently), then the configuration step<br>
&gt;&gt; would fail and be interrupted, so you get a chance to correct any<br>
&gt;&gt; errors and adjust appropriate cache variables. So, in this case it<br>
&gt;&gt; doesn&#39;t really matter if you&#39;ve hit configure or generate.<br>
&gt;&gt; --<br>
&gt;&gt;<br>
&gt;&gt; Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
&gt;&gt;<br>
&gt;&gt; Visit other Kitware open-source projects at<br>
&gt;&gt; <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
&gt;&gt;<br>
&gt;&gt; Please keep messages on-topic and check the CMake FAQ at:<br>
&gt;&gt; <a href="http://www.cmake.org/Wiki/CMake_FAQ" target="_blank">http://www.cmake.org/Wiki/CMake_FAQ</a><br>
&gt;&gt;<br>
&gt;&gt; Follow this link to subscribe/unsubscribe:<br>
&gt;&gt; <a href="http://www.cmake.org/mailman/listinfo/cmake" target="_blank">http://www.cmake.org/mailman/listinfo/cmake</a><br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt; Iterative configuring through the gui is useful for some people/projects,<br>
&gt; and generating is time-consuming too on some larger projects with some<br>
&gt; generators.<br>
&gt;<br>
&gt; So we probably won&#39;t be eliminating the Configure button anytime soon. On<br>
&gt; the other hand, you can just click &quot;Generate&quot; if that&#39;s what you want and<br>
&gt; ignore the configure button altogether nowadays. &quot;Generate&quot; will<br>
&gt; configure-first if necessary, and then generate.<br>
&gt;<br>
&gt; Here are some related issues indicating some people want the exact opposite<br>
&gt; (i.e., separate configure and generate steps for the command line cmake)<br>
&gt;   <a href="http://public.kitware.com/Bug/view.php?id=13359" target="_blank">http://public.kitware.com/Bug/view.php?id=13359</a><br>
&gt;<br>
&gt; And a request for a &quot;build&quot; button in cmake-gui:<br>
&gt;   <a href="http://public.kitware.com/Bug/view.php?id=8260" target="_blank">http://public.kitware.com/Bug/view.php?id=8260</a><br>
<br>
</div></div>I definitely hear your point, and I realize not everyone has my<br>
specific workflow, but usually I only hit configure to see if there<br>
are any failures that do NOT stop the generation process (such as<br>
status messages that print in red, but do not indicate an actual<br>
error). In that case, I do not want generation to proceed but instead<br>
I want to address the alert / error in the logs. However, if<br>
configuration succeeds I only end up hitting generate right after that<br>
anyway.<br>
<br>
I am only bringing this up since I was surprised to see how my team<br>
struggled to understand the differences between the two, and when to<br>
use one or the other. Most of the time I just say &quot;Ignore the<br>
configure button, just always hit generate&quot;. If it wasn&#39;t there, it<br>
would be more clear to people that are new to CMake. I&#39;m trying to<br>
migrate my company to CMake, so I thought this might be valuable<br>
feedback, as it was one of the surprising little things we got hung up<br>
on that you just never really think about.<br>
</blockquote></div><div><br></div><br><div>We hear you, too. But there are lots of people who like the separate buttons, so we&#39;re keeping them.</div><div><br></div>