public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
* Re: other/5620: [3.1] GCC -save-temps foo.c fails to build foo.o
@ 2003-05-13  1:16 Dara Hazeghi
  0 siblings, 0 replies; 7+ messages in thread
From: Dara Hazeghi @ 2003-05-13  1:16 UTC (permalink / raw)
  To: nobody; +Cc: gcc-prs

The following reply was made to PR other/5620; it has been noted by GNATS.

From: Dara Hazeghi <dhazeghi@yahoo.com>
To: danny_r_smith_2001@yahoo.co.nz, gcc-gnats@gcc.gnu.org
Cc:  
Subject: Re: other/5620: [3.1] GCC -save-temps foo.c fails to build foo.o
Date: Mon, 12 May 2003 18:14:45 -0700

 http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit- 
 trail&database=gcc&pr=5620
 
 Hello,
 
 you included a patch in late December of 2002. Did that patch ever get  
 applied? Is it sufficiently current to send to gcc-patches, and see if  
 someone will review it? Thanks,
 
 Dara
 


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

* Re: other/5620: [3.1] GCC -save-temps foo.c fails to build foo.o
@ 2002-12-10 17:16 Danny Smith
  0 siblings, 0 replies; 7+ messages in thread
From: Danny Smith @ 2002-12-10 17:16 UTC (permalink / raw)
  To: nobody; +Cc: gcc-prs

The following reply was made to PR other/5620; it has been noted by GNATS.

From: Danny Smith <dannysmith@clear.net.nz>
To: bangerth@dealii.org, danny_r_smith_2001@yahoo.co.nz, gcc-bugs@gcc.gnu.org,
 gcc-prs@gcc.gnu.org, nobody@gcc.gnu.org, gcc-gnats@gcc.gnu.org
Cc:  
Subject: Re: other/5620: [3.1] GCC -save-temps foo.c fails to build foo.o
Date: Wed, 11 Dec 2002 01:04:56 +0000

 ----- Original Message -----
 From: <bangerth@dealii.org>
 To: <danny_r_smith_2001@yahoo.co.nz>; <gcc-bugs@gcc.gnu.org>;
 <gcc-prs@gcc.gnu.org>; <nobody@gcc.gnu.org>
 Sent: Wednesday, 11 December 2002 01:01
 Subject: Re: other/5620: [3.1] GCC -save-temps foo.c fails to build
 foo.o
 
 
 > Synopsis: [3.1] GCC -save-temps foo.c fails to build foo.o
 >
 > State-Changed-From-To: open->analyzed
 > State-Changed-By: bangerth
 > State-Changed-When: Tue Dec 10 17:01:11 2002
 > State-Changed-Why:
 >     The patch you mention has not been reverted, as far as I can
 >     tell. Can you say whether the problem persists with
 >     present mainline?
 
 Yes.
 The bug is host (mingw) specific and is due to the msvcrt implementation
 of stat. I have a patch that fixes  for host, but have been putting off
 submitting because it is so ugly
 
 I'll work on it.
 
 Danny
 >
 >     Thanks
 >       Wolfgang
 >
 >
 http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=g
 cc&pr=5620
 


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

* Re: other/5620: [3.1] GCC -save-temps foo.c fails to build foo.o
@ 2002-12-10 17:16 Wolfgang Bangerth
  0 siblings, 0 replies; 7+ messages in thread
From: Wolfgang Bangerth @ 2002-12-10 17:16 UTC (permalink / raw)
  To: nobody; +Cc: gcc-prs

The following reply was made to PR other/5620; it has been noted by GNATS.

From: Wolfgang Bangerth <bangerth@ticam.utexas.edu>
To: Danny Smith <dannysmith@users.sourceforge.net>
Cc: bangerth@dealii.org, <danny_r_smith_2001@yahoo.co.nz>,
   <gcc-bugs@gcc.gnu.org>, <gcc-prs@gcc.gnu.org>, <nobody@gcc.gnu.org>,
   <gcc-gnats@gcc.gnu.org>
