* g++ -lmalloc error
@ 2002-06-28 1:52 Long Li
0 siblings, 0 replies; 2+ messages in thread
From: Long Li @ 2002-06-28 1:52 UTC (permalink / raw)
To: gcc-help
Hi, Guys,
I am having a problem when I try to compile a file
with g++.
When I typed:
g++ -Wall -g -lpthread -lrt -lmalloc -I{$my_file_path}
I got such error:
/usr/bin/ld: can not find -lmalloc
collect2: ld returned 1 exit status
I guess the problem is from ld. Could you tell me what
I need to do to make it work?
Thanks a lot!
Long
__________________________________________________
Do You Yahoo!?
Yahoo! - Official partner of 2002 FIFA World Cup
http://fifaworldcup.yahoo.com
^ permalink raw reply [flat|nested] 2+ messages in thread
[parent not found: <616BE6A276E3714788D2AC35C40CD18D6BF9FC@whale.softwire.co.uk>]
* RE: g++ -lmalloc error
[not found] <616BE6A276E3714788D2AC35C40CD18D6BF9FC@whale.softwire.co.uk>
@ 2002-06-28 2:05 ` Rupert Wood
0 siblings, 0 replies; 2+ messages in thread
From: Rupert Wood @ 2002-06-28 2:05 UTC (permalink / raw)
To: 'Long Li'; +Cc: gcc-help
Long Li wrote:
> g++ -Wall -g -lpthread -lrt -lmalloc -I{$my_file_path}
:
> /usr/bin/ld: can not find -lmalloc
> collect2: ld returned 1 exit status
The problem is that you're asking ld to link against libmalloc.a or
libmalloc.so but it can't find either of these.
Do you have a libmalloc.a or .so? If so, make sure that ld is searching
the path it's in (you can add paths using '-L').
Do you really need libmalloc? The function is probably available in the
C library unless you've got special requirements. Check your OS C
library documentation.
Rup.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2002-06-28 9:05 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-06-28 1:52 g++ -lmalloc error Long Li
[not found] <616BE6A276E3714788D2AC35C40CD18D6BF9FC@whale.softwire.co.uk>
2002-06-28 2:05 ` Rupert Wood
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).