Commit 5822daa6 authored by Max Kellermann's avatar Max Kellermann

output_internal, ...: add extern "C"

parent 4808c7ef
...@@ -30,6 +30,10 @@ extern const struct encoder_plugin *const encoder_plugins[]; ...@@ -30,6 +30,10 @@ extern const struct encoder_plugin *const encoder_plugins[];
(plugin = *encoder_plugin_iterator) != NULL; \ (plugin = *encoder_plugin_iterator) != NULL; \
++encoder_plugin_iterator) ++encoder_plugin_iterator)
#ifdef __cplusplus
extern "C" {
#endif
/** /**
* Looks up an encoder plugin by its name. * Looks up an encoder plugin by its name.
* *
...@@ -40,4 +44,8 @@ extern const struct encoder_plugin *const encoder_plugins[]; ...@@ -40,4 +44,8 @@ extern const struct encoder_plugin *const encoder_plugins[];
const struct encoder_plugin * const struct encoder_plugin *
encoder_plugin_get(const char *name); encoder_plugin_get(const char *name);
#ifdef __cplusplus
}
#endif
#endif #endif
...@@ -25,6 +25,10 @@ ...@@ -25,6 +25,10 @@
#include <stdarg.h> #include <stdarg.h>
#ifdef __cplusplus
extern "C" {
#endif
char* char*
icy_server_metadata_header(const char *name, icy_server_metadata_header(const char *name,
const char *genre, const char *url, const char *genre, const char *url,
...@@ -33,4 +37,8 @@ icy_server_metadata_header(const char *name, ...@@ -33,4 +37,8 @@ icy_server_metadata_header(const char *name,
struct page* struct page*
icy_server_metadata_page(const struct tag *tag, ...); icy_server_metadata_page(const struct tag *tag, ...);
#ifdef __cplusplus
}
#endif
#endif #endif
...@@ -257,6 +257,10 @@ audio_output_command_is_finished(const struct audio_output *ao) ...@@ -257,6 +257,10 @@ audio_output_command_is_finished(const struct audio_output *ao)
return ao->command == AO_COMMAND_NONE; return ao->command == AO_COMMAND_NONE;
} }
#ifdef __cplusplus
extern "C" {
#endif
struct audio_output * struct audio_output *
audio_output_new(const struct config_param *param, audio_output_new(const struct config_param *param,
struct player_control *pc, struct player_control *pc,
...@@ -273,4 +277,8 @@ ao_base_finish(struct audio_output *ao); ...@@ -273,4 +277,8 @@ ao_base_finish(struct audio_output *ao);
void void
audio_output_free(struct audio_output *ao); audio_output_free(struct audio_output *ao);
#ifdef __cplusplus
}
#endif
#endif #endif
...@@ -53,6 +53,10 @@ struct page { ...@@ -53,6 +53,10 @@ struct page {
unsigned char data[sizeof(long)]; unsigned char data[sizeof(long)];
}; };
#ifdef __cplusplus
extern "C" {
#endif
/** /**
* Creates a new #page object, and copies data from the specified * Creates a new #page object, and copies data from the specified
* buffer. It is initialized with a reference count of 1. * buffer. It is initialized with a reference count of 1.
...@@ -91,4 +95,8 @@ page_ref(struct page *page); ...@@ -91,4 +95,8 @@ page_ref(struct page *page);
bool bool
page_unref(struct page *page); page_unref(struct page *page);
#ifdef __cplusplus
}
#endif
#endif #endif
...@@ -34,6 +34,10 @@ resolver_quark(void) ...@@ -34,6 +34,10 @@ resolver_quark(void)
return g_quark_from_static_string("resolver"); return g_quark_from_static_string("resolver");
} }
#ifdef __cplusplus
extern "C" {
#endif
/** /**
* Converts the specified socket address into a string in the form * Converts the specified socket address into a string in the form
* "IP:PORT". The return value must be freed with g_free() when you * "IP:PORT". The return value must be freed with g_free() when you
...@@ -63,4 +67,8 @@ resolve_host_port(const char *host_port, unsigned default_port, ...@@ -63,4 +67,8 @@ resolve_host_port(const char *host_port, unsigned default_port,
int flags, int socktype, int flags, int socktype,
GError **error_r); GError **error_r);
#ifdef __cplusplus
}
#endif
#endif #endif
...@@ -32,6 +32,10 @@ typedef void (*server_socket_callback_t)(int fd, ...@@ -32,6 +32,10 @@ typedef void (*server_socket_callback_t)(int fd,
size_t address_length, int uid, size_t address_length, int uid,
void *ctx); void *ctx);
#ifdef __cplusplus
extern "C" {
#endif
struct server_socket * struct server_socket *
server_socket_new(server_socket_callback_t callback, void *callback_ctx); server_socket_new(server_socket_callback_t callback, void *callback_ctx);
...@@ -90,4 +94,8 @@ bool ...@@ -90,4 +94,8 @@ bool
server_socket_add_path(struct server_socket *ss, const char *path, server_socket_add_path(struct server_socket *ss, const char *path,
GError **error_r); GError **error_r);
#ifdef __cplusplus
}
#endif
#endif #endif
...@@ -30,6 +30,10 @@ struct timer { ...@@ -30,6 +30,10 @@ struct timer {
int rate; int rate;
}; };
#ifdef __cplusplus
extern "C" {
#endif
struct timer *timer_new(const struct audio_format *af); struct timer *timer_new(const struct audio_format *af);
void timer_free(struct timer *timer); void timer_free(struct timer *timer);
...@@ -48,4 +52,8 @@ timer_delay(const struct timer *timer); ...@@ -48,4 +52,8 @@ timer_delay(const struct timer *timer);
void timer_sync(struct timer *timer); void timer_sync(struct timer *timer);
#ifdef __cplusplus
}
#endif
#endif #endif
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment