If I have several files with a .cc or .cpp filename extension that I
want to compile using Octave's mkoctfile script (a wrapper that turns
them into loadable object code in a form recognisable by the Octave
interpreter), how should I do it?

I thought I could do it with add_custom_command, but as I seem to
understand it, I need to write one such add_custom_command per source
file I want to process, perhaps with a loop?

What I'm really looking for is something like

   .cpp.oct:
   mkoctfile $< $COMPILATION_OPTIONS

like in Makefiles, a way to specify a custom command to turn files of
type A into type B with some flexibility of the option passed to this
command. Then I want to use this custom command to any specified
source file.

TIA,
- Jordi G. H.
_______________________________________________
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

Reply via email to