Re: [CMake] Propagating variable to toplevel parent

2010-07-09 Thread Mathieu Malaterre
On Wed, Jul 7, 2010 at 3:06 PM, Michael Wild wrote: > project(bla NONE) > > set_property(GLOBAL PROPERTY v "13") > add_subdirectory(foo) > get_property(v GLOBAL PROPERTY v) > message("final v: ${v}") > > > For properties you must always use getters and setters, they are never > directly mapped to

Re: [CMake] Propagating variable to toplevel parent

2010-07-07 Thread Michael Wild
On 7. Jul, 2010, at 14:45 , Mathieu Malaterre wrote: > On Wed, Jul 7, 2010 at 1:07 PM, Bo Thorsen wrote: >> Den 07-07-2010 12:34, Mathieu Malaterre skrev: >>> >>> Hi there, >>> >>> I am wondering if I am missing anything here. How would one >>> propagate a variable across subdirectories in c

Re: [CMake] Propagating variable to toplevel parent

2010-07-07 Thread Mathieu Malaterre
On Wed, Jul 7, 2010 at 1:07 PM, Bo Thorsen wrote: > Den 07-07-2010 12:34, Mathieu Malaterre skrev: >> >> Hi there, >> >>   I am wondering if I am missing anything here. How would one >> propagate a variable across subdirectories in cmake ? I thought that a >> simple CACHE variable would do the tri

Re: [CMake] Propagating variable to toplevel parent

2010-07-07 Thread Bo Thorsen
Den 07-07-2010 12:34, Mathieu Malaterre skrev: Hi there, I am wondering if I am missing anything here. How would one propagate a variable across subdirectories in cmake ? I thought that a simple CACHE variable would do the trick, but using cmake 2.8.1 I had to do the following trick list(APP

[CMake] Propagating variable to toplevel parent

2010-07-07 Thread Mathieu Malaterre
Hi there, I am wondering if I am missing anything here. How would one propagate a variable across subdirectories in cmake ? I thought that a simple CACHE variable would do the trick, but using cmake 2.8.1 I had to do the following trick list(APPEND v "42") # make sure to actually update the CAC