X-Authentication-Warning: delorie.com: mail set sender to djgpp-workers-bounces using -f Date: Thu, 30 Dec 2004 04:02:17 -0700 From: Brian Inglis Subject: Re: tests/libc/ansi/time/makefile problems In-reply-to: <200410311110.i9VBALbc028787@speedy.ludd.ltu.se> To: djgpp-workers AT delorie DOT com Message-id: <3eh7t019mbd6q4j21t5pvuamikmq9clo3g@4ax.com> Organization: Systematic Software MIME-version: 1.0 X-Mailer: Forte Agent 1.93/32.576 English (American) Content-type: text/plain; charset=us-ascii References: <200410311110 DOT i9VBALbc028787 AT speedy DOT ludd DOT ltu DOT se> Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from quoted-printable to 8bit by delorie.com id iBUB2LZx025414 Reply-To: djgpp-workers AT delorie DOT com Errors-To: nobody AT delorie DOT com X-Mailing-List: djgpp-workers AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk On Sun, 31 Oct 2004 12:10:21 +0100 (CET), ams AT ludd DOT ltu DOT se wrote: >According to Brian Inglis: >> >> >Can anyone run make successfully in tests/libc/ansi/time/? >> >Without that line make says: >> >gcc @../../../gcc.opt -I. -I- -I../../../../include -c xstrftm.c >> >cc1.exe: warnings being treated as errors >> >xstrftm.c: In function `main': >> >xstrftm.c:17: warning: `%x' yields only last 2 digits of year in some locales >> >I'm using gcc 2.953. >> >> Not seeing that with 3.4.1. >> Check gcc*.opt to see if -Wformat and -pedantic or -Wformat-y2k is >> set, and change to or add -Wno-format-y2k. > >No -Wformat, -pedantic or -Wformat-y2k present. Adding -Wno-format-y2k >makes no difference (still warns about %x). > >Here's tests/gcc.opt (with -Wno-format-y2k added by me): >-MD >-O3 >-g >-Wall >-Wbad-function-cast >-Wcast-qual >-Werror >-Wpointer-arith >-Wshadow >-Wstrict-prototypes >-Wwrite-strings >-Wno-format-y2k >-nostdinc > >in case you see something obvious. Should work or you should get a compiler option warning. The default was changed for gcc 3.4 from: option -Wall implies -Wformat including -Wformat-y2k, and -Wno-format-y2k is required to not invoke Y2K format checks; to: option -Wall implies -Wformat excluding -Wformat-y2k, and -Wformat-y2k or -Wformat=2 are required to invoke Y2K format checks. This was gcc 3.4 PR c/3190 aka c/8714 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=3190 to c_format.c rev 1.50 noted in ChangeLog rev 2.1706 documented in doc/invoke.texi rev 1.358