summaryrefslogtreecommitdiffstats
path: root/src/tests/include
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-15 20:38:23 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-15 20:38:23 +0000
commitff6e3c025658a5fa1affd094f220b623e7e1b24b (patch)
tree9faab72d69c92d24e349d184f5869b9796f17e0c /src/tests/include
parentInitial commit. (diff)
downloadlibplacebo-upstream.tar.xz
libplacebo-upstream.zip
Adding upstream version 6.338.2.upstream/6.338.2upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'src/tests/include')
-rw-r--r--src/tests/include/include_tmpl.c1
-rw-r--r--src/tests/include/include_tmpl.cpp3
-rw-r--r--src/tests/include/meson.build35
3 files changed, 39 insertions, 0 deletions
diff --git a/src/tests/include/include_tmpl.c b/src/tests/include/include_tmpl.c
new file mode 100644
index 0000000..dd1000e
--- /dev/null
+++ b/src/tests/include/include_tmpl.c
@@ -0,0 +1 @@
+#include <libplacebo/@header@>
diff --git a/src/tests/include/include_tmpl.cpp b/src/tests/include/include_tmpl.cpp
new file mode 100644
index 0000000..2b6334c
--- /dev/null
+++ b/src/tests/include/include_tmpl.cpp
@@ -0,0 +1,3 @@
+#define PL_LIBAV_IMPLEMENTATION 0
+#define PL_DAV1D_IMPLEMENTATION 0
+#include <libplacebo/@header@>
diff --git a/src/tests/include/meson.build b/src/tests/include/meson.build
new file mode 100644
index 0000000..25dfaee
--- /dev/null
+++ b/src/tests/include/meson.build
@@ -0,0 +1,35 @@
+include_tmpl_langs = ['c', 'cpp']
+
+# Ensure all headers compile
+
+test_include_sources = []
+foreach h : headers
+
+ if (h.contains('internal') or
+ h.contains('dav1d') and not dav1d.found() or
+ h.contains('libav') and not libav_found or
+ h.contains('d3d11') and not d3d11_header)
+ continue
+ endif
+
+ foreach lang : include_tmpl_langs
+
+ test_include_sources += configure_file(
+ input: 'include_tmpl.' + lang,
+ output: 'include_@0@.@1@'.format(h.underscorify(), lang),
+ configuration: {
+ 'header': h
+ },
+ )
+
+ endforeach
+
+endforeach
+
+static_library('test_include', test_include_sources,
+ dependencies: [tdep_static, lavu, lavc, lavf],
+ include_directories: [inc, vulkan_headers_inc],
+ implicit_include_directories: false,
+ c_args: ['-Wall', '-Wextra', '-Wpedantic'],
+ cpp_args: ['-Wall', '-Wextra', '-Wpedantic'],
+)