Skip to content

Commit

Permalink
Disable deprecated-copy warnings for modern compilers with old Qt's
Browse files Browse the repository at this point in the history
  • Loading branch information
pcolby committed Apr 15, 2023
1 parent 119d26f commit 37320f8
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions common.pri
Expand Up @@ -64,3 +64,15 @@ macx:equals(QT_MAJOR_VERSION,5):equals(QT_MINOR_VERSION,5) {
message(Adding '-Wno-return-stack-address' flag $$QT_VERSION)
QMAKE_CXXFLAGS += -Wno-return-stack-address
}

# Disable deprecated-copy warnings for modern compilers with old Qt's (earlier than 5.13).
equals(QT_MAJOR_VERSION,5):lessThan(QT_MINOR_VERSION,13) {
*-clang++ {
message(Adding '-Wno-deprecated-copy-with-user-provided-copy' flag for $$QMAKE_CXX and $$QT_VERSION)
QMAKE_CXXFLAGS += -Wno-deprecated-copy-with-user-provided-copy
}
*-g++ {
message(Adding '-Wno-deprecated-copy' flag for $$QMAKE_CXX and $$QT_VERSION)
QMAKE_CXXFLAGS += -Wno-deprecated-copy
}
}

0 comments on commit 37320f8

Please sign in to comment.