[CMake] Problems with ctest output using clang compiler on Mac

Ananda Tallur anand at maunakeatech.com
Tue May 7 09:22:44 EDT 2013


Hi,

Just to inform CMake users on Mac OS X that problem is solved by using 
CTEST_USE_LAUNCHERS option.

As a reminder, problem is that some warnings generated by different 
clang processes during parallel compilation get mixed together, become 
unreadable, and are therefore processed as errors by ctest.

With 'CTEST_USE_LAUNCHERS' option, stdout and stderr outputs of parallel 
clang processes are handled differently and do not get mixed together 
anymore.

More details about this option are available in this page at item 2.  : 
http://www.kitware.fr/blog/home/post/11

To activate CTEST_USE_LAUNCHERS in you ctest script, following lines are 
needed :

|set(CTEST_USE_LAUNCHERS 1)

...

ctest_configure(BUILD "${CTEST_BINARY_DIRECTORY}"

     OPTIONS "-DCTEST_USE_LAUNCHERS=${CTEST_USE_LAUNCHERS}"

  ... )


|A last point : a side effect of this option I have observed is that 
warnings and errors are counted differently. Number of compilation units 
yielding errors and warnings are counted, and not individual errors and 
warning messages.
If someone knowns a method to use CTEST_USE_LAUNCHERS option with 
individual counting of error and warning messages, I am interested.

Hope this helps,

Kind regards

Ananda

