* runtime/error.c: Include sys/time.h before sys/resource.h.
authorFrançois-Xavier Coudert <fxcoudert@gcc.gnu.org>
Sun, 21 Jan 2007 21:04:53 +0000 (21:04 +0000)
committerFrançois-Xavier Coudert <fxcoudert@gcc.gnu.org>
Sun, 21 Jan 2007 21:04:53 +0000 (21:04 +0000)
From-SVN: r121036

libgfortran/ChangeLog
libgfortran/runtime/error.c

index f12f83ee441d4a61a221e64b05b00b51899ea303..d432812fe590741f10d2c97a2f01269414dd4c8e 100644 (file)
@@ -1,10 +1,14 @@
+2007-01-21  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
+
+       * runtime/error.c: Include sys/time.h before sys/resource.h.
+
 2007-01-21  Thomas Koenig  <Thomas.Koenig@online.de>
 
        PR libfortran/30525
        * intrinsics/string_intrinsics.c(compare_string):  Make
        sure that comparisons are done unsigned.
 
-2006-12-09  Tobias Burnus  <burnus@net-b.de>
+2007-01-21  Tobias Burnus  <burnus@net-b.de>
 
        PR libfortran/30015
        * intrinsics/date_and_time.c (date_and_time): Fix case where time
index e6713d2cc4d9ae773112e13bab7816a54afa688d..afd6a2172698e103cd0d232fefecb34b6fb2786d 100644 (file)
@@ -48,14 +48,16 @@ Boston, MA 02110-1301, USA.  */
 #include <stdlib.h>
 #endif
 
-#ifdef HAVE_SYS_RESOURCE_H
-#include <sys/resource.h>
-#endif
-
 #ifdef HAVE_SYS_TIME_H
 #include <sys/time.h>
 #endif
 
+/* <sys/time.h> has to be included before <sys/resource.h> to work
+   around PR 30518; otherwise, MacOS 10.3.9 headers are just broken.  */
+#ifdef HAVE_SYS_RESOURCE_H
+#include <sys/resource.h>
+#endif
+
 #include "libgfortran.h"
 
 #ifdef __MINGW32__