public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug other/35199]  New: [PATCH] Check for valid value of BASEVER
@ 2008-02-14 19:00 skunk at iskunk dot org
  2008-02-14 19:01 ` [Bug other/35199] " skunk at iskunk dot org
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: skunk at iskunk dot org @ 2008-02-14 19:00 UTC (permalink / raw)
  To: gcc-bugs

I was recently bootstrapping GCC4 on Tru64. One thing that tripped me up a
couple times was an ICE resulting from an invalid version_string (""). I traced
this back to the following fragment in gcc/Makefile, where BASEVER_c is
assigned:

    BASEVER     := $(srcdir)/BASE-VER  # 4.x.y
    [...]
    BASEVER_c   := $(shell cat $(BASEVER))

For some reason, the value of BASEVER_c was empty. I had the source tree on
NFS, and figured that some transient error caused $(BASEVER) to either
disappear momentarily, or briefly appear as an empty file. (It's difficult to
say, because the rest of the build proceeded with no errors of this sort
whatsoever.)

Whatever the cause, the makefile as currently written does not check for an
empty value of BASEVER_c, and the ICE that later results from this is
magnitudes of order more difficult to diagnose for most users. I would like to
submit a patch to the makefile, then, that immediately throws an error if
BASEVER_c is empty.


-- 
           Summary: [PATCH] Check for valid value of BASEVER
           Product: gcc
           Version: 4.2.3
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: other
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: skunk at iskunk dot org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35199


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug other/35199] [PATCH] Check for valid value of BASEVER
  2008-02-14 19:00 [Bug other/35199] New: [PATCH] Check for valid value of BASEVER skunk at iskunk dot org
@ 2008-02-14 19:01 ` skunk at iskunk dot org
  2008-02-14 19:34 ` [Bug bootstrap/35199] " pinskia at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: skunk at iskunk dot org @ 2008-02-14 19:01 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from skunk at iskunk dot org  2008-02-14 19:01 -------
Created an attachment (id=15151)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=15151&action=view)
Patch against gcc/Makefile.in


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35199


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug bootstrap/35199] [PATCH] Check for valid value of BASEVER
  2008-02-14 19:00 [Bug other/35199] New: [PATCH] Check for valid value of BASEVER skunk at iskunk dot org
  2008-02-14 19:01 ` [Bug other/35199] " skunk at iskunk dot org
@ 2008-02-14 19:34 ` pinskia at gcc dot gnu dot org
  2008-02-15 18:41 ` skunk at iskunk dot org
  2008-02-16 18:43 ` skunk at iskunk dot org
  3 siblings, 0 replies; 5+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2008-02-14 19:34 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from pinskia at gcc dot gnu dot org  2008-02-14 19:33 -------
BASE-VER should always exist.

Also patches should be posted to gcc-patches@.


-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Severity|normal                      |enhancement
          Component|other                       |bootstrap


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35199


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug bootstrap/35199] [PATCH] Check for valid value of BASEVER
  2008-02-14 19:00 [Bug other/35199] New: [PATCH] Check for valid value of BASEVER skunk at iskunk dot org
  2008-02-14 19:01 ` [Bug other/35199] " skunk at iskunk dot org
  2008-02-14 19:34 ` [Bug bootstrap/35199] " pinskia at gcc dot gnu dot org
@ 2008-02-15 18:41 ` skunk at iskunk dot org
  2008-02-16 18:43 ` skunk at iskunk dot org
  3 siblings, 0 replies; 5+ messages in thread
From: skunk at iskunk dot org @ 2008-02-15 18:41 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #3 from skunk at iskunk dot org  2008-02-15 18:41 -------
Created an attachment (id=15157)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=15157&action=view)
Updated patch against gcc/Makefile.in

Mail sent to gcc-patches@. Today I'm building GCC again, and lo and behold, the
BASEVER_c check tripped:

----begin----
rm -f libdecnumber.a
ar cru libdecnumber.a decNumber.o decContext.o decUtility.o decimal32.o
decimal64.o decimal128.o
ranlib libdecnumber.a
gmake[3]: Leaving directory
`/mnt/scratch/build/35197/gcc--4.2.3.build/libdecnumber'
gmake[3]: Entering directory `/mnt/scratch/build/35197/gcc--4.2.3.build/gcc'
Makefile:739: *** /tg/freeport/src/gcc/gcc--4.2.3/gcc/BASE-VER  : missing
version file.  Stop.
gmake[3]: Leaving directory `/mnt/scratch/build/35197/gcc--4.2.3.build/gcc'
gmake[2]: *** [all-stage1-gcc] Error 2
gmake[2]: Leaving directory `/mnt/scratch/build/35197/gcc--4.2.3.build'
gmake[1]: *** [stage1-bubble] Error 2
gmake[1]: Leaving directory `/mnt/scratch/build/35197/gcc--4.2.3.build'
gmake: *** [bootstrap-lean] Error 2
----end----

Sure beats an ICE! Anyway, I don't see any error from cat(1), so it looks like
BASE-VER is being read as an empty file. (If I cat the file manually, it comes
up non-empty; the problem is very transient.)

Patch tweaked slightly to remove spurious whitespace from the error message.


-- 

skunk at iskunk dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #15151|0                           |1
        is obsolete|                            |


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35199


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug bootstrap/35199] [PATCH] Check for valid value of BASEVER
  2008-02-14 19:00 [Bug other/35199] New: [PATCH] Check for valid value of BASEVER skunk at iskunk dot org
                   ` (2 preceding siblings ...)
  2008-02-15 18:41 ` skunk at iskunk dot org
@ 2008-02-16 18:43 ` skunk at iskunk dot org
  3 siblings, 0 replies; 5+ messages in thread
From: skunk at iskunk dot org @ 2008-02-16 18:43 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #4 from skunk at iskunk dot org  2008-02-16 18:42 -------
*** Bug 35197 has been marked as a duplicate of this bug. ***


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35199


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2008-02-16 18:43 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-02-14 19:00 [Bug other/35199] New: [PATCH] Check for valid value of BASEVER skunk at iskunk dot org
2008-02-14 19:01 ` [Bug other/35199] " skunk at iskunk dot org
2008-02-14 19:34 ` [Bug bootstrap/35199] " pinskia at gcc dot gnu dot org
2008-02-15 18:41 ` skunk at iskunk dot org
2008-02-16 18:43 ` skunk at iskunk dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).