[CMake] Paired values in an iterable data structure like map or tuple

Ateljevich, Eli eli at water.ca.gov
Fri Jul 13 15:33:41 EDT 2012


Hi,
I have a series of tests I would like to perform, some of which are serial and some of which are mpi and should use np processors.

I would further prefer to be able to process this as a list of paired values. The following is nothing but pseudocode, but it attempts to convey the idea. The ability to pair attributes (either as tuples or as some sort of map or dictionary) is something I would love to learn to emulate. Am I missing an easy way to do this? Thanks -E

foreach(testname (test_serial_1,serial,na),
                                  test_mpi_1,mpi,4),
                                  test_mpi_2,mpi,2)      )
maketest(${testname}[0], ${testname}[1],${testname}[2])
endforeach()
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20120713/2e14ea07/attachment.htm>


More information about the CMake mailing list