This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: 3.0.4 (64bit) on SunOS 5.8 sparc - sys_errlist undefined
- From: Brian C Hill <bchill at bch dot net>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Thu, 14 Mar 2002 09:52:47 -0800
- Subject: Re: 3.0.4 (64bit) on SunOS 5.8 sparc - sys_errlist undefined
- References: <20020313174058.A1938@mark.bch.net>
/usr/include/errno.h says that sys_errlist and sys_nerr are
visible in the 64-bit libs - must use strerror(3).
Brian
======================================================================
On Wed, Mar 13, 2002 at 05:40:58PM -0800, Brian C Hill wrote:
> Several programs (tcp wrappers, qpopper and others) I have
> tried compiling are giving me this:
>
> Undefined first referenced
> symbol in file
> sys_errlist /var/tmp/ccMv2vDb.o
> ld: fatal: Symbol referencing errors. No output written to a.out
> collect2: ld returned 1 exit status
>
> This simple program also generates the error, compiled simply
> with "gcc x.c"
>
> ----------------------------------------------------------------------
> x.c:
> ----------------------------------------------------------------------
> extern char *sys_errlist[];
>
> main()
> {
> int a;
>
> if (sys_errlist[0][0] == 'c') a=1;
> }
> ----------------------------------------------------------------------
>
> I give up. This did not happen with older version of gcc...
>
> What am I not getting' here?
>
> Brian
--
_____________________________________________________________________
/ Brian C. Hill bchill@bch.net http://brian.bch.net \
| Unix Specialist BCH Technical Services http://www.bch.net |