diff --git a/src/kernel/libroot/posix/time/Jamfile b/src/kernel/libroot/posix/time/Jamfile index 9d6b4b8d01..1bb0ffeca5 100644 --- a/src/kernel/libroot/posix/time/Jamfile +++ b/src/kernel/libroot/posix/time/Jamfile @@ -3,6 +3,7 @@ SubDir OBOS_TOP src kernel libroot posix time ; KernelMergeObject posix_time.o : <$(SOURCE_GRIST)>asctime.c <$(SOURCE_GRIST)>ctime.c + <$(SOURCE_GRIST)>difftime.c <$(SOURCE_GRIST)>localtime.c <$(SOURCE_GRIST)>mktime.c <$(SOURCE_GRIST)>time.c diff --git a/src/kernel/libroot/posix/time/difftime.c b/src/kernel/libroot/posix/time/difftime.c new file mode 100644 index 0000000000..553d303160 --- /dev/null +++ b/src/kernel/libroot/posix/time/difftime.c @@ -0,0 +1,16 @@ +/* +** Copyright 2004, Axel Dörfler, axeld@pinc-software.de. All rights reserved. +** Distributed under the terms of the Haiku License. +*/ + + +#include +#include + + +double +difftime(time_t time1, time_t time2) +{ + return 1. * ((bigtime_t)time1 - (bigtime_t)time2); +} +