[Qt-interest] including custom configuration features

Sean Harmer sean.harmer at maps-technology.com
Sat Feb 20 18:54:04 CET 2010


Mike Delaney wrote:
> I'm trying to setup my project to use some features I've put in a prf 
> file. I've tried setting QMAKEFEATURES in my project file but to no 
> avail. I can't see to get qmake to read in my prf file. I've provided an 
> example below, does anyone know what I'm doing wrong?
> 
> If I look at the generated Makefiles and I don't see a reference to the 
> file "application.prf"
> 
> [Directory structure]
> ----> features (directory)
> |    |  - application.prf
> |
> | - project.pro
> | - main.cpp
> 
> [project.pro]
> TEMPLATE = app
> 
> QMAKEFEATURES = "c:/project/features:c:/project"
> CONFIG += application
> 
> SOURCES = main.cpp

You need to set an environment variable called QMAKEFEATURES and then 
run qmake. As far as I know setting QMAKEFEATURES within the .pro file 
has no effect. See the advanced usage section of the qmake manual for 
information on how qmake decides where to search for your .prf file.

Cheers,

Sean




More information about the Qt-interest-old mailing list