Date: Thu, 08 Jan 2004 17:53:16 +0000 From: Colin Percival <cperciva@daemonology.net> To: FreeBSD-gnats-submit@FreeBSD.org Subject: bin/61087: wacky string constant merging in isdnd Message-ID: <20040108175316.23832.qmail@fafnir.daemonology.net> Resent-Message-ID: <200401081800.i08I0XuZ063495@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 61087 >Category: bin >Synopsis: wacky string constant merging in isdnd >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Thu Jan 08 10:00:33 PST 2004 >Closed-Date: >Last-Modified: >Originator: Colin Percival >Release: FreeBSD 5.2-RC i386 >Organization: >Environment: System: FreeBSD fafnir.daemonology.net 5.2-RC FreeBSD 5.2-RC #3: Sun Jan 4 16:13:57 GMT 2004 cperciva@fafnir.daemonology.net:/usr/obj/usr/src/sys/GENERIC i386 >Description: isdnd contains a build timestamp. It also contains the strings "1", "2", "3", ... , "32". If isdnd is built at 1-32 seconds past a minute, gcc will, very helpfully, merge the two constant strings. This is 1. A problem for FreeBSD Update, since this causes cascading differences, and 2. Rather astonishing behaviour. >How-To-Repeat: >Fix: Tell gcc not to merge the string constants in this particular case. --- isdnd.diff begins here --- Index: Makefile =================================================================== RCS file: /usr/cvsroot/src/usr.sbin/i4b/isdnd/Makefile,v retrieving revision 1.12 diff -u -r1.12 Makefile --- usr.sbin/i4b/isdnd/Makefile 4 Apr 2003 17:49:14 -0000 1.12 +++ usr.sbin/i4b/isdnd/Makefile 8 Jan 2004 17:23:04 -0000 @@ -10,6 +10,10 @@ # compile debug support COPTS+= -DDEBUG +# avoid wacky merging of string constants from +# source code with compile-time timestamp +COPTS+= -fno-merge-constants + # enable rtprio usage COPTS+= -DUSE_RTPRIO --- isdnd.diff ends here --- >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20040108175316.23832.qmail>