This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug target/17582] New: Problem cross gcc with errno. Invalid reference.
- From: "sergey_s_m at mail dot ru" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 21 Sep 2004 12:44:05 -0000
- Subject: [Bug target/17582] New: Problem cross gcc with errno. Invalid reference.
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
I've tested next example for gcc-3.3.1 and for two cross compilers: mips_fp_be-
gcc and arm_v4t_le-gcc 3.3.1 as well.
(main.c)
------------------------------------------------------------------
extern int errno;
main()
{
printf("errno=%d\n",errno);
}
1. For native compiler the result was:
In function 'main':
: undefined reference to 'errno'
collect2: ld returned 1 exit status
2. For cross compilers the result was a.out file without any mistakes.
So I think there is a bug into cross compilers. Does anybody know how to fix
it?
PS: I've compiled like: gcc main.c; or mips_fp_be-gcc main.c; or arm_v4t_le-
gcc main.c
--
Summary: Problem cross gcc with errno. Invalid reference.
Product: gcc
Version: 3.3.1
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: target
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: sergey_s_m at mail dot ru
CC: gcc-bugs at gcc dot gnu dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17582