Mercurial > hg > octave-terminal
changeset 10302:5669a0b893db
data.cc: include <sys/times.h> and ensure that HZ is defined
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Wed, 10 Feb 2010 15:42:59 -0500 |
parents | 9e0ec19df4bc |
children | e4899d6320b6 |
files | src/ChangeLog src/data.cc |
diffstat | 2 files changed, 13 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2010-02-10 John W. Eaton <jwe@octave.org> + + * data.cc: Include <sys/times.h>. Define HZ if it is not defined. + 2010-02-10 John W. Eaton <jwe@octave.org> * graphics.cc (base_properties::set_children): Ensure that new
--- a/src/data.cc +++ b/src/data.cc @@ -28,6 +28,7 @@ #endif #include <sys/types.h> +#include <sys/times.h> #ifdef HAVE_SYS_RESOURCE_H #include <sys/resource.h> @@ -64,6 +65,14 @@ #include "pager.h" #include "xnorm.h" +#if ! defined (HZ) +#if defined (CLK_TCK) +#define HZ CLK_TCK +#else +#define HZ 60 +#endif +#endif + #if ! defined (HAVE_HYPOTF) && defined (HAVE__HYPOTF) #define hypotf _hypotf #define HAVE_HYPOTF 1