aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/blackbox/testdata
diff options
context:
space:
mode:
authorJoerg Bornemann <joerg.bornemann@digia.com>2014-05-23 12:26:46 +0200
committerChristian Kandeler <christian.kandeler@digia.com>2014-05-26 16:16:59 +0200
commit875f9ba4e7631a3c66e1edfc54f6b4ed6a42b841 (patch)
tree8ca26ea03d6b85b99f2ba4464850a4f319f81b43 /tests/auto/blackbox/testdata
parent8917e0cecd80a5d673ac4a6d6586b472aa019d1b (diff)
run rules on dependency-only products
This enables compound products that do not provide their own source files but only consist of dependencies. Task-number: QBS-277 Change-Id: I8e3fc5b5e3a85ca2c6fe4890dcd52d3a55cebfe2 Reviewed-by: Christian Kandeler <christian.kandeler@digia.com>
Diffstat (limited to 'tests/auto/blackbox/testdata')
-rw-r--r--tests/auto/blackbox/testdata/appWithoutSources/a.cpp1
-rw-r--r--tests/auto/blackbox/testdata/appWithoutSources/b.cpp10
-rw-r--r--tests/auto/blackbox/testdata/appWithoutSources/project.qbs30
3 files changed, 41 insertions, 0 deletions
diff --git a/tests/auto/blackbox/testdata/appWithoutSources/a.cpp b/tests/auto/blackbox/testdata/appWithoutSources/a.cpp
new file mode 100644
index 000000000..bf7759e11
--- /dev/null
+++ b/tests/auto/blackbox/testdata/appWithoutSources/a.cpp
@@ -0,0 +1 @@
+int foo() { return 42; }
diff --git a/tests/auto/blackbox/testdata/appWithoutSources/b.cpp b/tests/auto/blackbox/testdata/appWithoutSources/b.cpp
new file mode 100644
index 000000000..76c93685d
--- /dev/null
+++ b/tests/auto/blackbox/testdata/appWithoutSources/b.cpp
@@ -0,0 +1,10 @@
+#include <cstdio>
+
+int foo(); // defined in a.cpp
+
+int main()
+{
+ printf("The answer is %d.\n", foo());
+ return 0;
+}
+
diff --git a/tests/auto/blackbox/testdata/appWithoutSources/project.qbs b/tests/auto/blackbox/testdata/appWithoutSources/project.qbs
new file mode 100644
index 000000000..983cc9bab
--- /dev/null
+++ b/tests/auto/blackbox/testdata/appWithoutSources/project.qbs
@@ -0,0 +1,30 @@
+import qbs 1.0
+
+Project {
+ StaticLibrary {
+ name: "a"
+
+ Depends { name: "cpp" }
+
+ files: [
+ "a.cpp",
+ ]
+ }
+
+ StaticLibrary {
+ name: "b"
+
+ Depends { name: "a" }
+ Depends { name: "cpp" }
+
+ files: [
+ "b.cpp",
+ ]
+ }
+
+ CppApplication {
+ name: "appWithoutSources"
+ Depends { name: "a" }
+ Depends { name: "b" }
+ }
+}