On 10/01/2013 15:24, Ananda Tallur wrote:
> Hi,
>
> We have the same problem here with ctest and clang on Mac OS X.
> Versions used are :
> - clang 4.2, from XCode 4.6DP4 on Mac OS X 10.7
> - cmake 2.8.10.2
>
> In our ctest script, compilation is launched with 4 jobs (make -j4).
> In our dashboard (and same thing when directly looking at the text output of the ctest process), we notice that some compilations outputs get mixed.
> In this case we can see the beginning of one compilation process output starting in the middle of a previous compilation output.
> This leads to some mixed outputs of two different compilation processes, that cannot be properly interpreted by ctest as warning, and are therefore displayed as errors.
>
> At the end of this mail, an example of the kind of mixes we have.
>
> Is anybody facing the same problem and is there a workaround available ?
>
> Kind regards
>
> Ananda
>
> -----
> 12:
> In file included from O/usr/local/mkt-dev/install/boost-1.52.0_patch_range_search_n-macosx10.7-x86_64-gnu++11_libc++-20121226/build-x86_64/include/boost/functional/hash/hash.hppIn file included from /usr/local/mkt-dev/install/boost-1.52.0_patch_range_search_n-macosx10.7-x86_64-gnu++11_libc++-20121226/build-x86_64/include/boost/date_time/gregorian/gregorian.hppO:S15:
> T:_I34/usr/local/mkt-dev/install/boost-1.52.0_patch_range_search_n-macosx10.7-x86_64-gnu++11_libc++-20121226/build-x86_64/include/boost/functional/hash/detail/hash_float.hpp:T71E:R:
> 25In file included from AT:O Rwarning: _/usr/local/mkt-dev/install/boost-1.52.0_patch_range_search_n-macosx10.7-x86_64-gnu++11_libc++-20121226/build-x86_64/include/boost/date_time/gregorian/parsers.hppFcAa:s13tC :
> In file included from AD/usr/local/mkt-dev/install/boost-1.52.0_patch_range_search_n-macosx10.7-x86_64-gnu++11_libc++-20121226/build-x86_64/include/boost/date_time/date_parsing.hpp:fEr_oP15:
> mL US'In file included from 'c
> har/usr/local/mkt-dev/install/boost-1.52.0_patch_range_search_n-macosx10.7-x86_64-gnu++11_libc++-20121226/build-x86_64/include/boost/tokenizer.hpp:20 *:
> In file included from ' /usr/local/mkt-dev/install/boost-1.52.0_patch_range_search_n-macosx10.7-x86_64-gnu++11_libc++-20121226/build-x86_64/include/boost/token_iterator.hpp:24t      return tmp += n;                              \o ':
>
> s                 ^t/usr/local/mkt-dev/install/boost-1.52.0_patch_range_search_n-macosx10.7-x86_64-gnu++11_libc++-20121226/build-x86_64/include/boost/token_functions.hpp
>
> :312:d:33: :swarning: uiznuse_e/usr/local/mkt-dev/install/boost-1.52.0_patch_range_search_n-macosx10.7-x86_64-gnu++11_libc++-20121226/build-x86_64/include/boost/gil/image_view.hpp:d125 t: p68a:* 'note:  ir(n aiansmetaktae n'tuianrt iso'n igonefd  lofnugb' * [')n- Wicutninocnr etaesmpeulass rteed-peaq rsameupiteercri]al
>
> eidz aatliiognn m'ebnoto sftr:o:mo p1e rtaot o8    static void assign(Iterator b, Iterator e, Token &t) { }
>                                  ^
> r [+-<Wbcoa/usr/local/mkt-dev/install/boost-1.52.0_patch_range_search_n-macosx10.7-x86_64-gnu++11_libc++-20121226/build-x86_64/include/boost/token_functions.hpposstt:-:a312l:i:gg45inl]
> [ 58%] Building CXX object libProcessing/tests/CMakeFiles/jitterestimationfilter_test.dir/jitterestimationfilter_test.cpp.o
> :::iterator warning: _frunom_2dus<bedoos parat:me:gteilr ::'eme' mo[r-Wuy_basnued_se2d_lod-capator<brametooerst]
> ::gil:                seed = *(std::size_t*) ptr;
> :m                        ^~~~~~~~~~~~~~~~~~
> emory_b    static void assign(Iterator b, Iterator e, Token &t) { }
>                                              ^
> ased/usr/local/mkt-dev/install/boost-1.52.0_patch_range_search_n-macosx10.7-x86_64-gnu++11_libc++-20121226/build-x86_64/include/boost/token_functions.hpp:312_st:55ep: _iwarning: utenurasetod r<conparstamete ur ns'tig' [-Wneund usshedor-parat met/usr/local/mkt-dev/install/boost-1.52.0_patch_range_search_n-macosx10.7-x86_64-gnu++11_libc++-20121226/build-x86_64/include/boost/functional/hash/detail/hash_float.hpp*:e>r76 :]>
> ----
>
>
> Andreas Fetzer<stromsau at gmx.de>  wrote
>
> > Hi there,
> >
> > On our dashboard some warnings are treated as errors and hence the build fails (only for Mac OS X systems):
> >
> > http://cdash.mitk.org/viewBuildError.php?buildid=132336  <http://cdash.mitk.org/viewBuildError.php?buildid=132336>
> >
> > Apparently not the hole output line of the clang compiler was considered. This happens especially when we are using the apple clang compiler.
> >
> > Is this a issue of ctest?
> >
> >
> > Regards
> > Andreas
> > --
> > Empfehlen Sie GMX DSL Ihren Freunden und Bekannten und wir
> > belohnen Sie mit bis zu 50,- Euro!https://freundschaftswerbung.gmx.de


-- 
Ananda Tallur | Software Development Engineer
Mauna Kea Technologies | 9 rue d'Enghien -- 75010 Paris, France
Tel : + 33 1 48 24 05 68 | Cell : + 33 6 77 77 71 67 | Fax : + 33 1 48 
24 12 18 | www.maunakeatech.com <http://www.maunakeatech.com/>

logomaunakeatech.jpg

This message and any attached documents are CONFIDENTIAL and intended 
only for the use of the intended recipient.
Ce message et tous les documents attachés sont CONFIDENTIELS et à la 
seule attention du destinataire pour lequel ils ont été écrits.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20130507/0be0aadc/attachment-0001.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: logomaunakeatech.jpg
Type: image/jpeg
Size: 9752 bytes
Desc: not available
URL: <http://www.cmake.org/pipermail/cmake/attachments/20130507/0be0aadc/attachment-0001.jpg>


More information about the CMake mailing list