On Feb 17, 2014, at 8:55 AM, Brad King <brad.k...@kitware.com> wrote:
> On 02/15/2014 04:29 PM, Steve Wilson wrote: >> I just pushed the updated version of objective-c-support to stage. > > Nice, thanks. Here are some comments. > > The "CMake<LANG>Compiler.cmake" files cannot have logic like > > +if(CMAKE_OBJC_ENABLED AND NOT CMAKE_OBJCXX_ENABLED) > > because the languages can be enabled in any order and the final > set is not known when these files are loaded. > > I think it will take special C++-implemented logic to magically > use the best-matching language for .m and .mm sources I wasn’t sure if this kind of solution would work, but thought it didn’t hurt to try. I’ll ask next time when I suspect there might be a problem. I’ll work on some tweaking deeper in the C++ code. Any suggestions where you might like this functionality to appear. >> such as CheckOBJCCompilerFlag > > I see new modules: > > CheckOBJCCompilerFlag.cmake > CheckOBJCSourceCompiles.cmake > CheckOBJCSourceRuns.cmake > CheckOBJCXXCompilerFlag.cmake > CheckOBJCXXSourceCompiles.cmake > CheckOBJCXXSourceRuns.cmake > > Rather than an explosion of modules I'd prefer to correct this > historical mistake and create a single API for each check that > takes the language as a parameter. Modules CheckTypeSize and > CheckStructHasMember recently learned this, for example. So, > we would need new modules: > > CheckCompilerFlag > CheckSourceCompiles > CheckSourceRuns > > and then refactor the implementations of the existing modules > for C and CXX to be in terms of the general ones. > > If you don't have time to work on that I think we can just leave > out the check modules for now. I will take a look and see if I can make the refactor happen. I’ll drop out the OBJC(XX) modules from the Objective-C(++) commits and resubmit those and then separately work on the refactor. It will take a couple of days to make these changes as my paying job ( :) ) requires my focused attention for a bit now. Question: In these cases where I have to drop my work on these changes and switch focus to other things, should the proposed topics be removed from stage, or should they be left for others to look at?
signature.asc
Description: Message signed with OpenPGP using GPGMail
-- 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://public.kitware.com/cgi-bin/mailman/listinfo/cmake-developers