]> git.sesse.net Git - vlc/blob - src/missing.c
ce318c58ac0cc1c0dcf40053e28aedf83ba88bd8
[vlc] / src / missing.c
1 /*****************************************************************************
2  * missing.c: missing libvlccore symbols
3  *****************************************************************************
4  * Copyright (C) 2008 RĂ©mi Denis-Courmont
5  *
6  * This program is free software; you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License as published by
8  * the Free Software Foundation; either version 2 of the License, or
9  * (at your option) any later version.
10  *
11  * This program is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with this program; if not, write to the Free Software
18  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
19  *****************************************************************************/
20
21 /** \file
22  * This file contains dummy replacement API for disabled features
23  */
24
25 #ifdef HAVE_CONFIG_H
26 # include "config.h"
27 #endif
28
29 #include <vlc_common.h>
30 #include <assert.h>
31
32 #ifndef ENABLE_HTTPD
33 # include <vlc_httpd.h>
34
35 char *httpd_ClientIP (const httpd_client_t *cl, char *psz_ip)
36 {
37     (void) cl; (void) psz_ip;
38     assert (0);
39 }
40
41 void httpd_ClientModeBidir (httpd_client_t *cl)
42 {
43     (void) cl;
44     assert (0);
45 }
46
47 void httpd_ClientModeStream (httpd_client_t *cl)
48 {
49     (void) cl;
50     assert (0);
51 }
52
53 httpd_file_sys_t *httpd_FileDelete (httpd_file_t *file)
54 {
55     (void) file;
56     assert (0);
57 }
58
59 httpd_file_t *httpd_FileNew (httpd_host_t *host,
60                              const char *url, const char *content_type,
61                              const char *login, const char *password,
62                              const vlc_acl_t *acl,
63                              httpd_file_callback_t cb, httpd_file_sys_t *data)
64 {
65     (void) host;
66     (void) url; (void) content_type;
67     (void) login; (void) password; (void) acl;
68     (void) cb; (void) data;
69     assert (0);
70 }
71
72 httpd_handler_sys_t *httpd_HandlerDelete (httpd_handler_t *handler)
73 {
74     (void) handler;
75     assert (0);
76 }
77
78 httpd_handler_t *httpd_HandlerNew (httpd_host_t *host, const char *url,
79                                    const char *login, const char *password,
80                                    const vlc_acl_t *acl,
81                                    httpd_handler_callback_t cb,
82                                    httpd_handler_sys_t *data)
83 {
84     (void) host; (void) url;
85     (void) login; (void) password; (void) acl;
86     (void) cb; (void) data;
87     assert (0);
88 }
89
90 void httpd_HostDelete (httpd_host_t *h)
91 {
92     (void) h;
93     assert (0);
94 }
95
96 httpd_host_t *httpd_HostNew (vlc_object_t *obj, const char *host, int port)
97 {
98     (void) host; (void) port;
99     msg_Err (obj, "VLC httpd support not compiled-in!");
100     return NULL;
101 }
102
103 httpd_host_t *httpd_TLSHostNew (vlc_object_t *obj, const char *host, int port)
104 {
105      return httpd_HostNew (obj, host, port);
106 }
107
108 void httpd_MsgAdd (httpd_message_t *m, const char *name, const char *fmt, ...)
109 {
110     (void) m; (void) name; (void) fmt;
111     assert (0);
112 }
113
114 const char *httpd_MsgGet (const httpd_message_t *m, const char *name)
115 {
116     (void) m; (void) name;
117     assert (0);
118 }
119
120 void httpd_RedirectDelete (httpd_redirect_t *r)
121 {
122     (void) r;
123     assert (0);
124 }
125
126 httpd_redirect_t *httpd_RedirectNew (httpd_host_t *host,
127                                      const char *dst, const char *src)
128 {
129     (void) host; (void) dst; (void) src;
130     assert (0);
131 }
132
133 char *httpd_ServerIP (const httpd_client_t *client, char *ip)
134 {
135     (void) client; (void) ip;
136     assert (0);
137 }
138
139 void httpd_StreamDelete (httpd_stream_t *stream)
140 {
141     (void) stream;
142     assert (0);
143 }
144
145 int httpd_StreamHeader (httpd_stream_t *stream, uint8_t *data, int count)
146 {
147     (void) stream; (void) data; (void) count;
148     assert (0);
149 }
150
151 httpd_stream_t *httpd_StreamNew (httpd_host_t *host,
152                                  const char *url, const char *content_type,
153                                  const char *login, const char *password,
154                                  const vlc_acl_t *acl)
155 {
156     (void) host; (void) url; (void) content_type;
157     (void) login; (void) password; (void) acl;
158     assert (0);
159 }
160
161 int httpd_StreamSend (httpd_stream_t *stream, uint8_t *data, int count)
162 {
163     (void) stream; (void) data; (void) count;
164     assert (0);
165 }
166
167 int httpd_UrlCatch (httpd_url_t *url, int request, httpd_callback_t cb,
168                     httpd_callback_sys_t *data)
169 {
170     (void) url; (void) request; (void) cb; (void) data;
171     assert (0);
172 }
173
174 void httpd_UrlDelete (httpd_url_t *url)
175 {
176     (void) url;
177     assert (0);
178 }
179
180 httpd_url_t *httpd_UrlNew (httpd_host_t *host, const char *url,
181                            const char *login, const char *password,
182                            const vlc_acl_t *acl)
183 {
184     (void) host; (void) url; (void) login; (void) password; (void) acl;
185     assert (0);
186 }
187
188 httpd_url_t *httpd_UrlNewUnique (httpd_host_t *host, const char *url,
189                                  const char *login, const char *password,
190                                  const vlc_acl_t *acl)
191 {
192     (void) host; (void) url; (void) login; (void) password; (void) acl;
193     assert (0);
194 }
195 #endif /* !ENABLE_HTTPD */
196
197 #ifndef ENABLE_SOUT
198 # include <vlc_sout.h>
199
200 char *sdp_AddMedia (char **sdp, const char *type, const char *protocol,
201                     int dport, unsigned pt, bool bw_indep, unsigned bw,
202                     const char *ptname, unsigned clockrate, unsigned channels,
203                     const char *fmtp)
204 {
205     assert (*sdp == NULL);
206     return NULL;
207 }
208
209 char *sdp_AddAttribute (char **sdp, const char *name, const char *fmt, ...)
210 {
211     assert (*sdp == NULL);
212     return NULL;
213 }
214
215 int sout_AccessOutControl (sout_access_out_t *out, int query, ...)
216 {
217     assert (0);
218 }
219
220 void sout_AccessOutDelete (sout_access_out_t *out)
221 {
222     assert (0);
223 }
224
225 #undef sout_AccessOutNew
226 sout_access_out_t *sout_AccessOutNew (vlc_object_t *obj,
227                                       const char *access, const char *name)
228 {
229     msg_Err (obj, "Output support not compiled-in!");
230     return NULL;
231 }
232
233 ssize_t sout_AccessOutRead (sout_access_out_t *out, block_t *block)
234 {
235     assert (0);
236 }
237
238 int sout_AccessOutSeek (sout_access_out_t *out, off_t offset)
239 {
240     assert (0);
241 }
242
243 ssize_t sout_AccessOutWrite (sout_access_out_t *out, block_t *block)
244 {
245     assert (0);
246 }
247
248 #undef sout_AnnounceRegisterSDP
249 session_descriptor_t *sout_AnnounceRegisterSDP (vlc_object_t *obj,
250                                                 const char *sdp,
251                                                 const char *dst)
252 {
253     msg_Err (obj, "SDP export not compiled-in!");
254     return NULL;
255 }
256
257 #undef sout_AnnounceUnRegister
258 sout_AnnounceUnRegister (vlc_object_t *obj, session_descriptor_t *d)
259 {
260     assert (0);
261 }
262
263 #undef sout_EncoderCreate
264 encoder_t *sout_EncoderCreate( vlc_object_t *p_this )
265 {
266     msg_Err (p_this, "Encoding support not compiled-in!");
267     return NULL;
268 }
269
270 sout_input_t *sout_MuxAddStream (sout_mux_t *mux, es_format_t *fmt)
271 {
272     assert (0);
273 }
274
275 void sout_MuxDelete (sout_mux_t *mux)
276 {
277     assert (0);
278 }
279
280 void sout_MuxDeleteStream (sout_mux_t *mux, sout_input_t *input)
281 {
282     assert (0);
283 }
284
285 int sout_MuxGetStream (sout_mux_t *p_mux, int i_blocks, mtime_t *pi_dts)
286 {
287     assert (0);
288 }
289
290 sout_mux_t *sout_MuxNew (sout_instance_t *instance, const char *mux,
291                          sout_access_out_t *out)
292 {
293     assert (0);
294 }
295
296 void sout_MuxSendBuffer (sout_mux_t *mux, sout_input_t *input, block_t *block)
297 {
298     assert (0);
299 }
300
301 void sout_StreamChainDelete (sout_stream_t *p_first, sout_stream_t *p_last)
302 {
303     assert (0);
304 }
305
306 sout_stream_t *sout_StreamChainNew (sout_instance_t *p_sout, char *psz_chain,
307                                     sout_stream_t *p_next,
308                                     sout_stream_t **pp_last)
309 {
310     assert (0);
311 }
312
313 char *vlc_sdp_Start (vlc_object_t *obj, const char *cfg,
314                      const struct sockaddr *src, size_t srclen,
315                      const struct sockaddr *addr, size_t addrlen)
316 {
317     return NULL;
318 }
319 #endif /* !ENABLE_SOUT */
320
321 #ifndef ENABLE_VLM
322 # include <vlc_vlm.h>
323
324 int vlm_Control (vlm_t *vlm, int query, ...)
325 {
326     VLC_UNUSED (vlm);
327     assert (0);
328 }
329
330 void vlm_Delete (vlm_t *vlm)
331 {
332     VLC_UNUSED (vlm);
333     assert (0);
334 }
335
336 int vlm_ExecuteCommand (vlm_t *vlm, const char *cmd, vlm_message_t **pm)
337 {
338     VLC_UNUSED (vlm);
339     VLC_UNUSED (cmd);
340     VLC_UNUSED (pm);
341     assert (0);
342 }
343
344 vlm_message_t *vlm_MessageAdd (vlm_message_t *a, vlm_message_t *b)
345 {
346     VLC_UNUSED (a);
347     VLC_UNUSED (b);
348     assert (0);
349 }
350
351 void vlm_MessageDelete (vlm_message_t *m)
352 {
353     VLC_UNUSED (m);
354     assert (0);
355 }
356
357 vlm_message_t *vlm_MessageSimpleNew (const char *a)
358 {
359     VLC_UNUSED (a);
360     return NULL;
361 }
362
363 vlm_message_t *vlm_MessageNew (const char *a, const char *fmt, ...)
364 {
365     VLC_UNUSED (a);
366     VLC_UNUSED (fmt);
367     return vlm_MessageSimpleNew (a);
368 }
369
370 #undef vlm_New
371 vlm_t *vlm_New (vlc_object_t *obj)
372 {
373      msg_Err (obj, "VLM not compiled-in!");
374      return NULL;
375 }
376 #endif /* !ENABLE_VLM */
377
378 #ifndef MEDIA_LIBRARY
379 #include<vlc_media_library.h>
380
381 #undef ml_Get
382 media_library_t* ml_Get ( vlc_object_t* p_this )
383 {
384     VLC_UNUSED( p_this );
385     return NULL;
386 }
387
388 media_library_t* ml_Create ( vlc_object_t *p_this, char* psz_name )
389 {
390     VLC_UNUSED( p_this );
391     VLC_UNUSED( psz_name );
392     return NULL;
393 }
394
395 void ml_Destroy( vlc_object_t * p_this )
396 {
397     VLC_UNUSED( p_this );
398     assert( 0 );
399 }
400
401 ml_media_t* media_New( media_library_t* p_ml, int id, ml_select_e select, bool reload )
402 {
403     VLC_UNUSED( p_ml );
404     VLC_UNUSED( id );
405     VLC_UNUSED( select );
406     VLC_UNUSED( reload );
407     assert( 0 );
408     return NULL;
409 }
410
411 #undef ml_UpdateSimple
412 int ml_UpdateSimple( media_library_t *p_media_library, ml_select_e selected_type,
413                                      const char* psz_lvalue, int id, ... )
414 {
415     VLC_UNUSED( p_media_library );
416     VLC_UNUSED( selected_type );
417     VLC_UNUSED( psz_lvalue );
418     VLC_UNUSED( id );
419     assert( 0 );
420     return 0;
421 }
422
423 ml_ftree_t* ml_OpConnectChilds( ml_op_e op, ml_ftree_t* left, ml_ftree_t* right )
424 {
425     VLC_UNUSED( op );
426     VLC_UNUSED( left );
427     VLC_UNUSED( right );
428     assert( 0 );
429     return NULL;
430 }
431
432 ml_ftree_t* ml_FtreeSpec( ml_ftree_t* tree, ml_select_e crit, int limit,
433                                           char* sort )
434 {
435     VLC_UNUSED( tree );
436     VLC_UNUSED( crit );
437     VLC_UNUSED( limit );
438     VLC_UNUSED( sort );
439     assert( 0 );
440     return NULL;
441 }
442
443 void ml_PlaySmartPlaylistBasedOn( media_library_t* p_ml,
444                                                 ml_ftree_t* p_tree )
445 {
446     VLC_UNUSED( p_ml );
447     VLC_UNUSED( p_tree );
448     assert( 0 );
449 }
450
451 void ml_DeletePersonTypeFromMedia( ml_media_t* p_media, const char *psz_role )
452 {
453     VLC_UNUSED( p_media );
454     VLC_UNUSED( psz_role );
455     assert( 0 );
456 }
457
458 ml_person_t*  ml_GetPersonsFromMedia( media_library_t* p_ml,
459                                                     ml_media_t* p_media,
460                                                     const char *psz_role )
461 {
462     VLC_UNUSED( p_ml );
463     VLC_UNUSED( p_media );
464     VLC_UNUSED( psz_role );
465     assert( 0 );
466     return NULL;
467 }
468 #endif /* !MEDIA_LIBRARY */