[CMake] ARGV to ARGN translation debugging

Bill Hoffman bill.hoffman at kitware.com
Mon Nov 17 14:44:27 EST 2014


On 11/17/2014 1:44 PM, Joe wrote:
>
> 1) How  can the same ARGV to the same function give different ARGN's? My
> feeling is that the answer is "never, it's something in how the MESSAGE
> command displays lists."
> 2) How can we display lists in a way that allows us to see the
> differences between them? That is, is there some function  which I can
> replace MESSAGE with in order to see the discrepancy between these two
> lists?
To me it looks like in the first call all of this stuff:
Multifield_Repartition;SOURCES;multifield_repartition.cpp;COMM;mpi;serial;STANDARD_PASS_OUTPUT;NUM_MPI_PROCS;4;FAIL_REGULAR_EXPRESSION;TEST 
FAILED;PASS_REGULAR_EXPRESSION;TEST 
PASSED;ARGS;--num_particles=50;--num_dimensions=2

is crammed into one variable.

It might be clearer if you changed your messages to do this:
   MESSAGE("FINAL EXE_NAME: ${EXE_NAME}")
   MESSAGE("FINAL ARGV: ${ARGV}")
   MESSAGE("FINAL ARGN: ${ARGN}")

Most likely it was called quoted?

my_func("lots of stuff;foo;bar")
vs
my_func("lots of stuff" foo bar)

-Bill



More information about the CMake mailing list