[Interest] QMake generation config file from variables in .pro file

Stephen Kelly steveire at gmail.com
Mon Jan 20 15:39:27 CET 2014


Bo Thorsen wrote:

> Den 16-01-2014 14:42, Guido Seifert skrev:
>> Hi,
>> when I use cmake I can create a file config.h.in, which contains
>> things like:
>> #define Version "@VERSION@"
>>
>> in the CMakeLists.txt I can define a variable:
>> SET(VERSION "something")
>> and add:
>>
>> configure_file (
>>"config.h.in"
>> )
>>
>> This creates a config.h with #define Version "something".
>>
>> Question is, can I do the same with qmake? How?
> 
> As someone already told you, no this can't be done.

It can be done. It's used in Qt itself (eg generating cmake files). 

I don't know if it is a 'stable interface for users to use' or 'for internal 
use only' and I don't know if it's documented.

Thanks,

Steve.





More information about the Interest mailing list