2009/7/11 Marcel Loose <[email protected]>: > Hi Bill, > > The problem is not in the invocation of gcc. That works fine. The > problem is that I lose the preprocessor definitions that were added with > add_definitions() when compiling assembly files. These assembly files > must be preprocessed by gcc. I have the feeling that CMake purposely > drops these. So the question is how I can persuade CMake to keep the -D > options on the command line.
I don't know if you can persuade CMake to keep those for "compiling" ASM instead of C but you may be you get the currently added definitions using properties: (on directory, target or source see cmake --help-properties) e.g.: get_directory_property(ASM_DEF DEFINITION) then use the value of ASM_DEF in your *ASM*.cmake. Take my opinion as "pure guess" because I does not know much on how CMake*Compiler.cmake works so I don't know if you may "share" some variables values between the standard C and your custom ASM. > Note that I have defined an assembler for BG/P that uses gcc as > frontend, using the *ASM*.cmake macros mentioned in my previous mail. -- Erk Membre de l'April - « promouvoir et défendre le logiciel libre » - http://www.april.org _______________________________________________ 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