Subject: Re: other/5620: [3.1] GCC -save-temps foo.c fails to build foo.o
Date: Tue, 10 Dec 2002 19:08:55 -0600 (CST)

 > >     tell. Can you say whether the problem persists with
 > >     present mainline?
 > 
 > Yes.
 
 OK, I'll reset the state of the report.
 
 > The bug is host (mingw) specific and is due to the msvcrt implementation
 > of stat. I have a patch that fixes  for host, but have been putting off
 > submitting because it is so ugly
 > 
 > I'll work on it.
 
 I think that would be great!
 W.
 
 -------------------------------------------------------------------------
 Wolfgang Bangerth              email:           bangerth@ticam.utexas.edu
                                www: http://www.ticam.utexas.edu/~bangerth
 
 


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

* Re: other/5620: [3.1] GCC -save-temps foo.c fails to build foo.o
@ 2002-12-10 17:01 bangerth
  0 siblings, 0 replies; 7+ messages in thread
From: bangerth @ 2002-12-10 17:01 UTC (permalink / raw)
  To: danny_r_smith_2001, gcc-bugs, gcc-prs, nobody

Synopsis: [3.1] GCC -save-temps foo.c fails to build foo.o

State-Changed-From-To: open->analyzed
State-Changed-By: bangerth
State-Changed-When: Tue Dec 10 17:01:11 2002
State-Changed-Why:
    The patch you mention has not been reverted, as far as I can
    tell. Can you say whether the problem persists with 
    present mainline?
    
    Thanks
      Wolfgang

http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=5620


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

* Re: other/5620: [3.1] GCC -save-temps foo.c fails to build foo.o
@ 2002-06-09 12:56 hp
  0 siblings, 0 replies; 7+ messages in thread
From: hp @ 2002-06-09 12:56 UTC (permalink / raw)
  To: danny_r_smith_2001, gcc-bugs, gcc-prs, nobody

Synopsis: [3.1] GCC -save-temps foo.c fails to build foo.o

State-Changed-From-To: closed->open
State-Changed-By: hp
State-Changed-When: Sun Jun  9 12:56:23 2002
State-Changed-Why:
    Mistakenly closed; the problem is reproducible on main trunk and
    3.1 branch (with a corrected test-case as noted).

http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=5620


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

* Re: other/5620: [3.1] GCC -save-temps foo.c fails to build foo.o
@ 2002-05-11 10:17 rodrigc
  0 siblings, 0 replies; 7+ messages in thread
From: rodrigc @ 2002-05-11 10:17 UTC (permalink / raw)
  To: danny_r_smith_2001, gcc-bugs, gcc-prs, nobody

Synopsis: [3.1] GCC -save-temps foo.c fails to build foo.o

