Bug 2794 - undef. reference to __log1p in libm.so
Summary: undef. reference to __log1p in libm.so
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Red Hat Raw Hide
Classification: Retired
Component: glibc
Version: 1.0
Hardware: i386
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Cristian Gafton
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 1999-05-13 19:02 UTC by matthew
Modified: 2008-05-01 15:37 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 1999-07-02 20:45:03 UTC


Attachments (Terms of Use)

Description matthew 1999-05-13 19:02:41 UTC
I really don't know if this is a glibc, g++, or Red Hat
problem, but here goes...
Compile the following with g++ (atanh.C) and be sure to link
with libm.so (not libm.a):

#include <math.h>
int main() {
  return (int)(atanh(0.5));
}

% g++ -O1 atanh.C /usr/lib/libm.so
/tmp/ccfkSv4a1.o: In function `main':
/tmp/ccfkSv4a1.o(.text+0x21): undefined reference to
`__log1p'
collect2: ld returned 1 exit status

But 'g++ -O1 atanh.C /usr/lib/libm.a' OR
    'g++ -O0 atanh.C /usr/lib/libm.so' OR
    'gcc -O1 atanh.c /usr/lib/libm.so'
works fine.

I'm using Red Hat 5.2 (w/ egcs-c++-1.0.3a-14) and I just
upgraded my glibc to glibc-2.1.1-7 from rawhide.  I had no
problems when I was using the glibc that came with 5.2
(glibc-2.0.7-29).

Please pardon me if this is an inappropriate place to report
this problem.

Comment 1 Cristian Gafton 1999-07-02 20:45:59 UTC
The compiler needs to be updated too. binutils must follow, etc. You
can not update glibc from 2.0 to 2.1 and expect the old development
environment to still work.


Note You need to log in before you can comment on or make changes to this bug.