Hi, 

> -----Original Message-----
> From: [EMAIL PROTECTED] 
> [mailto:[EMAIL PROTECTED]
> g] On Behalf Of Trevor Kellaway
> Sent: 21 April 2007 17:03
> To: [email protected]
> Subject: RE: [CMake] Unable to get CTEST_CUSTOM_WARNING_MATCH working
> 
> Hi,
> 
> > I've been trying to get CTEST_CUSTOM_WARNING_MATCH working for an 
> > embedded compiler that produces info and warning messages with 
> > "INFORMATION" and "WARNING", so that my build log reports 
> to the Dart 
> > server flags these up as warnings.
> > 
> > I've tried this: 
> > 
> >     SET(    CTEST_CUSTOM_WARNING_MATCH 
> >                     ${CTEST_CUSTOM_WARNING_MATCH} 
> >                     "INFORMATION" 
> >                     "WARNING" 
> >             )
> > 
> 
> OK, what I was doing wrong was putting this in a "CMakeList.txt" style
> file, rather than as the Wiki says to place it in 
> "CTestCustom.cmake" in
> the build directory (see
> http://www.cmake.org/Wiki/CMake_Testing_With_CTest#Customizing_CTest).
> 
> However, I've now fallen down another hole, as my Nightly & Continuous
> builds are using cleaning the binary tree in my CTest -S script (see
> http://www.cmake.org/HTML/TestingSetup.html), i.e.:
> 
>       "SET (CTEST_START_WITH_EMPTY_BINARY_DIRECTORY TRUE)"
> 
> This of course deletes my "CTestCustom.cmake" in the build directory!
> 
> Does anyone know what the workaround is for this? 
>  - A CTest command line option (I couldn't see anything obvious)?
>  - A CMake copy that will happen after the clean (slightly horrible).


The best way I can think of doing it is by adding CTestCustom.cmake to
my top level source directory and adding this to the top level
CMakeLists.txt:

        #
        # Ensure our Dart2 customised detection of build info/warnings
are copied to the binary
        # directory (as automated builds clean this out prior to
configuring).
        #
        CONFIGURE_FILE(CTestCustom.cmake
${CMAKE_BINARY_DIR}/CTestCustom.cmake COPYONLY)


It is a shame you can't place the CTEST_CUSTOM_WARNING_MATCH in a
*.cmake file, as I was adding a "Lint.cmake" package and it would be
really nice to keep the custom warnings associated with this package in
its "Lint.cmake" file, rather than forcing this on the end user.

 - TrevK
_______________________________________________
CMake mailing list
[email protected]
http://www.cmake.org/mailman/listinfo/cmake

Reply via email to