remove spalib

This commit is contained in:
Wim Taymans 2018-08-14 12:33:53 +02:00
parent d3b9a52ec4
commit 9d36b85dd6
49 changed files with 566 additions and 1162 deletions

View file

@ -1,67 +1,54 @@
executable('test-mixer', 'test-mixer.c',
include_directories : [spa_inc ],
dependencies : [dl_lib, pthread_lib, mathlib],
link_with : spalib,
install : false)
executable('test-bluez5', 'test-bluez5.c',
include_directories : [spa_inc, spa_libinc ],
include_directories : [spa_inc ],
dependencies : [dl_lib, pthread_lib, mathlib, dbus_dep],
link_with : spalib,
install : false)
executable('test-ringbuffer', 'test-ringbuffer.c',
include_directories : [spa_inc, spa_libinc ],
include_directories : [spa_inc ],
dependencies : [dl_lib, pthread_lib],
link_with : spalib,
install : false)
executable('test-graph', 'test-graph.c',
include_directories : [spa_inc, spa_libinc ],
include_directories : [spa_inc ],
dependencies : [dl_lib, pthread_lib],
link_with : spalib,
install : false)
executable('test-graph2', 'test-graph2.c',
include_directories : [spa_inc ],
dependencies : [dl_lib, pthread_lib],
link_with : spalib,
install : false)
executable('test-perf', 'test-perf.c',
include_directories : [spa_inc, spa_libinc ],
include_directories : [spa_inc ],
dependencies : [dl_lib, pthread_lib],
link_with : spalib,
install : false)
executable('stress-ringbuffer', 'stress-ringbuffer.c',
include_directories : [spa_inc, spa_libinc ],
include_directories : [spa_inc ],
dependencies : [dl_lib, pthread_lib],
link_with : spalib,
install : false)
if sdl_dep.found()
executable('test-v4l2', 'test-v4l2.c',
include_directories : [spa_inc, spa_libinc ],
include_directories : [spa_inc ],
dependencies : [dl_lib, sdl_dep, pthread_lib],
link_with : spalib,
install : false)
endif
executable('test-props', 'test-props.c',
include_directories : [spa_inc, spa_libinc ],
include_directories : [spa_inc ],
dependencies : [],
link_with : spalib,
install : false)
executable('test-props2', 'test-props2.c',
include_directories : [spa_inc, spa_libinc ],
include_directories : [spa_inc ],
dependencies : [],
link_with : spalib,
install : false)
#executable('test-props4', 'test-props4.c',
# include_directories : [spa_inc, spa_libinc ],
# include_directories : [spa_inc ],
# dependencies : [],
# link_with : spalib,
# install : false)
executable('test-props5', 'test-props5.c',
include_directories : [spa_inc, spa_libinc ],
include_directories : [spa_inc ],
dependencies : [],
link_with : spalib,
install : false)
executable('test-control', 'test-control.c',
include_directories : [spa_inc, spa_libinc ],
include_directories : [spa_inc ],
dependencies : [dl_lib, pthread_lib, mathlib],
link_with : spalib,
install : false)

View file

