From: Jaroslav Kysela Date: Fri, 20 Dec 2019 20:28:30 +0000 (+0100) Subject: topology: add snd_tplg_version() function X-Git-Tag: v1.2.2~34 X-Git-Url: https://git.alsa-project.org/?a=commitdiff_plain;h=0793ef064a97afd0b1335af0d187ede227b90582;p=alsa-lib.git topology: add snd_tplg_version() function Signed-off-by: Jaroslav Kysela --- diff --git a/include/topology.h b/include/topology.h index 63c13a98..37bced1a 100644 --- a/include/topology.h +++ b/include/topology.h @@ -775,6 +775,12 @@ enum snd_tplg_type { #define SND_TPLG_CREATE_VERBOSE (1<<0) /*!< Verbose output */ #define SND_TPLG_CREATE_DAPM_NOSORT (1<<1) /*!< Do not sort DAPM objects by index */ +/** + * \brief Return the version of the topology library. + * \return A static string with the version number. + */ +const char *snd_tplg_version(void); + /** * \brief Create a new topology parser instance. * \return New topology parser instance diff --git a/src/topology/parser.c b/src/topology/parser.c index 8f810f75..1eaa24bd 100644 --- a/src/topology/parser.c +++ b/src/topology/parser.c @@ -503,3 +503,8 @@ void snd_tplg_free(snd_tplg_t *tplg) free(tplg); } + +const char *snd_tplg_version(void) +{ + return SND_LIB_VERSION_STR; +}