main: make distcheck now works and includes all required files properly.
main: switched clock_gettime usage to gettimeofday for compatibility reasons.