@ -50,7 +50,7 @@ static struct spa_log *logger;
#include <spa/graph/graph.h>
#include <spa/graph/graph-scheduler6.h>
#include <lib/debug.h>
#include <spa/debug/pod.h>
struct type {
uint32_t log;
@ -133,7 +133,7 @@ struct data {
static void inspect_item(struct data *data, struct spa_pod *item)
{
spa_debug_pod(item, 0);
spa_debug_pod(0, data->map, item);
}
static void monitor_event(void *_data, struct spa_event *event)
@ -222,7 +222,6 @@ int main(int argc, char *argv[])
data.support[0].data = data.map;
data.n_support = 1;
init_type(&data.type, data.map);
spa_debug_set_type_map(data.map);
if ((res = get_handle(&data, &handle,
"build/spa/plugins/support/libspa-support.so",

View file

@ -49,7 +49,7 @@ static SPA_LOG_IMPL(default_log);
#include <spa/graph/graph.h>
#include <spa/graph/graph-scheduler6.h>
#include <lib/debug.h>
#include <spa/debug/pod.h>
struct type {
uint32_t node;
@ -326,7 +326,7 @@ static int make_nodes(struct data *data, const char *device)
":", data->type.props_device, "s", device ? device : "hw:0",
":", data->type.props_min_latency, "i", MIN_LATENCY);
spa_debug_pod(props, 0);
spa_debug_pod(0, data->map, props);
if ((res = spa_node_set_param(data->sink, data->type.param.idProps, 0, props)) < 0)
printf("got set_props error %d\n", res);
@ -431,7 +431,7 @@ static int negotiate_formats(struct data *data)
":", data->type.format_audio.rate, "i", 44100,
":", data->type.format_audio.channels, "i", 2);
spa_debug_pod(filter, 0);
spa_debug_pod(0, data->map, filter);
spa_log_debug(&default_log.log, "enum_params");
if ((res = spa_node_port_enum_params(data->sink,
@ -440,7 +440,7 @@ static int negotiate_formats(struct data *data)
filter, &format, &b)) <= 0)
return -EBADF;
spa_debug_pod(format, 0);
spa_debug_pod(0, data->map, format);
spa_log_debug(&default_log.log, "sink set_param");
if ((res = spa_node_port_set_param(data->sink,
@ -574,8 +574,6 @@ int main(int argc, char *argv[])
data.data_loop.remove_source = do_remove_source;
data.data_loop.invoke = do_invoke;
spa_debug_set_type_map(data.map);
if ((str = getenv("SPA_DEBUG")))
data.log->level = atoi(str);

View file

@ -44,7 +44,7 @@ static SPA_LOG_IMPL(default_log);
#include <spa/graph/graph.h>
#include <spa/graph/graph-scheduler6.h>
#include <lib/debug.h>
#include <spa/debug/pod.h>
struct type {
uint32_t node;
@ -305,7 +305,7 @@ static int make_nodes(struct data *data, const char *device)
":", data->type.props_device, "s", device ? device : "hw:0",
":", data->type.props_min_latency, "i", MIN_LATENCY);
spa_debug_pod(props, 0);
spa_debug_pod(0, data->map, props);
if ((res = spa_node_set_param(data->sink, data->type.param.idProps, 0, props)) < 0)
printf("got set_props error %d\n", res);
@ -399,7 +399,7 @@ static int negotiate_formats(struct data *data)
":", data->type.format_audio.rate, "i", 44100,
":", data->type.format_audio.channels, "i", 2);
spa_debug_pod(filter, 0);
spa_debug_pod(0, data->map, filter);
spa_log_debug(&default_log.log, "enum_params");
if ((res = spa_node_port_enum_params(data->sink,
@ -408,7 +408,7 @@ static int negotiate_formats(struct data *data)
filter, &format, &b)) <= 0)
return -EBADF;
spa_debug_pod(format, 0);
spa_debug_pod(0, data->map, format);
spa_log_debug(&default_log.log, "sink set_param");
if ((res = spa_node_port_set_param(data->sink,
@ -566,8 +566,6 @@ int main(int argc, char *argv[])
data.data_loop.remove_source = do_remove_source;
data.data_loop.invoke = do_invoke;
spa_debug_set_type_map(data.map);
if ((str = getenv("SPA_DEBUG")))
data.log->level = atoi(str);

View file

@ -29,8 +29,8 @@
#include <spa/pod/builder.h>
#include <spa/pod/parser.h>
#include <spa/param/video/format-utils.h>
#include <lib/debug.h>
#include <spa/debug/pod.h>
#include <spa/debug/format.h>
#if 0
/* { video/raw,
@ -250,8 +250,8 @@ static void do_static_struct(struct spa_type_map *map)
}
};
spa_debug_pod(&test_format.fmt.pod, 0);
spa_debug_pod(&test_format.fmt.pod, SPA_DEBUG_FLAG_FORMAT);
spa_debug_pod(0, map, &test_format.fmt.pod);
spa_debug_format(0, map, &test_format.fmt.pod);
{
uint32_t format = -1;
@ -283,7 +283,6 @@ int main(int argc, char *argv[])
struct spa_type_map *map = &default_map.map;
type_init(map);
spa_debug_set_type_map(map);
spa_pod_builder_init(&b, buffer, sizeof(buffer));
@ -317,7 +316,7 @@ int main(int argc, char *argv[])
fmt = spa_pod_builder_pop(&b);
spa_debug_pod(&fmt->pod, 0);
spa_debug_pod(0, map, &fmt->pod);
spa_pod_builder_init(&b, buffer, sizeof(buffer));
@ -335,8 +334,8 @@ int main(int argc, char *argv[])
2, &SPA_FRACTION(0,1),
&SPA_FRACTION(INT32_MAX,1));
spa_debug_pod(&fmt->pod, 0);
spa_debug_pod(&fmt->pod, SPA_DEBUG_FLAG_FORMAT);
spa_debug_pod(0, map, &fmt->pod);
spa_debug_format(0, map, &fmt->pod);
spa_pod_builder_init(&b, buffer, sizeof(buffer));
@ -365,8 +364,8 @@ int main(int argc, char *argv[])
&SPA_FRACTION(INT32_MAX,1),
">", NULL);
spa_debug_pod(&fmt->pod, 0);
spa_debug_pod(&fmt->pod, SPA_DEBUG_FLAG_FORMAT);
spa_debug_pod(0, map, &fmt->pod);
spa_debug_format(0, map, &fmt->pod);
do_static_struct(map);

View file

@ -30,7 +30,7 @@
#include <spa/pod/parser.h>
#include <spa/param/video/format.h>
#include <lib/debug.h>
#include <spa/debug/pod.h>
static SPA_TYPE_MAP_IMPL(default_map, 4096);
@ -43,8 +43,6 @@ int main(int argc, char *argv[])
struct spa_pod_parser prs;
struct spa_type_map *map = &default_map.map;
spa_debug_set_type_map(map);
b.data = buffer;
b.size = 1024;
@ -86,11 +84,11 @@ int main(int argc, char *argv[])
spa_pod_builder_pop(&b);
obj = spa_pod_builder_pop(&b);
spa_debug_pod(obj, 0);
spa_debug_pod(0, map, obj);
struct spa_pod_prop *p = spa_pod_find_prop(obj, 4);
printf("%d %d\n", p->body.key, p->body.flags);
spa_debug_pod(&p->body.value, 0);
spa_debug_pod(0, map, &p->body.value);
obj = spa_pod_builder_deref(&b, ref);

View file

@ -24,8 +24,9 @@
#include <errno.h>
#include <spa/pod/parser.h>
#include <spa/pod/builder.h>
#include <lib/debug.h>
#include <spa/debug/pod.h>
int main(int argc, char *argv[])
{
@ -52,7 +53,7 @@ int main(int argc, char *argv[])
2, &SPA_FRACTION(0,1),
&SPA_FRACTION(INT32_MAX, 1),
">", NULL);
spa_debug_pod(fmt, 0);
spa_debug_pod(0, NULL, fmt);
spa_pod_parser_pod(&prs, fmt);
res = spa_pod_parser_get(&prs,
@ -67,7 +68,7 @@ int main(int argc, char *argv[])
printf("media-type:%d media-subtype:%d\n", media_type, media_subtype);
printf("framerate:\n");
if (pod)
spa_debug_pod(pod, 0);
spa_debug_pod(0, NULL, pod);
printf("format: %d\n", fmt_value);
spa_pod_builder_init(&b, buffer, sizeof(buffer));
@ -76,7 +77,7 @@ int main(int argc, char *argv[])
" P", NULL,
" [ i", 44, "i",45,"]"
">", NULL);
spa_debug_pod(pod, 0);
spa_debug_pod(0, NULL, pod);
spa_pod_parser_pod(&prs, pod);
res = spa_pod_parser_get(&prs,

View file

@ -36,8 +36,6 @@
#include <spa/param/audio/format-utils.h>
#include <spa/param/format-utils.h>
#include <lib/debug.h>
static SPA_TYPE_MAP_IMPL(default_map, 4096);
static SPA_LOG_IMPL(default_log);

View file

@ -39,8 +39,6 @@
#include <spa/param/video/format-utils.h>
#include <spa/param/format-utils.h>
#include <lib/debug.h>
static SPA_TYPE_MAP_IMPL(default_map, 4096);
static SPA_LOG_IMPL(default_log);