It's possible, but it's probably not advisable.<div><br></div><div>The command line argument handling code in CMake is, shall we say, a smidge on the fragile side.</div><div><br></div><div>It would be better to stream your arguments into a file, perhaps one arg per line in a text file, and then use CMake's file reading capabilities to process that file from within your script. And using -D to indicate the filename to the CMake script...</div>
<div><br></div><div><br></div><div>HTH,</div><div>David</div><div><br></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Tue, Nov 27, 2012 at 5:31 PM, James Bigler <span dir="ltr"><<a href="mailto:jamesbigler@gmail.com" target="_blank">jamesbigler@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Is it possible to have an unbounded number of arguments to a script processed by CMake using the -P argument?<div><br></div>
<div>I need to specify a variable number of arguments, so using -D isn't going to help much.</div>
<br>--<br>
<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the CMake FAQ at: <a href="http://www.cmake.org/Wiki/CMake_FAQ" target="_blank">http://www.cmake.org/Wiki/CMake_FAQ</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.cmake.org/mailman/listinfo/cmake" target="_blank">http://www.cmake.org/mailman/listinfo/cmake</a><br></blockquote></div><br></div>