Include path for utilities not correct in docs


The docs for DateTime state that the header is included as follows: #include <datetimeutils.h>.

However it’s only correctly resolved under the utility directory: #include <utility\datetimeutils.h>.

A small thing that added to the confusion for me is that #include <mathutils.h> is not under the utility directory. That makes sense because it’s not in the utility namespace but the name of the file kind of suggests it’s on the same level as datetimeutils.h.

What might help is renaming utility\datetimeutils.h to utility\datetime.h.


Hey Thijs,

Welcome to the forum!

I see that Doxygen (that automatically generates our documentation pages) extracts the wrong header path. I never looked at it in the past but will try and fix it in our doc generation pipeline.

Regarding your second point: I agree that datetime.h is a better name for the header. I’ll change our source to reflect this.


Hey Coen,

On Linux the build now fails with this error:

// fatal error: utility\datetimeutils.h: No such file or directory
#include <utility\datetimeutils.h>

The source doesn’t reflect a change from datetimeutils.h to datetime.h yet so I assume it’s not that.
Could it be that the include path stated in the docs was actually correct for Linux? Would be weird though.


Hey Thijs,

Maybe use forward slashes? Backward slashes are only supported on windows. We use datetimeutils.h in other projects as well. Pretty sure that’s it.

NAP never works with backward slashes btw, it’s considered bad practice and one of the worst mistakes Microsoft ever made.

This is the include used by other projects building under windows, osx and linux:

#include <utility/datetimeutils.h>


Hah my bad…

Sounds like this would be it indeed, as well as for failing the unit tests. Running a new build now.



Atm: unit tests are failing here for linux because of a sigterm on exit. Has something to do with a qt app not being cleaned up properly. I’ve only encountered this on Linux (ubuntu 18.04) but not on other platforms. @bas was going to look into this. If you see the unit test on linux fail because of that reason everything should be fine.


I moved all time related functionality to nap/datetime.h, this allowed me to add a serializable date and timestamp object to NAP. All time related enums are now also serializable.