Re: [CMake] CMAKE_MFC_FLAG not working in functions

2011-10-20 Thread Rolf Eike Beer
I have a function defined very high up in the directory tree at the root CMakeLists file. Several levels below it, I have another CMakeLists file that I call that function from. The function sets CMAKE_MFC_FLAG to 2. I notice that this flag gets ignored when it is set inside of the function

Re: [CMake] CMAKE_MFC_FLAG not working in functions

2011-10-20 Thread Robert Dailey
On Thu, Oct 20, 2011 at 2:36 AM, Rolf Eike Beer e...@sf-mail.de wrote: I have a function defined very high up in the directory tree at the root CMakeLists file. Several levels below it, I have another CMakeLists file that I call that function from. The function sets CMAKE_MFC_FLAG to 2.

Re: [CMake] CMAKE_MFC_FLAG not working in functions

2011-10-20 Thread David Cole
Are you using VS10? Is it this already known problem? http://public.kitware.com/Bug/view.php?id=11224 On Thu, Oct 20, 2011 at 11:41 AM, Robert Dailey rcdai...@gmail.com wrote: On Thu, Oct 20, 2011 at 2:36 AM, Rolf Eike Beer e...@sf-mail.de wrote: I have a function defined very high up in

Re: [CMake] CMAKE_MFC_FLAG not working in functions

2011-10-20 Thread Robert Dailey
I'm generating for VS2003 in this case. Also with the searching I did I was not able to find an existing bug report related to this issue. - Robert Dailey On Thu, Oct 20, 2011 at 10:43 AM, David Cole david.c...@kitware.com wrote: Are you using VS10? Is it this already known problem?

Re: [CMake] CMAKE_MFC_FLAG not working in functions

2011-10-20 Thread Michael Wild
On 10/20/2011 05:41 PM, Robert Dailey wrote: On Thu, Oct 20, 2011 at 2:36 AM, Rolf Eike Beer e...@sf-mail.de mailto:e...@sf-mail.de wrote: I have a function defined very high up in the directory tree at the root CMakeLists file. Several levels below it, I have another

Re: [CMake] CMAKE_MFC_FLAG not working in functions

2011-10-20 Thread Robert Dailey
Let me ask this, What would be the parent of a function located in the root CMakeLists file but called from a subordinate CMakeLists file? - Robert Dailey On Thu, Oct 20, 2011 at 11:55 AM, Michael Wild them...@gmail.com wrote: On 10/20/2011 05:41 PM, Robert Dailey wrote: On Thu,

Re: [CMake] CMAKE_MFC_FLAG not working in functions

2011-10-20 Thread Michael Hertling
On 10/20/2011 06:59 PM, Robert Dailey wrote: Let me ask this, What would be the parent of a function located in the root CMakeLists file but called from a subordinate CMakeLists file? It's the subordinate CMakeLists.txt file's parent, but what Michael probably aims at is that some variables

Re: [CMake] CMAKE_MFC_FLAG not working in functions

2011-10-20 Thread Robert Dailey
On Thu, Oct 20, 2011 at 12:56 PM, Michael Hertling mhertl...@online.dewrote: On 10/20/2011 06:59 PM, Robert Dailey wrote: Let me ask this, What would be the parent of a function located in the root CMakeLists file but called from a subordinate CMakeLists file? It's the subordinate

Re: [CMake] CMAKE_MFC_FLAG not working in functions

2011-10-20 Thread Michael Hertling
On 10/20/2011 08:44 PM, Robert Dailey wrote: On Thu, Oct 20, 2011 at 12:56 PM, Michael Hertling mhertl...@online.dewrote: On 10/20/2011 06:59 PM, Robert Dailey wrote: Let me ask this, What would be the parent of a function located in the root CMakeLists file but called from a subordinate

Re: [CMake] CMAKE_MFC_FLAG not working in functions

2011-10-20 Thread Robert Dailey
So I created a small project to attempt to reproduce this problem on a much smaller scale, but it functioned as designed in that case. It's only in my large, corporate project that this happens. Is there any way to dump a scope stack or call stack of some sort in CMake? That way I can see what

Re: [CMake] CMAKE_MFC_FLAG not working in functions

2011-10-20 Thread Bill Hoffman
On 10/20/2011 5:11 PM, Robert Dailey wrote: So I created a small project to attempt to reproduce this problem on a much smaller scale, but it functioned as designed in that case. It's only in my large, corporate project that this happens. Is there any way to dump a scope stack or call stack of

Re: [CMake] CMAKE_MFC_FLAG not working in functions

2011-10-20 Thread David Cole
Use --trace with the cmake command line, redirect that to a file, then search the file On Thu, Oct 20, 2011 at 5:11 PM, Robert Dailey rcdai...@gmail.com wrote: So I created a small project to attempt to reproduce this problem on a much smaller scale, but it functioned as designed in that case.

Re: [CMake] CMAKE_MFC_FLAG not working in functions

2011-10-20 Thread Robert Dailey
There isn't any way to do a trace from cmake gui is there? Maybe that's a separate feature request on its own :P I'll check out the trace and follow up with results. - Robert Dailey On Thu, Oct 20, 2011 at 4:16 PM, Bill Hoffman bill.hoff...@kitware.comwrote: On 10/20/2011 5:11 PM,

Re: [CMake] CMAKE_MFC_FLAG not working in functions

2011-10-20 Thread Robert Dailey
I found out where I was going wrong based on how you guys said it isn't used by add_executable(). I was doing this before: set( CMAKE_MFC_FLAG 2 PARENT_SCOPE ) add_executable( ${project_name} WIN32 ${source} ) set( CMAKE_MFC_FLAG 0 PARENT_SCOPE ) I did this so that if I create any projects

[CMake] CMAKE_MFC_FLAG not working in functions

2011-10-19 Thread Robert Dailey
I have a function defined very high up in the directory tree at the root CMakeLists file. Several levels below it, I have another CMakeLists file that I call that function from. The function sets CMAKE_MFC_FLAG to 2. I notice that this flag gets ignored when it is set inside of the function in