Writting OS indepedent LIB and DEPENDPATH variables.
-
Hello,
currently these variables have entries like build-AStarDemoLib-Desktop_Qt_5_3_0_MinGW_32bit-Debug and build-AStarDemoLib-Android_f_r_armeabi_v7a_GCC_4_8_Qt_5_3_0-Debug
I have been hunting the qmake variable documentation, but I am kind of lost.
Is there a way to build such values in an OS independent way with variables like, e.g. $(BUILD), $(CXX) and so forth?
Thanks.
-
Hi,
qmake is innocent, it's Qt Creator that creates them.
Look in the Preferences -> Build & Run -> General -> "Default build directory"
-
Hi pjmlp,
comment of SGaist is useful if you want to change build path,
in addition you can find other build variables in above path
but if you want to add additional paths which is different in each OS, routine is different. -
Thanks guys, but my problem is how to properly do a multi-project in qmake in an OS independent way.
When using other make tools, it is usually a matter of using the correct set of make variables so that the binaries and include files can be properly found.
This is what I am looking for, what variables are available in qmake to achieve the same functionality when generating the makefile.
The qmake variable list, didn't seem to provide such variables as I am used to.
-
For OS specific stuff like rc file for Windows use scope
@
win32 {
RC_FILE = mycoolsoft.rc
}
@The same goes for include path
@
unix {
INCLUDEPATH += /usr/local/mycoollib/include
LIBS += -L/usr/local/mycoollib/lib
} else {
INCLUDEPATH += C:/Code/mycoollib/include
LIBS += C:/Code/mycoollib/lib
}
LIBS += -lmycoolib
@Compilers don't need to be setup since it's already done for you.
For more details and information, you can take a look at the "qmake manual" in Qt's documentation.