[CMake] enable_language(.... OPTIONAL) signature does not work correctly

Alan W. Irwin irwin at beluga.phys.uvic.ca
Mon Jun 29 18:40:33 EDT 2009


On 2009-06-29 22:48+0200 Alexander Neundorf wrote:

> On Monday 29 June 2009, Alan W. Irwin wrote:
>> I have been testing the OPTIONAL signature for enable_language using the
>> following simple CMakeLists.txt file:
>>
>> *******
>> cmake_minimum_required(VERSION 2.6.4)
>> project(test NONE)
>> enable_language(C OPTIONAL)
>> message(STATUS "CMAKE_C_COMPILER_WORKS = ${CMAKE_C_COMPILER_WORKS}")
>> *******
>>
>> According to the documentation the OPTIONAL signature is to help
>> CMake-based build systems deal smoothly with bad/broken compilers by
>> allowing them to take their own actions to deal with the compiler issue
>> based on the value of CMAKE_<languageName>_COMPILER_WORKS.  However, the
>> OPTIONAL signature does not work and bad/broken compilers error out before
>> the above message command can be reached.  The same issue also occurs for
>> C++ and Fortran.
>
> Yes, please report this in the bug tracker.

DONE, see http://public.kitware.com/Bug/view.php?id=9220.

Alan
__________________________
Alan W. Irwin

Astronomical research affiliation with Department of Physics and Astronomy,
University of Victoria (astrowww.phys.uvic.ca).

Programming affiliations with the FreeEOS equation-of-state implementation
for stellar interiors (freeeos.sf.net); PLplot scientific plotting software
package (plplot.org); the libLASi project (unifont.org/lasi); the Loads of
Linux Links project (loll.sf.net); and the Linux Brochure Project
(lbproject.sf.net).
__________________________

Linux-powered Science
__________________________


More information about the CMake mailing list