From: Will Wagner <will_wagner@carallon.com>
To: ecos-discuss@sources.redhat.com
Subject: [ECOS] link error due to unwanted exception support
Date: Fri, 13 May 2005 19:05:00 -0000 [thread overview]
Message-ID: <4284E6CE.8030303@carallon.com> (raw)
Hi,
I want to write a very simple C application that uses the minimal
template. This means that it has no heap and so no malloc/free.
When linking my application I get this error:
/opt/ecos/gnutools/powerpc-eabi/lib/gcc-lib/powerpc-eabi/3.3.3/../../../../powerpc-eabi/lib/nof/libsupc++.a(del_op.o)(.t
ext+0x14): In function `operator delete(void*)':
: undefined reference to `free'
/opt/ecos/gnutools/powerpc-eabi/lib/gcc-lib/powerpc-eabi/3.3.3/../../../../powerpc-eabi/lib/nof/libsupc++.a(eh_alloc.o)(
.text+0x98): In function `__cxa_allocate_exception':
: undefined reference to `malloc'
/opt/ecos/gnutools/powerpc-eabi/lib/gcc-lib/powerpc-eabi/3.3.3/../../../../powerpc-eabi/lib/nof/libsupc++.a(eh_alloc.o)(
.text+0x29c): In function `__cxa_free_exception':
: undefined reference to `free'
/opt/ecos/gnutools/powerpc-eabi/lib/gcc-lib/powerpc-eabi/3.3.3/../../../../powerpc-eabi/lib/nof/libsupc++.a(eh_globals.o
)(.text+0x54): In function `get_globals_dtor(void*)':
: undefined reference to `free'
/opt/ecos/gnutools/powerpc-eabi/lib/gcc-lib/powerpc-eabi/3.3.3/../../../../powerpc-eabi/lib/nof/libsupc++.a(eh_globals.o
)(.text+0x28c): In function `__cxa_get_globals':
: undefined reference to `malloc'
/opt/ecos/gnutools/powerpc-eabi/lib/gcc-lib/powerpc-eabi/3.3.3/nof/libgcc.a(unwind-dw2-fde.o)(.text+0x480):
In function
`__register_frame':
: undefined reference to `malloc'
/opt/ecos/gnutools/powerpc-eabi/lib/gcc-lib/powerpc-eabi/3.3.3/nof/libgcc.a(unwind-dw2-fde.o)(.text+0x594):
In function
`__register_frame_table':
: undefined reference to `malloc'
/opt/ecos/gnutools/powerpc-eabi/lib/gcc-lib/powerpc-eabi/3.3.3/nof/libgcc.a(unwind-dw2-fde.o)(.text+0x6c4):
In function
`__deregister_frame_info_bases':
: undefined reference to `free'
/opt/ecos/gnutools/powerpc-eabi/lib/gcc-lib/powerpc-eabi/3.3.3/nof/libgcc.a(unwind-dw2-fde.o)(.text+0x760):
In function
`__deregister_frame':
: undefined reference to `free'
/opt/ecos/gnutools/powerpc-eabi/lib/gcc-lib/powerpc-eabi/3.3.3/nof/libgcc.a(unwind-dw2-fde.o)(.text+0x167c):
In function
`init_object':
: undefined reference to `malloc'
/opt/ecos/gnutools/powerpc-eabi/lib/gcc-lib/powerpc-eabi/3.3.3/nof/libgcc.a(unwind-dw2-fde.o)(.text+0x169c):
In function
`init_object':
: undefined reference to `malloc'
/opt/ecos/gnutools/powerpc-eabi/lib/gcc-lib/powerpc-eabi/3.3.3/nof/libgcc.a(unwind-dw2-fde.o)(.text+0x180c):
In function
`init_object':
: undefined reference to `free'
I have no need for exception support and I'm compiling everything with
-fno-exceptions so why is it trying to link in these functions for
exception handling?
What compiler options do i need other than -fno-exceptions to remove
exception support?
I have managed to fix it temporarily by manually removing libsupc++.a
from the GROUPS entry in target.ld but as the file is autogenerated this
is a really bad solution.
Can anyone suggest what I'm doing wrong?
Many thanks,
Will Wagner
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
next reply other threads:[~2005-05-13 17:39 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-05-13 19:05 Will Wagner [this message]
2005-05-13 19:33 ` Gary Thomas
2005-05-16 12:41 ` Will Wagner
2005-05-16 19:42 ` Gary Thomas
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=4284E6CE.8030303@carallon.com \
--to=will_wagner@carallon.com \
--cc=ecos-discuss@sources.redhat.com \
/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).