[Interest] How to read Qmake .pro file built-in variables
Karl Ruetz
karl.ruetz at ruetzdogz.com
Thu Sep 25 15:13:10 CEST 2014
Here’s how I do it:
TARGET = MyProgram
VERSION = 1.0.0.0
DEFINES += \
APP_VERSION=\"\\\"$$VERSION\\\"\" \
APP_NAME=\\\"$$TARGET\\\"
I then access the TARGET as the constant APP_NAME and VERSION as the constant APP_VERSION
Karl
On Sep 25, 2014, at 8:04 AM, rap <rap at dlc.fi> wrote:
> Is there a way to read the contents of the qmake project file (.pro) built-in variables, specially the "TARGET" variable? I'm doing
> a bunch of small examples and getting the TARGET (.exe) name to my QWindow class would help to pass the name to setTitle()
> consistently and automatically.
>
> Thanks,
> /Risto
>
> _______________________________________________
> Interest mailing list
> Interest at qt-project.org
> http://lists.qt-project.org/mailman/listinfo/interest
More information about the Interest
mailing list