diff --git a/firmware/common/timefuncs.c b/firmware/common/timefuncs.c index d073ec819c..9865b0fe17 100644 --- a/firmware/common/timefuncs.c +++ b/firmware/common/timefuncs.c @@ -131,6 +131,7 @@ int set_time(const struct tm *tm) #endif } +#if CONFIG_RTC /* mktime() code taken from lynx-2.8.5 source, written by Philippe De Muyter */ time_t mktime(struct tm *t) @@ -165,3 +166,4 @@ time_t mktime(struct tm *t) result += t->tm_sec; return(result); } +#endif diff --git a/firmware/include/timefuncs.h b/firmware/include/timefuncs.h index d2f42eb9ff..e266ff9acb 100644 --- a/firmware/include/timefuncs.h +++ b/firmware/include/timefuncs.h @@ -27,6 +27,8 @@ struct tm *get_time(void); int set_time(const struct tm *tm); bool valid_time(const struct tm *tm); +#if CONFIG_RTC time_t mktime(struct tm *t); +#endif #endif /* _TIMEFUNCS_H_ */