State-Changed-From-To: open->closed
State-Changed-By: rodrigc
State-Changed-When: Sat May 11 10:17:44 2002
State-Changed-Why:
    Cannot reproduce problem with latest snapshot.
    Your testcase is wrong.  You provided:
    
    /* foo.c * / 
    int main()(return 0;}
    
    It should be:
    /* foo.c * / 
    int main(){return 0;}

http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=5620


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

* other/5620: [3.1] GCC -save-temps foo.c fails to build foo.o
@ 2002-02-06 18:06 danny_r_smith_2001
  0 siblings, 0 replies; 7+ messages in thread
From: danny_r_smith_2001 @ 2002-02-06 18:06 UTC (permalink / raw)
  To: gcc-gnats


>Number:         5620
>Category:       other
>Synopsis:       [3.1] GCC -save-temps foo.c fails to build foo.o
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Feb 06 18:06:00 PST 2002
>Closed-Date:
>Last-Modified:
>Originator:     Danny Smith
>Release:        GCC version, gcc version 3.1 20020202 (experimental)
>Organization:
>Environment:
NT4sp6, i386-pc-mingw32
>Description:
Compile foo.c (below) with "gcc -o foo -save-temps foo.c"  GCC builds foo.i and foo.s but not  object file foo.o. Hence, the exe fails to build.
Here is the verbose output.  Note that although gcc outputs foo.s it sends the tempname  "D:\TEMP/ccSaaaaa.s" to as.exe:

Reading specs from D:/MINGW/BIN/../lib/gcc-lib/mingw32/3.1/specs
Configured with: ../gcc/configure --with-gcc-version-trigger=/develop/gcc/gcc/gcc/version.c --with-gcc --with-gnu-ld --with-gnu-as --host=mingw32 --target=mingw32 --prefix=/mingw --enable-sjlj-exceptions --enable-threads --disable-nls --enable-languages=f77,c++,objc,ada --disable-win32-registry --enable-shared --enable-objc-gc : (reconfigured) ../gcc/configure --with-gcc-version-trigger=/develop/gcc/gcc/gcc/version.c --with-gcc --with-gnu-ld --with-gnu-as --host=mingw32 --target=mingw32 --prefix=/mingw --enable-sjlj-exceptions --enable-threads --disable-nls --enable-languages=f77,c++,objc,ada --disable-win32-registry --enable-shared --enable-objc-gc
Thread model: win32
gcc version 3.1 20020202 (experimental)
 D:/MINGW/BIN/../lib/gcc-lib/mingw32/3.1/cpp0.exe -lang-c -v -iprefix D:\MINGW\BIN/../lib/gcc-lib/mingw32/3.1/ -D__GNUC__=3 -D__GNUC_MINOR__=1 -D__GNUC_PATCHLEVEL__=0 -D_WIN32 -D__WIN32 -D__WIN32__ -DWINNT -DWIN32 -D__MINGW32__ -D__MSVCRT__ -D_X86_=1 -D_WIN32 -D__WIN32 -D__WIN32__ -D__WINNT__ -D__WIN32__ -D__MINGW32__ -D__MSVCRT__ -D_X86_=1 -D__WINNT -D__WIN32 -Asystem=winnt -D__NO_INLINE__ -D__STDC_HOSTED__=1 -remap -Acpu=i386 -Amachine=i386 -Di386 -D__i386 -D__i386__ -D__tune_i586__ -D__tune_pentium__ -D__stdcall=__attribute__((__stdcall__)) -D__cdecl=__attribute__((__cdecl__)) -D__fastcall=__attribute__((__fastcall__)) -D_stdcall=__attribute__((__stdcall__)) -D_cdecl=__attribute__((__cdecl__)) -D_fastcall=__attribute__((__fastcall__)) -D__declspec(x)=__attribute__((x)) foo.c foo.i
GNU CPP version 3.1 20020202 (experimental) (cpplib) (80386, BSD syntax)
ignoring nonexistent directory "/usr/local/mingw32/include"
#include "..." search starts here:
#include <...> search starts here:
 D:/MINGW/include
 D:/MINGW/lib/gcc-lib/mingw32/3.1/include
 D:/MINGW/mingw32/include
 /mingw/include
 /mingw/include
 /mingw/lib/gcc-lib/mingw32/3.1/include
 /mingw/mingw32/include
End of search list.
 D:/MINGW/BIN/../lib/gcc-lib/mingw32/3.1/cc1.exe -fpreprocessed foo.i -quiet -dumpbase foo.c -version -o foo.s
GNU CPP version 3.1 20020202 (experimental) (cpplib) (80386, BSD syntax)
GNU C version 3.1 20020202 (experimental) (mingw32)
	compiled by GNU C version 3.1 20020117 (experimental).
 D:/MINGW/BIN/../lib/gcc-lib/mingw32/3.1/../../../../mingw32/bin/as.exe -o foo.o D:\TEMP/ccSaaaaa.s
 D:/MINGW/BIN/../lib/gcc-lib/mingw32/3.1/../../../../mingw32/bin/ld.exe -Bdynamic -o foo.exe D:/MINGW/BIN/../lib/gcc-lib/mingw32/3.1/../../../../mingw32/lib/crt2.o -LD:/MINGW/BIN/../lib/gcc-lib/mingw32/3.1 -LD:/MINGW/BIN/../lib/gcc-lib -L/mingw/lib/gcc-lib/mingw32/3.1 -LD:/MINGW/BIN/../lib/gcc-lib/mingw32/3.1/../../../../mingw32/lib -L/mingw/lib/gcc-lib/mingw32/3.1/../../../../mingw32/lib -LD:/MINGW/BIN/../lib/gcc-lib/mingw32/3.1/../../.. -L/mingw/lib/gcc-lib/mingw32/3.1/../../.. foo.o -lmingw32 -lgcc -lmoldname -lisocext -lmsvcrt -luser32 -lkernel32 -ladvapi32 -lshell32 -lmingw32 -lgcc -lmoldname -lisocext -lmsvcrt
D:/MINGW/BIN/../lib/gcc-lib/mingw32/3.1/../../../../mingw32/lib/libmingw32.a(main.o)(.text+0x96):main.c: undefined reference to `WinMain@16'


If I repeat the same command (after foo.i and foo.s are built), it outputs a temp .s file and sends it to as.exe to make foo.o and all is fine,
<snip>
 D:/MINGW/BIN/../lib/gcc-lib/mingw32/3.1/cc1.exe -fpreprocessed foo.i -quiet -dumpbase foo.c -version -o D:\TEMP/cckdaaaa.s
GNU CPP version 3.1 20020202 (experimental) (cpplib) (80386, BSD syntax)
GNU C version 3.1 20020202 (experimental) (mingw32)
	compiled by GNU C version 3.1 20020117 (experimental).
 D:/MINGW/BIN/../lib/gcc-lib/mingw32/3.1/../../../../mingw32/bin/as.exe -o foo.o D:\TEMP/cckdaaaa.s
 D:/MINGW/BIN/../lib/gcc-lib/mingw32/3.1/../../../../mingw32/bin/ld.exe -Bdynamic -o foo.exe D:/MINGW/BIN/../lib/gcc-lib/mingw32/3.1/../../../../mingw32/lib/crt2.o -LD:/MINGW/BIN/../lib/gcc-lib/mingw32/3.1 -LD:/MINGW/BIN/../lib/gcc-lib -L/mingw/lib/gcc-lib/mingw32/3.1 -LD:/MINGW/BIN/../lib/gcc-lib/mingw32/3.1/../../../../mingw32/lib -L/mingw/lib/gcc-lib/mingw32/3.1/../../../../mingw32/lib -LD:/MINGW/BIN/../lib/gcc-lib/mingw32/3.1/../../.. -L/mingw/lib/gcc-lib/mingw32/3.1/../../.. foo.o -lmingw32 -lgcc -lmoldname -lisocext -lmsvcrt -luser32 -lkernel32 -ladvapi32 -lshell32 -lmingw32 -lgcc -lmoldname -lisocext -lmsvcrt

>How-To-Repeat:
Compile the following with "gcc -o foo -save-temps foo.c

/* foo.c * / 
int main()(return 0;}
>Fix:
revert this change:
2001-12-14  Ira Ruben	<ira@apple.com>

	Fix to no allow -save-temps to clobber user's source file.
	* gcc.c: Add static globals input_stat and input_stat_set.
	(do_spec_1): For 'g', 'u', 'U' case with save_temps_flag
	set, check that user's input file is not overwritten.
	(set_input): Reset input_stat_set for each new file.
>Release-Note:
>Audit-Trail:
>Unformatted:


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

end of thread, other threads:[~2003-05-13  1:16 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-05-13  1:16 other/5620: [3.1] GCC -save-temps foo.c fails to build foo.o Dara Hazeghi
  -- strict thread matches above, loose matches on Subject: below --
2002-12-10 17:16 Wolfgang Bangerth
2002-12-10 17:16 Danny Smith
2002-12-10 17:01 bangerth
2002-06-09 12:56 hp
2002-05-11 10:17 rodrigc
2002-02-06 18:06 danny_r_smith_2001

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).