From 32094c850a92fbdc77b05f9d78cb35f385b44c2e Mon Sep 17 00:00:00 2001 From: Gergő J. Miklós Date: Sat, 10 Oct 2020 23:26:19 +0200 Subject: versionstring --- src/main.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'src/main.c') diff --git a/src/main.c b/src/main.c index 357d929..5919421 100644 --- a/src/main.c +++ b/src/main.c @@ -20,7 +20,10 @@ #include "hmc5883.h" #define VERSION 1.27 - +#ifndef _BUILD_TIME_ + #define _BUILD_TIME_ __DATE__" "__TIME__ +#endif + // extern void lm75_print_help(void); // extern void lm75_read_all(const char *opts); // extern void lm75_read_one(const char *opts); @@ -29,6 +32,7 @@ // extern void hih61xx_read_one(const char *opts); + uint16 devicef; //# Bus-Device file uchar temp[256]; void (*print_all)(void) = NULL; @@ -57,7 +61,7 @@ void print_help(void) { " i2sensors read_all 1 lm75 0x4f \n" " i2sensors read_one 1 lm75 0x4f 00,-1.35\n" "\n" ); - printf ("Version: v%1.2f, build: [%s %s] (%s), TS: %s STDC: %d\n\n",VERSION,__DATE__,__TIME__,__VERSION__,__TIMESTAMP__,__STDC_VERSION__); + printf ("Version: v%1.2f, build: [%s] (gcc %s) \n\n",VERSION,_BUILD_TIME_,__VERSION__); } void bus_err(int ern){ -- cgit v1.2.3