diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/DabMod.cpp | 31 | ||||
-rw-r--r-- | src/Utils.cpp | 46 | ||||
-rw-r--r-- | src/Utils.h | 2 |
3 files changed, 45 insertions, 34 deletions
diff --git a/src/DabMod.cpp b/src/DabMod.cpp index a298fbe..0378c97 100644 --- a/src/DabMod.cpp +++ b/src/DabMod.cpp @@ -213,36 +213,7 @@ int launch_modulator(int argc, char* argv[]) mod_settings_t mod_settings; parse_args(argc, argv, mod_settings); - std::cerr << "ODR-DabMod version " << -#if defined(GITVERSION) - GITVERSION -#else - VERSION -#endif - << std::endl; - - std::cerr << "Compiled with features: " << -#if defined(HAVE_ZEROMQ) - "zeromq " << -#endif -#if defined(HAVE_OUTPUT_UHD) - "output_uhd " << -#endif -#if defined(HAVE_SOAPYSDR) - "output_soapysdr " << -#endif -#if defined(__FAST_MATH__) - "fast-math" << -#endif - "\n"; - - etiLog.level(info) << "Starting up version " << -#if defined(GITVERSION) - GITVERSION; -#else - VERSION; -#endif - + printStartupInfo(); // When using the FIRFilter, increase the modulator offset pipelining delay // by the correct amount diff --git a/src/Utils.cpp b/src/Utils.cpp index a2ac9f4..5bd93d9 100644 --- a/src/Utils.cpp +++ b/src/Utils.cpp @@ -89,13 +89,19 @@ void printVersion(void) { FILE *out = stderr; - fprintf(out, "Welcome to %s %s, compiled at %s, %s\n\n", - PACKAGE, VERSION, __DATE__, __TIME__); + fprintf(out, "%s %s, compiled at %s, %s\n\n", + PACKAGE, +#if defined(GITVERSION) + GITVERSION +#else + VERSION +#endif + ,__DATE__, __TIME__); fprintf(out, " ODR-DabMod is copyright (C) Her Majesty the Queen in Right of Canada,\n" - " 2009, 2010, 2011, 2012 Communications Research Centre (CRC),\n" + " 2005 -- 2012 Communications Research Centre (CRC),\n" " and\n" - " Copyright (C) 2014, 2015 Matthias P. Braendli, matthias.braendli@mpb.li\n" + " Copyright (C) 2017 Matthias P. Braendli, matthias.braendli@mpb.li\n" "\n" " http://opendigitalradio.org\n" "\n" @@ -113,7 +119,39 @@ void printVersion(void) " with ODR-DabMod. If not, see <http://www.gnu.org/licenses/>.\n" "\n" ); +} +void printStartupInfo() +{ + std::cerr << "ODR-DabMod version " << +#if defined(GITVERSION) + GITVERSION +#else + VERSION +#endif + << std::endl; + + std::cerr << "Compiled with features: " << +#if defined(HAVE_ZEROMQ) + "zeromq " << +#endif +#if defined(HAVE_OUTPUT_UHD) + "output_uhd " << +#endif +#if defined(HAVE_SOAPYSDR) + "output_soapysdr " << +#endif +#if defined(__FAST_MATH__) + "fast-math" << +#endif + "\n"; + + etiLog.level(info) << "Starting up version " << +#if defined(GITVERSION) + GITVERSION; +#else + VERSION; +#endif } int set_realtime_prio(int prio) diff --git a/src/Utils.h b/src/Utils.h index 4631292..8da3a1b 100644 --- a/src/Utils.h +++ b/src/Utils.h @@ -41,6 +41,8 @@ void printUsage(const char* progName); void printVersion(void); +void printStartupInfo(void); + inline long timespecdiff_us(struct timespec& oldTime, struct timespec& time) { long tv_sec; |