码迷,mamicode.com
首页 > 其他好文 > 详细

qt demo pro

时间:2020-02-07 18:31:15      阅读:76      评论:0      收藏:0      [点我收藏+]

标签:mit   compiler   release   set   put   consul   std   tde   can   

qt demo pro

 

qtdemo.pri

TEMPLATE = app

QT_VER = $$[QT_VERSION]
QT_PATH = $$[QT_INSTALL_PREFIX]

#message(Qt version is $$QT_VER)
#message(Qt install prefix is $$QT_PATH)

QT       += core gui

greaterThan(QT_MAJOR_VERSION, 4): QT += widgets

CONFIG += debug_and_release

TARGET = qtdemo
CONFIG(debug, debug|release) {
    unix: TARGET = $$join(TARGET,,,_debug)
    else: TARGET = $$join(TARGET,,,d)
}

VER_MAJ = 0
VER_MIN = 1
VER_PAT = 1
VERSION = $$sprintf("%1.%2.%3",$$VER_MAJ,$$VER_MIN,$$VER_PAT)

# BUILD_DIR = $$_PRO_FILE_PWD_/../build
debug: DESTDIR = debug
release: DESTDIR = release

QMAKE_LIBDIR += $$DESTDIR

UI_DIR += .ui
OBJECTS_DIR += .obj
MOC_DIR += .moc
RCC_DIR += .res


# Default rules for deployment.
qnx: target.path = /tmp/$${TARGET}/bin
else: unix:!android: target.path = /opt/$${TARGET}/bin
!isEmpty(target.path): INSTALLS += target


#win32:debug: CONFIG += console
CONFIG(debug, debug|release) {
    CONFIG += debug
    CONFIG += warn_on

    DEFINES += QT_DEBUG
} else {
    CONFIG += release
    CONFIG += warn_off

    DEFINES += QT_NO_DEBUG
    DEFINES += QT_NO_DEBUG_OUTPUT
    DEFINES += QT_NO_WARNING_OUTPUT
}

CONFIG += c++11

# 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

# You can also make your code fail to compile if it uses deprecated APIs.
# In order to do so, uncomment the following line.
# You can also select to disable deprecated APIs only up to a certain version of Qt.
#DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x060000    # disables all the APIs deprecated before Qt 6.0.0

DEFINES += QT_NO_CAST_FROM_ASCII
DEFINES += QT_NO_CAST_TO_ASCII
DEFINES += QT_NO_CAST_FROM_BYTEARRAY
DEFINES += QT_NO_URL_CAST_FROM_STRING
DEFINES += QT_USE_QSTRINGBUILDER


SOURCES +=     main.cpp     qmymainwindow.cpp

HEADERS +=     qmymainwindow.h

FORMS +=     qmymainwindow.ui


# Disable warning C4819 for msvc
msvc:QMAKE_CXXFLAGS += -execution-charset:utf-8
msvc:QMAKE_CXXFLAGS += -source-charset:utf-8
msvc:QMAKE_CXXFLAGS_WARN_ON += -wd4819

 

========== End

 

qt demo pro

标签:mit   compiler   release   set   put   consul   std   tde   can   

原文地址:https://www.cnblogs.com/lsgxeva/p/12273752.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!