Trevor Kellaway wrote:
Bill,

You want to create your own rules for CMAKE_(LANG)_COMPILE_OBJECT:

SET(CMAKE_C_COMPILE_OBJECT
"<CMAKE_C_COMPILER> ${CMAKE_START_TEMP_FILE} ${CMAKE_CL_NOLOGO} <FLAGS> /Fo<OBJECT> /Fd<TARGET_PDB> -c <SOURCE>${CMAKE_END_TEMP_FILE}")

Each new line in this is a separate command. You should just be able to append the lint stuff to end end of the existing rule variable.

Something like this:

set(CMAKE_C_COMPILE_OBJECT "${CMAKE_C_COMPILE_OBJECT\} lint <OBJECT>")

How does CMake know where one command finishes and the next starts?
You say "each new line" but surely "lint <OBJECT>" above will just be
treated as extra arguments to the compiler? Or was you example across
multiple lines and the email merged them?
Email merged them. For an example see Linux-como.cmake. Also, I think I had it a big wrong...
It should be like this:
"command ..."
"command2 .."
"command3 .."

-Bill

_______________________________________________
CMake mailing list
[email protected]
http://www.cmake.org/mailman/listinfo/cmake

Reply via email to