diff --git a/srslte/include/srslte/version.h.in b/srslte/include/srslte/version.h.in index a5962870c..770569bcf 100644 --- a/srslte/include/srslte/version.h.in +++ b/srslte/include/srslte/version.h.in @@ -9,6 +9,7 @@ * This file is part of the srsLTE library. * * srsLTE is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License as * published by the Free Software Foundation, either version 3 of * the License, or (at your option) any later version. @@ -33,7 +34,8 @@ #define SRSLTE_VERSION_PATCH @SRSLTE_VERSION_PATCH@ #define SRSLTE_VERSION @SRSLTE_VERSION@ -SRSLTE_API char* srslte_get_version(); +#include "srslte/config.h" + SRSLTE_API int srslte_get_version_major(); SRSLTE_API int srslte_get_version_minor(); SRSLTE_API int srslte_get_version_patch(); diff --git a/srslte/lib/version/src/version.c b/srslte/lib/version/src/version.c index dcb8e3f41..138d1470a 100644 --- a/srslte/lib/version/src/version.c +++ b/srslte/lib/version/src/version.c @@ -24,20 +24,7 @@ * */ -#define STRINGIFY(x) #x -#define TOSTRING(x) STRINGIFY(x) - #include "srslte/version.h" -#include - -char* srslte_get_version_string() { - char buf[32]; - sprintf(buf, "%s.%s.%s", - TOSTRING(SRSLTE_VERSION_MAJOR), - TOSTRING(SRSLTE_VERSION_MINOR), - TOSTRING(SRSLTE_VERSION_PATCH)); - return buf; -} int srslte_get_version_major() { return SRSLTE_VERSION_MAJOR;