diff options
author | Denis Shienkov <denis.shienkov@gmail.com> | 2019-10-17 14:55:44 +0300 |
---|---|---|
committer | Denis Shienkov <denis.shienkov@gmail.com> | 2019-10-21 11:11:24 +0000 |
commit | 1353ac64cf542dcd0b174e2e77e9c37d86fcba39 (patch) | |
tree | dd8758dad62e048f76ae04e8b96ccc0b7876b14d /tests/auto/blackbox/testdata | |
parent | 02af2595540e7666b6aad1991599763230af339d (diff) |
Add test for cpp.generateLinkerMapFile property
This test cover only the applications using the MSVC and
GCC-like toolchains yet. Other toolchains and a product
types can be added later if it will required.
Change-Id: I37db96015774447e1e30b503d9853599be0177f2
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Diffstat (limited to 'tests/auto/blackbox/testdata')
-rw-r--r-- | tests/auto/blackbox/testdata/generate-linker-map-file/generate-linker-map-file.qbs | 25 | ||||
-rw-r--r-- | tests/auto/blackbox/testdata/generate-linker-map-file/main.cpp | 29 |
2 files changed, 54 insertions, 0 deletions
diff --git a/tests/auto/blackbox/testdata/generate-linker-map-file/generate-linker-map-file.qbs b/tests/auto/blackbox/testdata/generate-linker-map-file/generate-linker-map-file.qbs new file mode 100644 index 000000000..815e64853 --- /dev/null +++ b/tests/auto/blackbox/testdata/generate-linker-map-file/generate-linker-map-file.qbs @@ -0,0 +1,25 @@ +Project { + CppApplication { + name: "app-map" + files: ["main.cpp"] + cpp.generateLinkerMapFile: true + } + CppApplication { + name: "app-nomap" + files: ["main.cpp"] + cpp.generateLinkerMapFile: false + } + CppApplication { + name: "app-nomap-default" + files: ["main.cpp"] + } + + Probe { + id: toolchainProbe + property bool isUsed: qbs.toolchain.contains("msvc") + || qbs.toolchain.contains("gcc") + configure: { + console.info("use test: " + isUsed); + } + } +} diff --git a/tests/auto/blackbox/testdata/generate-linker-map-file/main.cpp b/tests/auto/blackbox/testdata/generate-linker-map-file/main.cpp new file mode 100644 index 000000000..e4e2a1671 --- /dev/null +++ b/tests/auto/blackbox/testdata/generate-linker-map-file/main.cpp @@ -0,0 +1,29 @@ +/**************************************************************************** +** +** Copyright (C) 2019 Denis Shienkov <denis.shienkov@gmail.com> +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qbs. +** +** $QT_BEGIN_LICENSE:GPL-EXCEPT$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 as published by the Free Software +** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +int main() { return 0; } |