aboutsummaryrefslogtreecommitdiff
path: root/lib/meson-projects/meson.build
diff options
context:
space:
mode:
authorcrupest <crupest@outlook.com>2023-10-07 16:38:56 +0800
committercrupest <crupest@outlook.com>2023-10-07 16:38:56 +0800
commitd080481d8d2c358c553eddcb10786131b59bc9b6 (patch)
treebc36630a9c3bffcaf37e9397b02a2f17a0a5802e /lib/meson-projects/meson.build
parenta1dbbdf5fc04ac091be91add80aafe09d48cfea9 (diff)
downloadcru-d080481d8d2c358c553eddcb10786131b59bc9b6.tar.gz
cru-d080481d8d2c358c553eddcb10786131b59bc9b6.tar.bz2
cru-d080481d8d2c358c553eddcb10786131b59bc9b6.zip
...
Diffstat (limited to 'lib/meson-projects/meson.build')
-rw-r--r--lib/meson-projects/meson.build16
1 files changed, 16 insertions, 0 deletions
diff --git a/lib/meson-projects/meson.build b/lib/meson-projects/meson.build
index c373f0ce..0434dfb0 100644
--- a/lib/meson-projects/meson.build
+++ b/lib/meson-projects/meson.build
@@ -1,5 +1,21 @@
project('cru-deps', 'c', 'cpp')
+hello_word_test = '''
+#include <stdio.h>
+
+int main() {
+ printf("Hello world!");
+ return 0;
+}
+'''
+
+cc = meson.get_compiler('c')
+hello_world_result = cc.run(hello_word_test, name: 'hello world')
+
+if hello_world_result.returncode() != 0
+ error('Failed to hello world!')
+endif
+
if get_option('cairo').enabled()
subproject('glib')
subproject('cairo')