Re: [CMake] Testing for the presence of an element in a list

2011-05-10 Thread Alexander Neundorf
On Tuesday 10 May 2011, J.S. van Bethlehem wrote: > Hello everyone, > > A silly question maybe, but I'm pretty sure at some point I read in some > piece of CMake documentation about a direct way to test for the presence > of an element in some list. So the following in a single command: > list(FIN

[CMake] Testing for the presence of an element in a list

2011-05-10 Thread J.S. van Bethlehem
Hello everyone, A silly question maybe, but I'm pretty sure at some point I read in some piece of CMake documentation about a direct way to test for the presence of an element in some list. So the following in a single command: list(FIND SOME_LIST TEST_ELEMENT TEST_INDEX) if(${TEST_INDEX} EQUA