[Qt-interest] How do I tell with qmake whether system is 64 or32-bit?

Ben Swerts benswerts at telenet.be
Thu Jun 9 21:21:15 CEST 2011


Hi Nikos,

For quite a few systems you can check the QMAKESPEC, as mentioned before.
For Windows, however, you'll need something else. We use this construct:

win32:contains(QMAKE_HOST.arch, x86_64) {
  LIBS += fmodex64
} else {
  LIBS += fmodex32
} 

Hope it helps,


	Ben

> -----Original Message-----
> From: qt-interest-bounces+benswerts=telenet.be at qt.nokia.com 
> [mailto:qt-interest-bounces+benswerts=telenet.be at qt.nokia.com]
>  On Behalf Of Nikos Chantziaras
> Sent: Wednesday, June 08, 2011 21:25
> To: qt-interest at qt.nokia.com
> Subject: [Qt-interest] How do I tell with qmake whether 
> system is 64 or32-bit?
> 
> In a qmake-based project, I need to include different 
> libraries in the build if the current system is 64-bit.  
> Something like this:
> 
>    64bit {
>        LIBS += fmodex64
>    }
>    32bit {
>        LIBS += fmodex32
>    }
> 
> How do I do that?
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at qt.nokia.com
> http://lists.qt.nokia.com/mailman/listinfo/qt-interest
> 




More information about the Qt-interest-old mailing list