[CMake] Single line crashes cmake

Joseph Garvin k04jg02 at gmail.com
Sun Nov 11 15:07:14 EST 2007


What version of cmake are you running? Running from the cmd prompt I got the
same crash with no error output. If there's a newer version available, where
can I get it? I'm running 2.4 - patch 7. Also, I get the crash even if the
file is just this without the message part:

FILE(GLOB BLITZ_TMP "C:/" "blitz-[0-9].[0-9]")

So I don't think the crash is caused by the MESSAGE() line.

On Nov 5, 2007 4:58 PM, Brandon Van Every <bvanevery at gmail.com> wrote:

> On Nov 5, 2007 4:36 PM, Joseph Garvin <k04jg02 at gmail.com> wrote:
> > I'm trying to find all folders matching the pattern "blitz-[0-9].[0-9]"
> so
> > it would match blitz-0.3, blitz-2.4, etc. within the folders C:\ and
> > C:\Program Files. Starting to code this I put this in an otherwise empty
> > .cmake file:
> >
> > FILE(GLOB BLITZ_TMP "C:/" "blitz-[0-9].[0-9]")
> > MESSAGE(${BLITZ_TMP})
> >
> > Then I included it from the CMakeLists.txt for my project. CMake crashes
> on
> > the first line (i.e. commenting out the second doesn't prevent the
> crash),
> > running v2.4 under Vista saying, "CMakeSetup MFC application has stopped
> > working".
> >
> > What am I doing wrong?
>
> I put your 2 lines into a file called glob.cmake.  Then I ran it as a
> script, using a Windows Vista Command Prompt.  I got the following
> results:
>
> C:\devel\src\cbugs\glob>cmake -P glob.cmake
> CMake Error: Error in cmake code at
> C:/devel/src/cbugs/glob/glob.cmake:3:
> message called with incorrect number of arguments
>   Called from: [1]     C:/devel/src/cbugs/glob/glob.cmake
>
> C:\devel\src\cbugs\glob>
>
> Thus: the glob expressions didn't match anything in my current
> directory, BLITZ_TMP was null, and MESSAGE fails because it has been
> handed no arguments.  Generally you need MESSAGE("${myvariable}").
>
> When I include the glob.cmake in a CMakeLists.txt, CMakeSetup crashes
> as you described.  I am wondering why CMakeSetup can't be more
> informative about the error.
>
>
> Cheers,
> Brandon Van Every
> _______________________________________________
> CMake mailing list
> CMake at cmake.org
> http://www.cmake.org/mailman/listinfo/cmake
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://public.kitware.com/pipermail/cmake/attachments/20071111/0827fd1e/attachment.htm


More information about the CMake mailing list