[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
link error of liboctave (MinGW build)
From: |
John W. Eaton |
Subject: |
link error of liboctave (MinGW build) |
Date: |
Thu, 7 Jan 2010 00:56:20 -0500 |
On 7-Jan-2010, Tatsuro MATSUOKA wrote:
| I have at last reached to link stage of liboctave. However, unfortunately,
error occurred
| DLLs..libs/liboctave_la-glob-match.o:glob-match.cc:(.text+0x6e3): undefined
reference to
| `rpl_glob(char const*, int, int (*)(char const*, int), glob_t*)'
| .libs/liboctave_la-glob-match.o:glob-match.cc:(.text+0x893): undefined
reference
| to`rpl_globfree(glob_t*)'
| ../libgnu/.libs/libgnu.a(getlogin_r.o):getlogin_r.c:(.text+0x11): undefined
reference to `getlogin'
| collect2: ld returned 1 exit status
|
| For errors related glob, I have looked into glob.in.h
To see what is actually compiled, you should be looking at the
generated glob.h file in the libgnu directory of your build tree.
| The followings are found
| #define glob rpl_glob
| #define globfree rpl_globfree
| #define glob_pattern_p rpl_glob_pattern_p
| However there are no rpl_???? functions in glob.c.
I think this may be another case of missing extern "C" somewhere.
What is the output of
nm libgnu/.libs/libgnu.a
?
| ../libgnu/.libs/libgnu.a(getlogin_r.o):getlogin_r.c:(.text+0x11): undefined
reference to `getlogin'
| collect2: ld returned 1 exit status
| make[3]: *** [liboctave.la] Error 1
| make[3]: Leaving directory `/home/octaves/OctBuild/hg-devel/liboctave'
| make[2]: *** [all] Error 2
| make[2]: Leaving directory `/home/octaves/OctBuild/hg-devel/liboctave'
| make[1]: *** [all-recursive] Error 1
| make[1]: Leaving directory `/home/octaves/OctBuild/hg-devel'
| make: *** [all] Error 2
|
| There remained errors.
|
| For getlogin_r.c, I found symbol '_getlogin_r' in libgnu.a.
Clearly the getlogin_r.c function from gnulib expects the getlogin
function to exist. I'm not sure what the correct fix is here. I'll
ask the gnulib maintainers.
jwe