diff options
-rw-r--r-- | base/remote_gdb.cc | 1 | ||||
-rw-r--r-- | base/statistics.hh | 7 | ||||
-rw-r--r-- | sim/sim_time.cc | 6 | ||||
-rw-r--r-- | sim/sim_time.hh | 2 |
4 files changed, 10 insertions, 6 deletions
diff --git a/base/remote_gdb.cc b/base/remote_gdb.cc index 0289f29db..a7893cdf7 100644 --- a/base/remote_gdb.cc +++ b/base/remote_gdb.cc @@ -91,6 +91,7 @@ #include <unistd.h> +#include <cstdio> #include <string> #include "cpu/exec_context.hh" diff --git a/base/statistics.hh b/base/statistics.hh index f333b9b08..7ccb20498 100644 --- a/base/statistics.hh +++ b/base/statistics.hh @@ -55,9 +55,10 @@ #include <assert.h> -#include "host.hh" -#include "refcnt.hh" -#include "str.hh" +#include "base/refcnt.hh" +#include "base/str.hh" + +#include "sim/host.hh" #ifndef NAN float __nan(); diff --git a/sim/sim_time.cc b/sim/sim_time.cc index 3d91eba83..70483d9a2 100644 --- a/sim/sim_time.cc +++ b/sim/sim_time.cc @@ -132,21 +132,21 @@ namespace Time ostream & operator<<(ostream &out, const Start &start) { - out << ::ctime(&start.get().tv_sec); + out << ::ctime((const time_t *)&start.get().tv_sec); return out; } ostream & operator<<(ostream &out, const Now &now) { - out << ::ctime(&now.get().tv_sec); + out << ::ctime((const time_t *)&now.get().tv_sec); return out; } ostream & operator<<(ostream &out, const Elapsed &elapsed) { - out << ::ctime(&elapsed.get().tv_sec); + out << ::ctime((const time_t *)&elapsed.get().tv_sec); return out; } } diff --git a/sim/sim_time.hh b/sim/sim_time.hh index dbba42aa7..af69c3321 100644 --- a/sim/sim_time.hh +++ b/sim/sim_time.hh @@ -29,6 +29,8 @@ #ifndef __SIM_TIME_HH__ #define __SIM_TIME_HH__ +#include <sys/time.h> + #include <iosfwd> namespace Time { |