diff options
Diffstat (limited to 'src/contrib/service/conversation/meson.build')
-rw-r--r-- | src/contrib/service/conversation/meson.build | 193 |
1 files changed, 193 insertions, 0 deletions
diff --git a/src/contrib/service/conversation/meson.build b/src/contrib/service/conversation/meson.build new file mode 100644 index 000000000..b3fb070d9 --- /dev/null +++ b/src/contrib/service/conversation/meson.build | |||
@@ -0,0 +1,193 @@ | |||
1 | libgnunetconversation_src = ['conversation_api.c', 'conversation_api_call.c'] | ||
2 | |||
3 | gnunetserviceconversation_src = ['gnunet-service-conversation.c'] | ||
4 | |||
5 | gnunetconversationproxy_src = ['gnunet-conversation-proxy.c'] | ||
6 | |||
7 | configure_file(input : 'conversation.conf.in', | ||
8 | output : 'conversation.conf', | ||
9 | configuration : cdata, | ||
10 | install: true, | ||
11 | install_dir: pkgcfgdir) | ||
12 | |||
13 | |||
14 | if get_option('monolith') | ||
15 | foreach p : libgnunetconversation_src + gnunetserviceconversation_src | ||
16 | gnunet_src += 'conversation/' + p | ||
17 | endforeach | ||
18 | subdir_done() | ||
19 | endif | ||
20 | |||
21 | libgnunetmicrophone = library('gnunetmicrophone', | ||
22 | ['microphone.c'], | ||
23 | soversion: '0', | ||
24 | version: '0.0.0', | ||
25 | dependencies: [libgnunetutil_dep], | ||
26 | include_directories: [incdir, configuration_inc], | ||
27 | install: true, | ||
28 | install_dir: get_option('libdir')) | ||
29 | libgnunetmicrophone_dep = declare_dependency(link_with : libgnunetmicrophone) | ||
30 | pkg.generate(libgnunetmicrophone, url: 'https://www.gnunet.org', | ||
31 | description : 'Provides API to access to microphone') | ||
32 | |||
33 | libgnunetspeaker = library('gnunetspeaker', | ||
34 | ['speaker.c'], | ||
35 | soversion: '0', | ||
36 | version: '0.0.0', | ||
37 | dependencies: [libgnunetutil_dep], | ||
38 | include_directories: [incdir, configuration_inc], | ||
39 | install: true, | ||
40 | install_dir: get_option('libdir')) | ||
41 | libgnunetspeaker_dep = declare_dependency(link_with : libgnunetspeaker) | ||
42 | pkg.generate(libgnunetspeaker, url: 'https://www.gnunet.org', | ||
43 | description : 'Provides API to access to speaker') | ||
44 | |||
45 | libgnunetconversation = library('gnunetconversation', | ||
46 | libgnunetconversation_src, | ||
47 | soversion: '0', | ||
48 | version: '0.0.0', | ||
49 | dependencies: [libgnunetutil_dep, | ||
50 | libgnunetgnsrecord_dep, | ||
51 | libgnunetgns_dep, | ||
52 | libgnunetnamestore_dep, | ||
53 | libgnunetidentity_dep], | ||
54 | include_directories: [incdir, configuration_inc], | ||
55 | install: true, | ||
56 | install_dir: get_option('libdir')) | ||
57 | libgnunetconversation_dep = declare_dependency(link_with : libgnunetconversation) | ||
58 | pkg.generate(libgnunetconversation, url: 'https://www.gnunet.org', | ||
59 | description : 'Provides API to access to conversation') | ||
60 | |||
61 | shared_module('gnunet_plugin_gnsrecord_conversation', | ||
62 | ['plugin_gnsrecord_conversation.c'], | ||
63 | dependencies: [libgnunetutil_dep, | ||
64 | libgnunetconversation_dep, | ||
65 | libgnunetgns_dep, | ||
66 | libgnunetgnsrecord_dep, | ||
67 | libgnunetidentity_dep], | ||
68 | include_directories: [incdir, configuration_inc], | ||
69 | install: true, | ||
70 | install_dir: get_option('libdir')/'gnunet') | ||
71 | |||
72 | executable ('gnunet-conversation', | ||
73 | 'gnunet-conversation.c', | ||
74 | dependencies: [libgnunetconversation_dep, | ||
75 | libgnunetgns_dep, | ||
76 | libgnunetgnsrecord_dep, | ||
77 | libgnunetnamestore_dep, | ||
78 | libgnunetspeaker_dep, | ||
79 | libgnunetmicrophone_dep, | ||
80 | libgnunetidentity_dep, | ||
81 | libgnunetutil_dep], | ||
82 | include_directories: [incdir, configuration_inc], | ||
83 | install: true, | ||
84 | install_dir: get_option('bindir')) | ||
85 | |||
86 | executable ('gnunet-service-conversation', | ||
87 | gnunetserviceconversation_src, | ||
88 | dependencies: [libgnunetconversation_dep, | ||
89 | libgnunetutil_dep, | ||
90 | libgnunetspeaker_dep, | ||
91 | libgnunetmicrophone_dep, | ||
92 | libgnunetidentity_dep, | ||
93 | libgnunetcadet_dep], | ||
94 | include_directories: [incdir, configuration_inc], | ||
95 | install: true, | ||
96 | install_dir: get_option('libdir') / 'gnunet' / 'libexec') | ||
97 | |||
98 | helperrecord_src = ['gnunet-helper-audio-record.c'] | ||
99 | helperplayback_src = ['gnunet-helper-audio-record.c'] | ||
100 | if conversation_backend == 'gst' | ||
101 | helperrecord_src = ['gnunet-helper-audio-record-gst.c'] | ||
102 | helperplayback_src = ['gnunet-helper-audio-playback-gst.c'] | ||
103 | endif | ||
104 | |||
105 | executable ('gnunet-helper-audio-record', | ||
106 | helperrecord_src, | ||
107 | dependencies: [libgnunetconversation_dep, | ||
108 | libgnunetutil_dep, | ||
109 | libgnunetspeaker_dep, | ||
110 | libgnunetmicrophone_dep, | ||
111 | gst_dep, | ||
112 | ogg_dep, | ||
113 | pulse_dep, | ||
114 | opus_dep | ||
115 | ], | ||
116 | include_directories: [incdir, configuration_inc], | ||
117 | install: true, | ||
118 | install_dir: get_option('libdir') / 'gnunet' / 'libexec') | ||
119 | |||
120 | executable ('gnunet-helper-audio-playback', | ||
121 | helperplayback_src, | ||
122 | dependencies: [libgnunetconversation_dep, | ||
123 | libgnunetutil_dep, | ||
124 | libgnunetspeaker_dep, | ||
125 | libgnunetmicrophone_dep, | ||
126 | gst_dep, | ||
127 | ogg_dep, | ||
128 | pulse_dep, | ||
129 | opus_dep | ||
130 | ], | ||
131 | include_directories: [incdir, configuration_inc], | ||
132 | install: true, | ||
133 | install_dir: get_option('libdir') / 'gnunet' / 'libexec') | ||
134 | |||
135 | testconvapi = executable ('test_conversation_api', | ||
136 | ['test_conversation_api.c'], | ||
137 | dependencies: [libgnunetconversation_dep, | ||
138 | libgnunetutil_dep, | ||
139 | libgnunetidentity_dep, | ||
140 | libgnunettesting_dep, | ||
141 | libgnunetgnsrecord_dep, | ||
142 | libgnunetnamestore_dep, | ||
143 | libgnunetspeaker_dep, | ||
144 | libgnunetmicrophone_dep, | ||
145 | ], | ||
146 | include_directories: [incdir, configuration_inc], | ||
147 | install: true, | ||
148 | install_dir: get_option('libdir') / 'gnunet' / 'libexec') | ||
149 | |||
150 | testconvapitwo = executable ('test_conversation_api_twocalls', | ||
151 | ['test_conversation_api_twocalls.c'], | ||
152 | dependencies: [libgnunetconversation_dep, | ||
153 | libgnunetutil_dep, | ||
154 | libgnunetidentity_dep, | ||
155 | libgnunettesting_dep, | ||
156 | libgnunetgnsrecord_dep, | ||
157 | libgnunetnamestore_dep, | ||
158 | libgnunetspeaker_dep, | ||
159 | libgnunetmicrophone_dep, | ||
160 | ], | ||
161 | include_directories: [incdir, configuration_inc], | ||
162 | install: true, | ||
163 | install_dir: get_option('libdir') / 'gnunet' / 'libexec') | ||
164 | |||
165 | testconvapireject = executable ('test_conversation_api_reject', | ||
166 | ['test_conversation_api_reject.c'], | ||
167 | dependencies: [libgnunetconversation_dep, | ||
168 | libgnunetutil_dep, | ||
169 | libgnunetidentity_dep, | ||
170 | libgnunettesting_dep, | ||
171 | libgnunetgnsrecord_dep, | ||
172 | libgnunetnamestore_dep, | ||
173 | libgnunetspeaker_dep, | ||
174 | libgnunetmicrophone_dep, | ||
175 | ], | ||
176 | include_directories: [incdir, configuration_inc], | ||
177 | install: true, | ||
178 | install_dir: get_option('libdir') / 'gnunet' / 'libexec') | ||
179 | |||
180 | configure_file(input : 'test_conversation.conf', | ||
181 | output : 'test_conversation.conf', | ||
182 | copy: true, | ||
183 | install: false) | ||
184 | |||
185 | test('test_conversation_api', testconvapi, workdir: meson.current_build_dir(), | ||
186 | suite: 'conversation') | ||
187 | |||
188 | test('test_conversation_api_twocalls', testconvapitwo, workdir: meson.current_build_dir(), | ||
189 | suite: 'conversation') | ||
190 | |||
191 | test('test_conversation_api_reject', testconvapireject, workdir: meson.current_build_dir(), | ||
192 | suite: 'conversation') | ||
193 | |||