From: Eric Blake Date: Wed, 31 Mar 2010 13:57:51 +0000 (-0600) Subject: sys_time: avoid compiler warnings X-Git-Tag: v0.1~4388 X-Git-Url: http://erislabs.org.uk/gitweb/?a=commitdiff_plain;h=b3119f181de14c17aaf923846713526fd82891bf;p=gnulib.git sys_time: avoid compiler warnings sys/time uses #if/#else/#endif, and is therefore not subject to the gcc optimization. The #pragma GCC system_header must occur up front. * lib/sys_time.in.h (includes): Ensure gcc pragma is unconditional, fixing regression from 2010-03-29. Reported by Simon Josefsson. Signed-off-by: Eric Blake --- diff --git a/ChangeLog b/ChangeLog index 87b208371..23db9606b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2010-03-31 Eric Blake + + sys_time: avoid compiler warnings + * lib/sys_time.in.h (includes): Ensure gcc pragma is + unconditional, fixing regression from 2010-03-29. + Reported by Simon Josefsson. + 2010-03-28 Jose E. Marchesi maint.mk: s/_header_without_use/_sc_header_without_use/ diff --git a/lib/sys_time.in.h b/lib/sys_time.in.h index 6d818d1e8..6e0c7db98 100644 --- a/lib/sys_time.in.h +++ b/lib/sys_time.in.h @@ -18,12 +18,12 @@ /* Written by Paul Eggert. */ -#if defined _GL_SYS_TIME_H - #if __GNUC__ >= 3 @PRAGMA_SYSTEM_HEADER@ #endif +#if defined _GL_SYS_TIME_H + /* Simply delegate to the system's header, without adding anything. */ # if @HAVE_SYS_TIME_H@ # @INCLUDE_NEXT@ @NEXT_SYS_TIME_H@