summaryrefslogtreecommitdiffstats
path: root/Tests/QtAutogen/RccOnly
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2017-12-14 13:21:21 (GMT)
committerKitware Robot <kwrobot@kitware.com>2017-12-14 13:21:28 (GMT)
commit7341930ade835ce48641b5415cdd3f738772edf2 (patch)
tree377585f108b61dbc8b28462f708360a6ac504205 /Tests/QtAutogen/RccOnly
parent671958d2884e2d2597362265620b73f43d414870 (diff)
parent540d08f4858ddbb8d0356f77f878b9fbb7af8f80 (diff)
downloadCMake-7341930ade835ce48641b5415cdd3f738772edf2.zip
CMake-7341930ade835ce48641b5415cdd3f738772edf2.tar.gz
CMake-7341930ade835ce48641b5415cdd3f738772edf2.tar.bz2
Merge topic 'autogen-separate-tests'
540d08f4 Autogen: Tests: Move QtAutoUicInterface test to QtAutogen/UicInterface b1504f9f Autogen: Tests: Separate RerunRccDepends test e9fcd154 Autogen: Tests: Separate RerunMocPlugin test 54b4ff2a Autogen: Tests: Separate RerunMocBasic test 4988746e Autogen: Tests: Separate Complex test 6ce6fd42 Autogen: Tests: Separate StaticLibraryCycle test 45b6776a Autogen: Tests: Separate SameName test d7868687 Autogen: Tests: Separate MacOsFW test ... Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !1578
Diffstat (limited to 'Tests/QtAutogen/RccOnly')
-rw-r--r--Tests/QtAutogen/RccOnly/CMakeLists.txt8
-rw-r--r--Tests/QtAutogen/RccOnly/rccOnly.cpp9
-rw-r--r--Tests/QtAutogen/RccOnly/rccOnlyRes.qrc5
3 files changed, 22 insertions, 0 deletions
diff --git a/Tests/QtAutogen/RccOnly/CMakeLists.txt b/Tests/QtAutogen/RccOnly/CMakeLists.txt
new file mode 100644
index 0000000..a65dee4
--- /dev/null
+++ b/Tests/QtAutogen/RccOnly/CMakeLists.txt
@@ -0,0 +1,8 @@
+cmake_minimum_required(VERSION 3.10)
+project(RccOnly)
+include("../AutogenTest.cmake")
+
+# Test AUTORCC being enabled only
+add_executable(rccOnly rccOnly.cpp rccOnlyRes.qrc)
+set_property(TARGET rccOnly PROPERTY AUTORCC ON)
+target_link_libraries(rccOnly ${QT_QTCORE_TARGET})
diff --git a/Tests/QtAutogen/RccOnly/rccOnly.cpp b/Tests/QtAutogen/RccOnly/rccOnly.cpp
new file mode 100644
index 0000000..61c7bf4
--- /dev/null
+++ b/Tests/QtAutogen/RccOnly/rccOnly.cpp
@@ -0,0 +1,9 @@
+
+extern int qInitResources_rccOnlyRes();
+
+int main(int, char**)
+{
+ // Fails to link if the symbol is not present.
+ qInitResources_rccOnlyRes();
+ return 0;
+}
diff --git a/Tests/QtAutogen/RccOnly/rccOnlyRes.qrc b/Tests/QtAutogen/RccOnly/rccOnlyRes.qrc
new file mode 100644
index 0000000..5551348
--- /dev/null
+++ b/Tests/QtAutogen/RccOnly/rccOnlyRes.qrc
@@ -0,0 +1,5 @@
+<!DOCTYPE RCC><RCC version="1.0">
+<qresource>
+ <file>rccOnly.cpp</file>
+</qresource>
+</RCC>