diff -uprN bird-1.0.11-/sysdep/unix/io.c bird-1.0.11/sysdep/unix/io.c --- bird-1.0.11-/sysdep/unix/io.c 2008-08-20 17:04:36.000000000 +0200 +++ bird-1.0.11/sysdep/unix/io.c 2008-08-20 17:49:28.000000000 +0200 @@ -1093,6 +1093,19 @@ sk_dump_all(void) volatile int async_config_flag; /* Asynchronous reconfiguration/dump scheduled */ volatile int async_dump_flag; +static time_t +monotonic_time(void) +{ + struct timespec ts; + int rv; + + rv = clock_gettime(CLOCK_MONOTONIC, &ts); + if (rv != 0) + die("clock_gettime: %m"); + + return ts.tv_sec; +} + void io_init(void) { @@ -1101,7 +1114,7 @@ io_init(void) init_list(&sock_list); init_list(&global_event_list); krt_io_init(); - now = time(NULL); + now = monotonic_time(); srandom((int) now); } @@ -1119,7 +1132,7 @@ io_loop(void) for(;;) { events = ev_run_list(&global_event_list); - now = time(NULL); + now = monotonic_time(); tout = tm_first_shot(); if (tout <= now) { diff -uprN bird-1.0.11-/tools/Rules.in bird-1.0.11/tools/Rules.in --- bird-1.0.11-/tools/Rules.in 2004-08-19 11:15:36.000000000 +0200 +++ bird-1.0.11/tools/Rules.in 2008-08-20 17:51:11.000000000 +0200 @@ -22,7 +22,7 @@ clean-dirs:=$(all-dirs) proto sysdep CPPFLAGS=-I$(root-rel) -I$(srcdir) @CPPFLAGS@ CFLAGS=$(CPPFLAGS) @CFLAGS@ LDFLAGS=@LDFLAGS@ -LIBS=@LIBS@ +LIBS=-lrt @LIBS@ CLIENT_LIBS=@CLIENT_LIBS@ CC=@CC@ M4=@M4@