On 08/09/2010 05:27 PM, Alexander Neundorf wrote: > Ok, attached you can find a CMakeParseArguments.cmake. > Docs are still missing. > The interface is similar to the one from boost, but not identical. > With this version you can specify options (no values following), single-value > arguments (0..1 value following) and multi-value arguments (0..n values > following). > This has the advantage that the function can also report the arguments which > it didn't know. > This is done in ${prefix}_UNPARSED_ARGUMENTS.
Sounds good. > It runs once over ARGN, but the option and argument names have to checked on > each iteration, I think this can't be avoided (and is also the case in the > macro from Boost). Yeah, we cannot do much better without real data structures in the CMake language; let's not open that can of worms now. At least list(FIND) is in C++ :) > Is this the current version: > http://calder.sdml.cs.kent.edu/trac/origin/browser/trunk/cmake/BoostUtils.cmake > ? > It seems to have a bug, an option doesn't seem to terminate the collecting of > values of the previous argument (but I didn't test). I'm not sure. The official boost svn is here: https://svn.boost.org/trac/boost/browser but the CMake build system is distributed here: http://sodium.resophonic.com/boost-cmake/current-docs/ but there is a new CMake-based modularized version here: http://github.com/boost-lib/ -Brad _______________________________________________ cmake-developers mailing list cmake-developers@cmake.org http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-developers