Re: [CMake] CMake with IDL file generation

2012-09-12 Thread Andreas Haferburg
Here's what we're using (found somewhere on the internet, slightly modified): # MACRO_ADD_INTERFACES(idl_files...) # # Syntax: MACRO_ADD_INTERFACES(output list idl1 [idl2 [...]]) # Notes: idl1 should be absolute

Re: [CMake] CMake with IDL file generation

2012-09-11 Thread Petr Kmoch
Hi Robert. What you're after is pretty standard cmake. You'll need add_custom_command( OUTPUT path_to/generated_header.h path_to/generated_source.cpp COMMAND midl.exe arguments to midl other options of add_custom_command as necessary ) # as many times as necessary (probably once per IDL

Re: [CMake] CMake with IDL file generation

2012-09-11 Thread Petr Kmoch
Sorry, typo. In the case of add_custom_target(), the files would be listed as DEPENDS. Petr On Tue, Sep 11, 2012 at 9:13 AM, Petr Kmoch petr.km...@gmail.com wrote: Hi Robert. What you're after is pretty standard cmake. You'll need add_custom_command( OUTPUT path_to/generated_header.h

[CMake] CMake with IDL file generation

2012-09-10 Thread Robert Dailey
I'm creating a shared library target that needs to compile and include source generated by an IDL. I want CMake to create a custom target that will invoke MIDL.EXE (comes with Windows SDK) against the IDL file to generate the header / source files needed. These header/source files will then be