bugmake - Bugs: bug #10735, fails to build on irix4 with sgi...

 
 

bug #10735: fails to build on irix4 with sgi mips compiler

Submitted by:  Riccardo Mottola <rmottola>
Submitted on:  Tue 19 Oct 2004 05:26:44 PM UTC  
 
Severity: 3 - NormalItem Group: Build/Install
Status: Works for mePrivacy: Public
Assigned to: NoneOpen/Closed: Closed
Component Version: 3.80Operating System: POSIX-Based
Fixed Release: NoneTriage Status: None

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Sat 08 Jan 2005 11:51:55 AM UTC, comment #4:

Unfortunately I have no "new" details. The idea that this is a compiler bug is probably correct. Using your workaround of a temporary variable I was able to get to run (and compile) other programs.

Unfortunately in this case, the program segfaults. I think these are tw separate bugs. The workaround is "ugly" and I understand your reluctance to make int mainstream.

The segfault is probably unrelated.

I am doing this effort on such an old system because with many programs gnu-make is almost essential to compile otherwise even trivial programs. Only few people take care in having portable makefiles.

Riccardo Mottola <rmottola>
Fri 07 Jan 2005 11:11:38 PM UTC, comment #3:

I'm not sure what to do about this: I try very hard to keep GNU make as portable as possible, but I can't rewrite code to work around buggy compilers.

If you find any more details about this please post a followup to this bug.

Paul D. Smith <psmith>
Project Administrator
Tue 19 Oct 2004 09:30:21 PM UTC, comment #2:

Indeed, it seems to be a compiler bug. I sinerted temporary variables and made the switches compile. the bad news, it segmentation faults.

I tried to get a trace with dbx (I'm not used to it)
(dbx) run
Process 5642 (make) started
Process 5642 (make) Segmentation fault [define_makeflags:2465 +0x8,0x4149f0]
2465 || (int ) cs->value_ptr != (int ) cs->default_value))

t

> 0 define_makeflags(all = 0, makefile = 0) ["/usr/people/multix/make-3.80/main.c":2465, 0x4149f0]

1 .main.main(argc = 0, argv = (nil), envp = (nil)) ["/usr/people/multix/make-3.80/main.c":1435, 0x4128fc]

of course the lines will be slightly different since I inserted some statements.

Riccardo Mottola <rmottola>
Tue 19 Oct 2004 05:49:15 PM UTC, comment #1:

Hm. All I can think of is that it's upset because the type of the "type" field is an enumeration. It's definitely true that this is a const value, but the argument to switch is not an assignment or increment or decrement, of course.

I'm pretty sure this is a bug in the compiler; I can't see anything that violates the standard in this code.

If you change the code to something like:

int t;
...
t = switches[i].type;
switch (t)
...

(etc.) does that work?

Paul D. Smith <psmith>
Project Administrator
Tue 19 Oct 2004 05:26:44 PM UTC, original submission:

The compiler moans about:
accom: Error: main.c, line 2012: modifiable lvalue (3.2.2.1) required for assignment operators (3.3.16) and increment and decrement(ANSI 3.3.2.1,3.3.2.4)
switch (switches[i].type)
------------------------------^
accom: Error: main.c, line 2191: modifiable lvalue (3.2.2.1) required for assignment operators (3.3.16) and increment and decrement(ANSI 3.3.2.1,3.3.2.4)
switch (cs->type)
-----------------------^
accom: Error: main.c, line 2447: modifiable lvalue (3.2.2.1) required for assignment operators (3.3.16) and increment and decrement(ANSI 3.3.2.1,3.3.2.4)
switch (cs->type)

I have never seen such an error... It happens with the oldest gnumake I was able to find too (3.75). The mips compiler is known to be very pricky (and this one is an old version too).

Riccardo Mottola <rmottola>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

CC list is empty

 

Do you think this task is very important?
If so, you can click here to add your encouragement to it.
This task has 0 encouragements so far.

Only logged-in users can vote.

 

Please enter the title of George Orwell's famous dystopian book (it's a date):

 

 

Follow 2 latest changes.

Date Changed By Updated Field Previous Value => Replaced By
Fri 07 Jan 2005 11:11:38 PM UTCpsmithStatusNone=>Works for me
  Open/ClosedOpen=>Closed

Back to the top


Powered by Savane 3.1-cleanup1