QMake DEFINES variable



  • Hi,

    I've got a function call in a SDK that is not defined any more so I need to remove it. I don't really want to touch the SDK source code so I thought that I could use a macro to remove the call, this works fine:

    @#define functionToRemove(arg)
    functionToRemove("test");@

    But this implies to modify the SDK or one of the included files and as I said, I'd rather not. Is it possible to write that #define inside the .pro file? I tried many combinations with the DEFINES variable but none seems to work.

    @DEFINES += functionToRemove(arg)
    DEFINES += functionToRemove(arg)=
    DEFINES += "functionToRemove(arg)="
    DEFINES += functionToRemove(arg)=//
    DEFINES += "functionToRemove(arg)=/
    /"@

    Did I miss something or is it just not possible to do that kind of things?



  • Maybe check this "post":http://www.qtcentre.org/threads/29104-QMake-DEFINES?p=237294#post237294 from another forum. Write if this helps.



  • I've already seen that but it didn't work ... I think it is the parameter that is causing these problems



  • you must escape the braces, there is no need to have an equals sign, so I doubt that thats it.



  • I already tried but didn't succeed...

    @DEFINES += functionToRemove(arg)
    DEFINES += "functionToRemove(arg)"
    DEFINES += "functionToRemove(arg)"
    DEFINES += "functionToRemove(arg)"
    DEFINES += functionToRemove\(arg\)@


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.