OpenCores
URL https://opencores.org/ocsvn/c0or1k/c0or1k/trunk

Subversion Repositories c0or1k

[/] [c0or1k/] [trunk/] [conts/] [posix/] [libposix/] [include/] [posix/] [bits/] [uClibc_errno.h] - Blame information for rev 2

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 2 drasko
/*
2
 * Copyright (C) 2000-2006 Erik Andersen <andersen@uclibc.org>
3
 *
4
 * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
5
 */
6
#ifndef _BITS_UCLIBC_ERRNO_H
7
#define _BITS_UCLIBC_ERRNO_H 1
8
 
9
#ifdef IS_IN_rtld
10
# undef errno
11
# define errno _dl_errno
12
extern int _dl_errno; // attribute_hidden;
13
#elif defined __UCLIBC_HAS_THREADS__
14
# include <tls.h>
15
# if defined USE___THREAD && USE___THREAD
16
#  undef errno
17
#  ifndef NOT_IN_libc
18
#   define errno __libc_errno
19
#  else
20
#   define errno errno
21
#  endif
22
extern __thread int errno __attribute_tls_model_ie;
23
# endif /* USE___THREAD */
24
#endif /* IS_IN_rtld */
25
 
26
#define __set_errno(val) (errno = (val))
27
 
28
#ifndef __ASSEMBLER__
29
extern int *__errno_location (void) __THROW __attribute__ ((__const__))
30
# ifdef IS_IN_rtld
31
        attribute_hidden
32
# endif
33
;
34
# if defined __UCLIBC_HAS_THREADS__
35
#  include <tls.h>
36
#  if defined USE___THREAD && USE___THREAD
37
libc_hidden_proto(__errno_location)
38
#  endif
39
# endif
40
 
41
#endif /* !__ASSEMBLER__ */
42
 
43
#endif

powered by: WebSVN 2.1.0

© copyright 1999-2025 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.