os/ossrv/genericopenlibs/openenvcore/libc/include/namespace.h
author sl
Tue, 10 Jun 2014 14:32:02 +0200
changeset 1 260cb5ec6c19
permissions -rw-r--r--
Update contrib.
     1 /*
     2  * Copyright (c) 2001 Daniel Eischen <deischen@FreeBSD.org>.
     3  * All rights reserved.
     4  *
     5  * Redistribution and use in source and binary forms, with or without
     6  * modification, are permitted provided that the following conditions
     7  * are met:
     8  * 1. Redistributions of source code must retain the above copyright
     9  *    notice, this list of conditions and the following disclaimer.
    10  * 2. Redistributions in binary form must reproduce the above copyright
    11  *    notice, this list of conditions and the following disclaimer in the
    12  *    documentation and/or other materials provided with the distribution.
    13  *
    14  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
    15  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
    16  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
    17  * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
    18  * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
    19  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
    20  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
    21  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
    22  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
    23  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
    24  * SUCH DAMAGE.
    25  *
    26  ** Portions Copyright (c) 2006 Nokia Corporation and/or its subsidiary(-ies).. All rights reserved.
    27  * $FreeBSD: src/lib/libc/include/namespace.h,v 1.16.12.1 2005/10/08 17:56:33 delphij Exp $
    28  */
    29 
    30 #ifndef _NAMESPACE_H_
    31 #define _NAMESPACE_H_
    32 
    33 /*
    34  * Adjust names so that headers declare "hidden" names.
    35  *
    36  * README: When modifying this file don't forget to make the appropriate
    37  *         changes in un-namespace.h!!!
    38  */
    39 
    40 /*
    41  * ISO C (C90) section.  Most names in libc aren't in ISO C, so they
    42  * should be here.  Most aren't here...
    43  */
    44 #define		err				_err
    45 #define		warn				_warn
    46 #define		nsdispatch			_nsdispatch
    47 
    48 /*
    49  * Prototypes for syscalls/functions that need to be overridden
    50  * in libc_r/libpthread.
    51  */
    52 #define		accept				_accept
    53 #define		__acl_aclcheck_fd		___acl_aclcheck_fd
    54 #define		__acl_delete_fd			___acl_delete_fd
    55 #define		__acl_get_fd			___acl_get_fd
    56 #define		__acl_set_fd			___acl_set_fd
    57 #define		bind				_bind
    58 #define		__cap_get_fd			___cap_get_fd
    59 #define		__cap_set_fd			___cap_set_fd
    60 #define		close				_close
    61 #define		connect				_connect
    62 #define		dup				_dup
    63 #define		dup2				_dup2
    64 #define		execve				_execve
    65 #define		fcntl				_fcntl
    66 /*#define		flock				_flock */
    67 #define		flockfile			_flockfile
    68 #define		fpathconf			_fpathconf
    69 #define		fstat				_fstat
    70 #define		fstatfs				_fstatfs
    71 #define		fsync				_fsync
    72 #define		funlockfile			_funlockfile
    73 /*#define		getdirentries			_getdirentries */
    74 #define		getlogin			_getlogin
    75 #define		getpeername			_getpeername
    76 #define		_getprogname			getprogname
    77 #define		getsockname			_getsockname
    78 #define		getsockopt			_getsockopt
    79 #define		ioctl				_ioctl
    80 /* #define		kevent				_kevent */
    81 #define		listen				_listen
    82 #define		nanosleep			_nanosleep
    83 #define		open				_open
    84 #define		poll				_poll
    85 #define		pthread_cond_broadcast		_pthread_cond_broadcast
    86 #define		pthread_cond_destroy		_pthread_cond_destroy
    87 #define		pthread_cond_init		_pthread_cond_init
    88 #define		pthread_cond_signal		_pthread_cond_signal
    89 #define		pthread_cond_timedwait		_pthread_cond_timedwait
    90 #define		pthread_cond_wait		_pthread_cond_wait
    91 #define		pthread_exit			_pthread_exit
    92 #define		pthread_getspecific		_pthread_getspecific
    93 #define		pthread_key_create		_pthread_key_create
    94 #define		pthread_key_delete		_pthread_key_delete
    95 #define		pthread_main_np			_pthread_main_np
    96 #define		pthread_mutex_destroy		_pthread_mutex_destroy
    97 #define		pthread_mutex_init		_pthread_mutex_init
    98 #define		pthread_mutex_lock		_pthread_mutex_lock
    99 #define		pthread_mutex_trylock		_pthread_mutex_trylock
   100 #define		pthread_mutex_unlock		_pthread_mutex_unlock
   101 #define		pthread_mutexattr_destroy	_pthread_mutexattr_destroy
   102 #define		pthread_mutexattr_init		_pthread_mutexattr_init
   103 #define		pthread_mutexattr_settype	_pthread_mutexattr_settype
   104 #define		pthread_once			_pthread_once
   105 #define		pthread_rwlock_destroy		_pthread_rwlock_destroy
   106 #define		pthread_rwlock_init		_pthread_rwlock_init
   107 #define		pthread_rwlock_rdlock		_pthread_rwlock_rdlock
   108 #define		pthread_rwlock_wrlock		_pthread_rwlock_wrlock
   109 #define		pthread_rwlock_tryrdlock	_pthread_rwlock_tryrdlock
   110 #define		pthread_rwlock_trywrlock	_pthread_rwlock_trywrlock
   111 #define		pthread_rwlock_unlock		_pthread_rwlock_unlock
   112 #define		pthread_self			_pthread_self
   113 #define		pthread_setspecific		_pthread_setspecific
   114 #define		pthread_sigmask			_pthread_sigmask
   115 #define		read				_read
   116 #define		readv				_readv
   117 #define		recvfrom			_recvfrom
   118 #define		recvmsg				_recvmsg
   119 #define		select				_select
   120 #define		sendmsg				_sendmsg
   121 #define		sendto				_sendto
   122 #define		setsockopt			_setsockopt
   123 /*#define		sigaction			_sigaction*/
   124 #define		sigprocmask			_sigprocmask
   125 #define		sigsuspend			_sigsuspend
   126 #define		socket				_socket
   127 #define		socketpair			_socketpair
   128 #define		usleep				_usleep
   129 #define		wait4				_wait4
   130 #define		waitpid				_waitpid
   131 #define		write				_write
   132 #define		writev				_writev
   133 
   134 
   135 /*
   136  * Other hidden syscalls/functions that libc_r needs to override
   137  * but are not used internally by libc.
   138  *
   139  * XXX - When modifying libc to use one of the following, remove
   140  * the prototype from below and place it in the list above.
   141  */
   142 #if 0
   143 #define		creat				_creat
   144 #define		fchflags			_fchflags
   145 #define		fchmod				_fchmod
   146 #define		ftrylockfile			_ftrylockfile
   147 #define		msync				_msync
   148 #define		nfssvc				_nfssvc
   149 #define		pause				_pause
   150 #define		pthread_rwlockattr_init		_pthread_rwlockattr_init
   151 #define		pthread_rwlockattr_destroy	_pthread_rwlockattr_destroy
   152 #define		sched_yield			_sched_yield
   153 #define		sendfile			_sendfile
   154 #define		shutdown			_shutdown
   155 #define		sigaltstack			_sigaltstack
   156 #define		sigpending			_sigpending
   157 #define		sigreturn			_sigreturn
   158 #define		sigsetmask			_sigsetmask
   159 #define		sleep				_sleep
   160 #define		system				_system
   161 #define		tcdrain				_tcdrain
   162 #define		wait				_wait
   163 #endif
   164 
   165 #endif /* _NAMESPACE_H_ */