summaryrefslogtreecommitdiffstats
path: root/test cases/frameworks/22 gir link order/get-prgname
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-29 04:41:38 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-29 04:41:38 +0000
commit7b6e527f440cd7e6f8be2b07cee320ee6ca18786 (patch)
tree4a2738d69fa2814659fdadddf5826282e73d81f4 /test cases/frameworks/22 gir link order/get-prgname
parentInitial commit. (diff)
downloadmeson-7b6e527f440cd7e6f8be2b07cee320ee6ca18786.tar.xz
meson-7b6e527f440cd7e6f8be2b07cee320ee6ca18786.zip
Adding upstream version 1.0.1.upstream/1.0.1upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'test cases/frameworks/22 gir link order/get-prgname')
-rw-r--r--test cases/frameworks/22 gir link order/get-prgname/get-prgname.c8
-rw-r--r--test cases/frameworks/22 gir link order/get-prgname/get-prgname.h6
-rw-r--r--test cases/frameworks/22 gir link order/get-prgname/meson.build13
3 files changed, 27 insertions, 0 deletions
diff --git a/test cases/frameworks/22 gir link order/get-prgname/get-prgname.c b/test cases/frameworks/22 gir link order/get-prgname/get-prgname.c
new file mode 100644
index 0000000..356b45e
--- /dev/null
+++ b/test cases/frameworks/22 gir link order/get-prgname/get-prgname.c
@@ -0,0 +1,8 @@
+#include "get-prgname.h"
+
+#include <glib.h>
+
+const char *get_prgname_get_name (void)
+{
+ return g_get_prgname ();
+}
diff --git a/test cases/frameworks/22 gir link order/get-prgname/get-prgname.h b/test cases/frameworks/22 gir link order/get-prgname/get-prgname.h
new file mode 100644
index 0000000..cb5118e
--- /dev/null
+++ b/test cases/frameworks/22 gir link order/get-prgname/get-prgname.h
@@ -0,0 +1,6 @@
+#ifndef GET_PRGNAME_H
+#define GET_PRGNAME_H
+
+const char *get_prgname_get_name (void);
+
+#endif /* GET_PRGNAME_H */
diff --git a/test cases/frameworks/22 gir link order/get-prgname/meson.build b/test cases/frameworks/22 gir link order/get-prgname/meson.build
new file mode 100644
index 0000000..6a7489d
--- /dev/null
+++ b/test cases/frameworks/22 gir link order/get-prgname/meson.build
@@ -0,0 +1,13 @@
+get_prgname_sources = ['get-prgname.c', 'get-prgname.h']
+get_prgname_lib = shared_library(
+ 'get-prgname',
+ sources : get_prgname_sources,
+ dependencies : [glib],
+ install : false,
+)
+
+get_prgname_includes = include_directories('.')
+get_prgname = declare_dependency(
+ include_directories : get_prgname_includes,
+ link_with : get_prgname_lib,
+)