summaryrefslogtreecommitdiff
path: root/test cases
diff options
context:
space:
mode:
authorJussi Pakkanen <jpakkane@gmail.com>2013-06-15 02:40:53 +0300
committerJussi Pakkanen <jpakkane@gmail.com>2013-06-15 02:40:53 +0300
commit7e6d8454a4545dc26916e8db0d718d6d66369bd4 (patch)
treee12e1cc484ec0ba7cbb3c6671a57d6748c18b8a7 /test cases
parent4887450de6ccaea5ce065b4544d4599d44161aa2 (diff)
downloadmeson-7e6d8454a4545dc26916e8db0d718d6d66369bd4.tar.gz
Precompiled headers work for C++.
Diffstat (limited to 'test cases')
-rw-r--r--test cases/common/14 cpp pch/meson.build2
-rw-r--r--test cases/common/14 cpp pch/pch/prog_pch.cc5
2 files changed, 6 insertions, 1 deletions
diff --git a/test cases/common/14 cpp pch/meson.build b/test cases/common/14 cpp pch/meson.build
index d56800b93..6922fd7b6 100644
--- a/test cases/common/14 cpp pch/meson.build
+++ b/test cases/common/14 cpp pch/meson.build
@@ -1,2 +1,2 @@
project('c++ pch test', 'cpp')
-exe = executable('prog', 'prog.cc', pch : 'pch/prog.hh')
+exe = executable('prog', 'prog.cc', cpp_pch : ['pch/prog.hh', 'pch/prog_pch.cc'])
diff --git a/test cases/common/14 cpp pch/pch/prog_pch.cc b/test cases/common/14 cpp pch/pch/prog_pch.cc
new file mode 100644
index 000000000..aff122589
--- /dev/null
+++ b/test cases/common/14 cpp pch/pch/prog_pch.cc
@@ -0,0 +1,5 @@
+#if !defined(_MSC_VER)
+#error "This file is only for use with MSVC."
+#endif
+
+#include "prog.hh"