public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
From: eru@netti.fi
To: gcc-gnats@gcc.gnu.org
Subject: debug/8229: Linking of a program fails if -g used on GCC 3.2/RH 7.1
Date: Tue, 15 Oct 2002 03:16:00 -0000	[thread overview]
Message-ID: <20021015101507.17957.qmail@sources.redhat.com> (raw)


>Number:         8229
>Category:       debug
>Synopsis:       Linking of a program fails if -g used on GCC 3.2/RH 7.1
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Oct 15 03:16:01 PDT 2002
>Closed-Date:
>Last-Modified:
>Originator:     Erkki Ruohtula
>Release:        GCC 3.2
>Organization:
>Environment:

>Description:
Compiling&linking the attached small (selfcontained) program
succeeds if no debugging option is used, fails with an
error message from "ld" if "-g" was specified.
>How-To-Repeat:
% gcc -v -g stupid-link-warning.c
Reading specs from /opt/gcc/linux/ix86/gcc_3.2/lib/gcc-lib/i686-pc-linux-gnu/3.2/specs
Configured with: /usr/local/src/gcc-3.2/configure --prefix=/opt/gcc/linux/ix86/gcc_3.2 --enable-__cxa_atexit --enable-threads=posix --enable-shared
Thread model: posix
gcc version 3.2
 /opt/gcc/linux/ix86/gcc_3.2/lib/gcc-lib/i686-pc-linux-gnu/3.2/cc1 -lang-c -v -D__GNUC__=3 -D__GNUC_MINOR__=2 -D__GNUC_PATCHLEVEL__=0 -D__GXX_ABI_VERSION=102 -D__ELF__ -Dunix -D__gnu_linux__ -Dlinux -D__ELF__ -D__unix__ -D__gnu_linux__ -D__linux__ -D__unix -D__linux -Asystem=posix -D__NO_INLINE__ -D__STDC_HOSTED__=1 -Acpu=i386 -Amachine=i386 -Di386 -D__i386 -D__i386__ -D__tune_i686__ -D__tune_pentiumpro__ stupid-link-warning.c -quiet -dumpbase stupid-link-warning.c -g -version -o /tmp/ccZ7fwxu.s
GNU CPP version 3.2 (cpplib) (i386 Linux/ELF)
GNU C version 3.2 (i686-pc-linux-gnu)
        compiled by GNU C version 3.2.
ignoring nonexistent directory "/opt/gcc/linux/ix86/gcc_3.2/i686-pc-linux-gnu/include"
#include "..." search starts here:
#include <...> search starts here:
 /usr/local/include
 /opt/gcc/linux/ix86/gcc_3.2/include
 /opt/gcc/linux/ix86/gcc_3.2/lib/gcc-lib/i686-pc-linux-gnu/3.2/include
 /usr/include
End of search list.
 as --traditional-format -V -Qy -o /tmp/ccaF4iyW.o /tmp/ccZ7fwxu.s
GNU assembler version 2.11.90.0.8 (i386-redhat-linux) using BFD version 2.11.90.0.8
 /opt/gcc/linux/ix86/gcc_3.2/lib/gcc-lib/i686-pc-linux-gnu/3.2/collect2 -m elf_i386 -dynamic-linker /lib/ld-linux.so.2 /usr/lib/crt1.o /usr/lib/crti.o /opt/gcc/linux/ix86/gcc_3.2/lib/gcc-lib/i686-pc-linux-gnu/3.2/crtbegin.o -L/opt/gcc/linux/ix86/gcc_3.2/lib/gcc-lib/i686-pc-linux-gnu/3.2 -L/opt/gcc/linux/ix86/gcc_3.2/lib/gcc-lib/i686-pc-linux-gnu/3.2/../../.. /tmp/ccaF4iyW.o -lgcc -lgcc_eh -lc -lgcc -lgcc_eh /opt/gcc/linux/ix86/gcc_3.2/lib/gcc-lib/i686-pc-linux-gnu/3.2/crtend.o /usr/lib/crtn.o
/usr/bin/ld: Dwarf Error: Invalid or unhandled FORM value: 14.
/usr/bin/ld: Dwarf Error: Invalid or unhandled FORM value: 14.
/usr/bin/ld: Dwarf Error: Invalid or unhandled FORM value: 14.
/tmp/ccaF4iyW.o: In function `main':
:7: the use of `tempnam' is dangerous, better use `mkstemp'
collect2: ld returned 1 exit status
>Fix:

>Release-Note:
>Audit-Trail:
>Unformatted:
----gnatsweb-attachment----
Content-Type: application/octet-stream; name="stupid-link-warning.c"
Content-Transfer-Encoding: base64
Content-Disposition: attachment; filename="stupid-link-warning.c"

ZXh0ZXJuICAgICAgIGNoYXIgKnRlbXBuYW0oY29uc3QgY2hhciAqZGlyLCBjb25zdCBjaGFyICpw
ZngpOwoKZXh0ZXJuIGludCBwdXRzKGNvbnN0IGNoYXIgKnMpOwoKaW50IG1haW4odm9pZCkKewog
ICAgY2hhciAqcCA9IHRlbXBuYW0oIi90bXAiLCAieHl6enkiKTsKCgogICAgcHV0cyhwKTsKICAg
IHJldHVybiAwOwp9Cg==


             reply	other threads:[~2002-10-15 10:16 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-10-15  3:16 eru [this message]
2002-10-21 23:46 rth

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20021015101507.17957.qmail@sources.redhat.com \
    --to=eru@netti.fi \
    --cc=gcc-gnats@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).