ucm: Set default include path

Many UCM profiles include the UCM profile components under ucm/*
subdirectories and thusly put <searchdir:ucm> at each place.  This is
rather cumbersome.

This patch makes the UCM parser to set the default include path, so
that each profile no longer needs to set searchdir.  All the
<searchdir:ucm> lines currently found in the profiles are removed
gracefully, too.

For the needed implementation, a new helper,
_snd_config_load_with_include() is introduced.  It's not exported,
only for the use inside alsa-lib.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
This commit is contained in:
Takashi Iwai 2018-11-28 16:25:41 +01:00
parent d48adc2a20
commit c9fcf98369
23 changed files with 41 additions and 25 deletions

View file

@ -354,6 +354,9 @@ int snd_config_search_alias_hooks(snd_config_t *config,
int _snd_conf_generic_id(const char *id);
int _snd_config_load_with_include(snd_config_t *config, snd_input_t *in,
const char *default_include_path);
/* convenience macros */
#define ARRAY_SIZE(x) (sizeof(x) / sizeof(x[0]))