NetBSD-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: lib/40983: iconv(3) man page says linking -lc is enough, but -liconv is needed
The following reply was made to PR lib/40983; it has been noted by GNATS.
From: Takehiko NOZAKI <takehiko.nozaki%gmail.com@localhost>
To: michael+netbsd%stapelberg.de@localhost
Cc: gnats-bugs%netbsd.org@localhost
Subject: Re: lib/40983: iconv(3) man page says linking -lc is enough, but
-liconv is needed
Date: Mon, 9 Mar 2009 02:12:17 +0900
hi,
> When not specifying -liconv, I get:
> src/util.o: In function `convert_utf8_to_ucs2':
> src/util.c:161: undefined reference to `libiconv_open'
> src/util.c:169: undefined reference to `libiconv'
> src/util.c:172: undefined reference to `libiconv'
> gmake: *** [all] Error 1
it seems that your application includes GNU libiconv's
header(/usr/pkg/include/iconv.h),
you have to set correct include path and use NetBSD's own
header(/usr/include/iconv.h).
GNU libiconv rewrites iconv_open() to libiconv_open() in its header file
to avoid conflict with libc's symbol. so that this is not bug :)
if you want use GNU libiconv(not NetBSD), you have to specify
-L/usr/pkg/lib -liconv.
(but their manpage is not mention about it..., please comtact GNU
libiconv's maintainor)
very truly yours.
--
Takehiko NOZAKI<tnozaki%NetBSD.org@localhost>
Home |
Main Index |
Thread Index |
Old Index