CMake does not warn. And actually, I think I have to back-track on my statement a little bit.
Whether or not a TRY_COMPILE "works" for a multiple arch / config build *depends* entirely on what you are trying to compile and what result you are expecting to get out of it. If you do a try compile on some code to detect the presence of a function, for example, that should work fine on a universal binary build (presuming the function you're trying to link against is present in universal binary form in the library it lives in...). The thing that won't work on a multiple arch/config build is trying to detect the size of something or the presence/absence of something where the thing you're trying to measure is different in the different archs / configs. If it's uniform across all archs/configs then you can measure it and get an answer that makes sense for all archs/configs. If not, then you can't. Does that make sense? So... CMake does not warn because it does not know whether what you are attempting to measure is valid or not. It's up to you to "do the right thing" in these sorts of situations. You already know that if you are building a universal binary with both 32-bit and 64-bit architectures in it that it makes no sense to "measure" the size of "void*" at CMake time. You know this because you know there is more than one answer depending on which one runs. Hope this clarifies things even further, (rather than muddying anybody's waters...) David On Thu, Jun 11, 2009 at 6:56 PM, Sean McBride <s...@rogue-research.com>wrote: > On 6/11/09 5:25 PM, David Cole said: > > >TRY_COMPILE works fine for cross compiles, just not for *mutiple > >configs/architectures "simultaneously"* compiles... > > Thanks for the clarification, that language is clearer. > > Does CMake detect and warn in such cases? (it is after all the common > case on OS X.) > > Cheers, > > -- > ____________________________________________________________ > Sean McBride, B. Eng s...@rogue-research.com > Rogue Research www.rogue-research.com > Mac Software Developer Montréal, Québec, Canada > > >
_______________________________________________ Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake