diff options
author | joel <joel@138bc75d-0d04-0410-961f-82ee72b054a4> | 2005-11-21 23:31:50 +0000 |
---|---|---|
committer | joel <joel@138bc75d-0d04-0410-961f-82ee72b054a4> | 2005-11-21 23:31:50 +0000 |
commit | 526eec38dadf7679bfda4af4fe5e4fb6cc9d4c14 (patch) | |
tree | b0b6d8d1d37dad9d942abc948411563e9fef36bc /gcc/ada/socket.c | |
parent | 72a6b07c4c8afddb3a5b5db4b1334a65dd713abf (diff) | |
download | gcc-526eec38dadf7679bfda4af4fe5e4fb6cc9d4c14.tar.gz |
2005-11-21 Joel Sherrill <joel.sherrill@oarcorp.com>
* socket.c: Add extern int h_errno for rtems since networking header
files are not available at this point in a tool bootstrap. Newlib
only has basic C library header files.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@107331 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ada/socket.c')
-rw-r--r-- | gcc/ada/socket.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/gcc/ada/socket.c b/gcc/ada/socket.c index d02763a9548..bb79ac30a72 100644 --- a/gcc/ada/socket.c +++ b/gcc/ada/socket.c @@ -189,6 +189,13 @@ __gnat_get_h_errno (void) { } #elif defined(VMS) return errno; +#elif defined(__rtems__) + /* At this stage in the tool build, no networking .h files are available. + Newlib does not provide networking .h files and RTEMS is not built yet. + So we need to explicitly extern h_errno to access it. + */ + extern int h_errno; + return h_errno; #else return h_errno; #endif |