[CMake] Complaint about if..endif

Ioan Calin Borcoman iborco at gmail.com
Sat Nov 22 04:13:27 EST 2008


Does this apply to else(), too?

And could you please update the man page?

Thanx.

Ionutz

On Sat, Nov 22, 2008 at 7:53 AM, Philip Lowman <philip at yhbt.com> wrote:
> On Sat, Nov 22, 2008 at 12:17 AM, Robert Dailey <rcdailey at gmail.com> wrote:
>>
>> Hi,
>>
>> Why must endif() contain the same expression as the associated if()
>> command? Isn't CMake smart enough to know that a simple occurrence of
>> "endif()" simply matches the previous if(), regardless of its expression
>> list? Are there any plans to simplify this? The way it is now is redundant
>> and boilerplate.
>
> On CMake 2.6.x you no longer have to match the endif().  If you're still
> using CMake 2.4.x you can set CMAKE_ALLOW_LOOSE_LOOP_CONSTRUCTS.
>
> http://www.vtk.org/Wiki/CMake_Useful_Variables
>
>
> --
> Philip Lowman
>
> _______________________________________________
> CMake mailing list
> CMake at cmake.org
> http://www.cmake.org/mailman/listinfo/cmake
>


More information about the CMake mailing list