From 1c987b919b453b7f571f78440544111b7892cc9c Mon Sep 17 00:00:00 2001 From: Roman Telezhynskyi Date: Sat, 6 Aug 2016 19:23:42 +0300 Subject: [PATCH] =?UTF-8?q?Use=20gcc=E2=80=99s=20Address=20Sanitizer=20onl?= =?UTF-8?q?y=20in=20Debug=20mode.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --HG-- branch : develop --- src/app/tape/warnings.pri | 13 ++++++++----- src/app/valentina/warnings.pri | 13 ++++++++----- src/libs/fervor/warnings.pri | 13 ++++++++----- src/libs/ifc/warnings.pri | 13 ++++++++----- src/libs/qmuparser/warnings.pri | 13 ++++++++----- src/libs/vdxf/warnings.pri | 13 ++++++++----- src/libs/vformat/warnings.pri | 13 ++++++++----- src/libs/vgeometry/warnings.pri | 13 ++++++++----- src/libs/vlayout/warnings.pri | 13 ++++++++----- src/libs/vmisc/warnings.pri | 13 ++++++++----- src/libs/vobj/warnings.pri | 13 ++++++++----- src/libs/vpatterndb/warnings.pri | 13 ++++++++----- src/libs/vpropertyexplorer/warnings.pri | 13 ++++++++----- src/libs/vtools/warnings.pri | 13 ++++++++----- src/libs/vwidgets/warnings.pri | 13 ++++++++----- src/test/CollectionTest/warnings.pri | 13 ++++++++----- src/test/ParserTest/warnings.pri | 13 ++++++++----- src/test/TranslationsTest/warnings.pri | 13 ++++++++----- src/test/ValentinaTest/warnings.pri | 13 ++++++++----- 19 files changed, 152 insertions(+), 95 deletions(-) diff --git a/src/app/tape/warnings.pri b/src/app/tape/warnings.pri index 549cf5183..5b95e306d 100644 --- a/src/app/tape/warnings.pri +++ b/src/app/tape/warnings.pri @@ -15,11 +15,14 @@ unix { noAddressSanitizer{ # For enable run qmake with CONFIG+=noAddressSanitizer # do nothing } else { - #gcc’s 4.8.0 Address Sanitizer - #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ - QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_LFLAGS += -fsanitize=address + CONFIG(debug, debug|release){ + # Debug mode + #gcc’s 4.8.0 Address Sanitizer + #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ + QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_LFLAGS += -fsanitize=address + } } } diff --git a/src/app/valentina/warnings.pri b/src/app/valentina/warnings.pri index ad525c0bf..1841710c3 100644 --- a/src/app/valentina/warnings.pri +++ b/src/app/valentina/warnings.pri @@ -16,11 +16,14 @@ unix { noAddressSanitizer{ # For enable run qmake with CONFIG+=noAddressSanitizer # do nothing } else { - #gcc’s 4.8.0 Address Sanitizer - #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ - QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_LFLAGS += -fsanitize=address + CONFIG(debug, debug|release){ + # Debug mode + #gcc’s 4.8.0 Address Sanitizer + #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ + QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_LFLAGS += -fsanitize=address + } } } diff --git a/src/libs/fervor/warnings.pri b/src/libs/fervor/warnings.pri index 28b9b9e84..f32c0fa70 100644 --- a/src/libs/fervor/warnings.pri +++ b/src/libs/fervor/warnings.pri @@ -14,11 +14,14 @@ unix { noAddressSanitizer{ # For enable run qmake with CONFIG+=noAddressSanitizer # do nothing } else { - #gcc’s 4.8.0 Address Sanitizer - #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ - QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_LFLAGS += -fsanitize=address + CONFIG(debug, debug|release){ + # Debug mode + #gcc’s 4.8.0 Address Sanitizer + #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ + QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_LFLAGS += -fsanitize=address + } } } diff --git a/src/libs/ifc/warnings.pri b/src/libs/ifc/warnings.pri index 10aa7e21b..9acd59b65 100644 --- a/src/libs/ifc/warnings.pri +++ b/src/libs/ifc/warnings.pri @@ -14,11 +14,14 @@ unix { noAddressSanitizer{ # For enable run qmake with CONFIG+=noAddressSanitizer # do nothing } else { - #gcc’s 4.8.0 Address Sanitizer - #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ - QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_LFLAGS += -fsanitize=address + CONFIG(debug, debug|release){ + # Debug mode + #gcc’s 4.8.0 Address Sanitizer + #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ + QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_LFLAGS += -fsanitize=address + } } } diff --git a/src/libs/qmuparser/warnings.pri b/src/libs/qmuparser/warnings.pri index 8b688cc33..5f5665a1b 100644 --- a/src/libs/qmuparser/warnings.pri +++ b/src/libs/qmuparser/warnings.pri @@ -13,11 +13,14 @@ unix { noAddressSanitizer{ # For enable run qmake with CONFIG+=noAddressSanitizer # do nothing } else { - #gcc’s 4.8.0 Address Sanitizer - #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ - QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_LFLAGS += -fsanitize=address + CONFIG(debug, debug|release){ + # Debug mode + #gcc’s 4.8.0 Address Sanitizer + #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ + QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_LFLAGS += -fsanitize=address + } } } diff --git a/src/libs/vdxf/warnings.pri b/src/libs/vdxf/warnings.pri index 8b688cc33..5f5665a1b 100644 --- a/src/libs/vdxf/warnings.pri +++ b/src/libs/vdxf/warnings.pri @@ -13,11 +13,14 @@ unix { noAddressSanitizer{ # For enable run qmake with CONFIG+=noAddressSanitizer # do nothing } else { - #gcc’s 4.8.0 Address Sanitizer - #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ - QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_LFLAGS += -fsanitize=address + CONFIG(debug, debug|release){ + # Debug mode + #gcc’s 4.8.0 Address Sanitizer + #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ + QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_LFLAGS += -fsanitize=address + } } } diff --git a/src/libs/vformat/warnings.pri b/src/libs/vformat/warnings.pri index 8b688cc33..5f5665a1b 100644 --- a/src/libs/vformat/warnings.pri +++ b/src/libs/vformat/warnings.pri @@ -13,11 +13,14 @@ unix { noAddressSanitizer{ # For enable run qmake with CONFIG+=noAddressSanitizer # do nothing } else { - #gcc’s 4.8.0 Address Sanitizer - #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ - QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_LFLAGS += -fsanitize=address + CONFIG(debug, debug|release){ + # Debug mode + #gcc’s 4.8.0 Address Sanitizer + #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ + QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_LFLAGS += -fsanitize=address + } } } diff --git a/src/libs/vgeometry/warnings.pri b/src/libs/vgeometry/warnings.pri index 8b688cc33..5f5665a1b 100644 --- a/src/libs/vgeometry/warnings.pri +++ b/src/libs/vgeometry/warnings.pri @@ -13,11 +13,14 @@ unix { noAddressSanitizer{ # For enable run qmake with CONFIG+=noAddressSanitizer # do nothing } else { - #gcc’s 4.8.0 Address Sanitizer - #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ - QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_LFLAGS += -fsanitize=address + CONFIG(debug, debug|release){ + # Debug mode + #gcc’s 4.8.0 Address Sanitizer + #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ + QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_LFLAGS += -fsanitize=address + } } } diff --git a/src/libs/vlayout/warnings.pri b/src/libs/vlayout/warnings.pri index 61e9cf089..f7b3e0486 100644 --- a/src/libs/vlayout/warnings.pri +++ b/src/libs/vlayout/warnings.pri @@ -19,11 +19,14 @@ unix { noAddressSanitizer{ # For enable run qmake with CONFIG+=noAddressSanitizer # do nothing } else { - #gcc’s 4.8.0 Address Sanitizer - #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ - QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_LFLAGS += -fsanitize=address + CONFIG(debug, debug|release){ + # Debug mode + #gcc’s 4.8.0 Address Sanitizer + #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ + QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_LFLAGS += -fsanitize=address + } } } diff --git a/src/libs/vmisc/warnings.pri b/src/libs/vmisc/warnings.pri index 43804e5cb..f051b7d6c 100644 --- a/src/libs/vmisc/warnings.pri +++ b/src/libs/vmisc/warnings.pri @@ -13,11 +13,14 @@ unix { noAddressSanitizer{ # For enable run qmake with CONFIG+=noAddressSanitizer # do nothing } else { - #gcc’s 4.8.0 Address Sanitizer - #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ - QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_LFLAGS += -fsanitize=address + CONFIG(debug, debug|release){ + # Debug mode + #gcc’s 4.8.0 Address Sanitizer + #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ + QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_LFLAGS += -fsanitize=address + } } } diff --git a/src/libs/vobj/warnings.pri b/src/libs/vobj/warnings.pri index 8b688cc33..5f5665a1b 100644 --- a/src/libs/vobj/warnings.pri +++ b/src/libs/vobj/warnings.pri @@ -13,11 +13,14 @@ unix { noAddressSanitizer{ # For enable run qmake with CONFIG+=noAddressSanitizer # do nothing } else { - #gcc’s 4.8.0 Address Sanitizer - #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ - QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_LFLAGS += -fsanitize=address + CONFIG(debug, debug|release){ + # Debug mode + #gcc’s 4.8.0 Address Sanitizer + #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ + QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_LFLAGS += -fsanitize=address + } } } diff --git a/src/libs/vpatterndb/warnings.pri b/src/libs/vpatterndb/warnings.pri index 8b688cc33..5f5665a1b 100644 --- a/src/libs/vpatterndb/warnings.pri +++ b/src/libs/vpatterndb/warnings.pri @@ -13,11 +13,14 @@ unix { noAddressSanitizer{ # For enable run qmake with CONFIG+=noAddressSanitizer # do nothing } else { - #gcc’s 4.8.0 Address Sanitizer - #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ - QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_LFLAGS += -fsanitize=address + CONFIG(debug, debug|release){ + # Debug mode + #gcc’s 4.8.0 Address Sanitizer + #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ + QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_LFLAGS += -fsanitize=address + } } } diff --git a/src/libs/vpropertyexplorer/warnings.pri b/src/libs/vpropertyexplorer/warnings.pri index 6dd49aeff..2ba5ef7d8 100644 --- a/src/libs/vpropertyexplorer/warnings.pri +++ b/src/libs/vpropertyexplorer/warnings.pri @@ -18,11 +18,14 @@ unix { noAddressSanitizer{ # For enable run qmake with CONFIG+=noAddressSanitizer # do nothing } else { - #gcc’s 4.8.0 Address Sanitizer - #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ - QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_LFLAGS += -fsanitize=address + CONFIG(debug, debug|release){ + # Debug mode + #gcc’s 4.8.0 Address Sanitizer + #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ + QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_LFLAGS += -fsanitize=address + } } } diff --git a/src/libs/vtools/warnings.pri b/src/libs/vtools/warnings.pri index d360b9cf1..46d1f80de 100644 --- a/src/libs/vtools/warnings.pri +++ b/src/libs/vtools/warnings.pri @@ -15,11 +15,14 @@ unix { noAddressSanitizer{ # For enable run qmake with CONFIG+=noAddressSanitizer # do nothing } else { - #gcc’s 4.8.0 Address Sanitizer - #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ - QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_LFLAGS += -fsanitize=address + CONFIG(debug, debug|release){ + # Debug mode + #gcc’s 4.8.0 Address Sanitizer + #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ + QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_LFLAGS += -fsanitize=address + } } } diff --git a/src/libs/vwidgets/warnings.pri b/src/libs/vwidgets/warnings.pri index e59da23b5..999753061 100644 --- a/src/libs/vwidgets/warnings.pri +++ b/src/libs/vwidgets/warnings.pri @@ -13,11 +13,14 @@ unix { noAddressSanitizer{ # For enable run qmake with CONFIG+=noAddressSanitizer # do nothing } else { - #gcc’s 4.8.0 Address Sanitizer - #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ - QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_LFLAGS += -fsanitize=address + CONFIG(debug, debug|release){ + # Debug mode + #gcc’s 4.8.0 Address Sanitizer + #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ + QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_LFLAGS += -fsanitize=address + } } } diff --git a/src/test/CollectionTest/warnings.pri b/src/test/CollectionTest/warnings.pri index 28c3e2d23..d6c219342 100644 --- a/src/test/CollectionTest/warnings.pri +++ b/src/test/CollectionTest/warnings.pri @@ -15,11 +15,14 @@ unix { noAddressSanitizer{ # For enable run qmake with CONFIG+=noAddressSanitizer # do nothing } else { - #gcc’s 4.8.0 Address Sanitizer - #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ - QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_LFLAGS += -fsanitize=address + CONFIG(debug, debug|release){ + # Debug mode + #gcc’s 4.8.0 Address Sanitizer + #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ + QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_LFLAGS += -fsanitize=address + } } } diff --git a/src/test/ParserTest/warnings.pri b/src/test/ParserTest/warnings.pri index b413ad86c..1e44663b3 100644 --- a/src/test/ParserTest/warnings.pri +++ b/src/test/ParserTest/warnings.pri @@ -11,11 +11,14 @@ unix { noAddressSanitizer{ # For enable run qmake with CONFIG+=noAddressSanitizer # do nothing } else { - #gcc’s 4.8.0 Address Sanitizer - #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ - QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_LFLAGS += -fsanitize=address + CONFIG(debug, debug|release){ + # Debug mode + #gcc’s 4.8.0 Address Sanitizer + #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ + QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_LFLAGS += -fsanitize=address + } } } diff --git a/src/test/TranslationsTest/warnings.pri b/src/test/TranslationsTest/warnings.pri index 28c3e2d23..d6c219342 100644 --- a/src/test/TranslationsTest/warnings.pri +++ b/src/test/TranslationsTest/warnings.pri @@ -15,11 +15,14 @@ unix { noAddressSanitizer{ # For enable run qmake with CONFIG+=noAddressSanitizer # do nothing } else { - #gcc’s 4.8.0 Address Sanitizer - #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ - QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_LFLAGS += -fsanitize=address + CONFIG(debug, debug|release){ + # Debug mode + #gcc’s 4.8.0 Address Sanitizer + #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ + QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_LFLAGS += -fsanitize=address + } } } diff --git a/src/test/ValentinaTest/warnings.pri b/src/test/ValentinaTest/warnings.pri index 28c3e2d23..d6c219342 100644 --- a/src/test/ValentinaTest/warnings.pri +++ b/src/test/ValentinaTest/warnings.pri @@ -15,11 +15,14 @@ unix { noAddressSanitizer{ # For enable run qmake with CONFIG+=noAddressSanitizer # do nothing } else { - #gcc’s 4.8.0 Address Sanitizer - #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ - QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer - QMAKE_LFLAGS += -fsanitize=address + CONFIG(debug, debug|release){ + # Debug mode + #gcc’s 4.8.0 Address Sanitizer + #http://blog.qt.digia.com/blog/2013/04/17/using-gccs-4-8-0-address-sanitizer-with-qt/ + QMAKE_CXXFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_CFLAGS += -fsanitize=address -fno-omit-frame-pointer + QMAKE_LFLAGS += -fsanitize=address + } } }