QT中.pro文件常用配置

#core
QT       += core gui svg
QT       += sql
QT       += network
QT       += opengl
QT       += multimedia

# specify out put dir
CONFIG(debug, debug|release){
    DESTDIR = $$PWD/debug
}else{
    DESTDIR = $$PWD/release
}

#specify tmp directory.
MOC_DIR         = $$PWD/build/moc  #指定moc命令将含Q_OBJECT的头文件转换成标准.h文件的存放目录
RCC_DIR         = $$PWD/build/rcc  #指定rcc命令将.qrc文件转换成qrc_*.h文件的存放目录
UI_DIR          = $$PWD/build/ui   #指定ui.h 路径
OBJECTS_DIR     = $$PWD/build/obj  #指定目标文件(obj)的存放目录

greaterThan(QT_MAJOR_VERSION, 4): QT += widgets

CONFIG += c++11
QMAKE_CXXFLAGS += /utf-8
CODECFORTR = GB2312
CODECFORSRC = UTF-8
TRANSLATIONS = $$PWD/resource/language/VideoClient_Chinese.ts

# The following define makes your compiler emit warnings if you use
# any Qt feature that has been marked deprecated (the exact warnings
# depend on your compiler). Please consult the documentation of the
# deprecated API in order to know how to port your code away from it.
DEFINES += QT_DEPRECATED_WARNINGS
DEFINES += _XXX
DEFINES += DLOGGER
DEFINES += _WINSOCKAPI_


include($$PWD/DniuOnvif/dniuOnvif.pri)

#logger
INCLUDEPATH += $$PWD/public/dlogger/include/

你可能感兴趣的:(QT,ui)