Source file src/runtime/defs_openbsd.go

     1  // Copyright 2009 The Go Authors. All rights reserved.
     2  // Use of this source code is governed by a BSD-style
     3  // license that can be found in the LICENSE file.
     4  
     5  //go:build ignore
     6  
     7  /*
     8  Input to cgo.
     9  
    10  GOARCH=amd64 go tool cgo -godefs defs_openbsd.go
    11  GOARCH=386 go tool cgo -godefs defs_openbsd.go
    12  GOARCH=arm go tool cgo -godefs defs_openbsd.go
    13  GOARCH=arm64 go tool cgo -godefs defs_openbsd.go
    14  GOARCH=mips64 go tool cgo -godefs defs_openbsd.go
    15  */
    16  
    17  package runtime
    18  
    19  /*
    20  #include <sys/types.h>
    21  #include <sys/event.h>
    22  #include <sys/mman.h>
    23  #include <sys/time.h>
    24  #include <sys/unistd.h>
    25  #include <sys/signal.h>
    26  #include <errno.h>
    27  #include <fcntl.h>
    28  #include <pthread.h>
    29  #include <signal.h>
    30  */
    31  import "C"
    32  
    33  const (
    34  	EINTR  = C.EINTR
    35  	EFAULT = C.EFAULT
    36  	EAGAIN = C.EAGAIN
    37  
    38  	O_NONBLOCK = C.O_NONBLOCK
    39  	O_CLOEXEC  = C.O_CLOEXEC
    40  
    41  	PROT_NONE  = C.PROT_NONE
    42  	PROT_READ  = C.PROT_READ
    43  	PROT_WRITE = C.PROT_WRITE
    44  	PROT_EXEC  = C.PROT_EXEC
    45  
    46  	MAP_ANON    = C.MAP_ANON
    47  	MAP_PRIVATE = C.MAP_PRIVATE
    48  	MAP_FIXED   = C.MAP_FIXED
    49  	MAP_STACK   = C.MAP_STACK
    50  
    51  	MADV_FREE = C.MADV_FREE
    52  
    53  	SA_SIGINFO = C.SA_SIGINFO
    54  	SA_RESTART = C.SA_RESTART
    55  	SA_ONSTACK = C.SA_ONSTACK
    56  
    57  	PTHREAD_CREATE_DETACHED = C.PTHREAD_CREATE_DETACHED
    58  
    59  	F_SETFD    = C.F_SETFD
    60  	F_GETFL    = C.F_GETFL
    61  	F_SETFL    = C.F_SETFL
    62  	FD_CLOEXEC = C.FD_CLOEXEC
    63  
    64  	SIGHUP    = C.SIGHUP
    65  	SIGINT    = C.SIGINT
    66  	SIGQUIT   = C.SIGQUIT
    67  	SIGILL    = C.SIGILL
    68  	SIGTRAP   = C.SIGTRAP
    69  	SIGABRT   = C.SIGABRT
    70  	SIGEMT    = C.SIGEMT
    71  	SIGFPE    = C.SIGFPE
    72  	SIGKILL   = C.SIGKILL
    73  	SIGBUS    = C.SIGBUS
    74  	SIGSEGV   = C.SIGSEGV
    75  	SIGSYS    = C.SIGSYS
    76  	SIGPIPE   = C.SIGPIPE
    77  	SIGALRM   = C.SIGALRM
    78  	SIGTERM   = C.SIGTERM
    79  	SIGURG    = C.SIGURG
    80  	SIGSTOP   = C.SIGSTOP
    81  	SIGTSTP   = C.SIGTSTP
    82  	SIGCONT   = C.SIGCONT
    83  	SIGCHLD   = C.SIGCHLD
    84  	SIGTTIN   = C.SIGTTIN
    85  	SIGTTOU   = C.SIGTTOU
    86  	SIGIO     = C.SIGIO
    87  	SIGXCPU   = C.SIGXCPU
    88  	SIGXFSZ   = C.SIGXFSZ
    89  	SIGVTALRM = C.SIGVTALRM
    90  	SIGPROF   = C.SIGPROF
    91  	SIGWINCH  = C.SIGWINCH
    92  	SIGINFO   = C.SIGINFO
    93  	SIGUSR1   = C.SIGUSR1
    94  	SIGUSR2   = C.SIGUSR2
    95  
    96  	FPE_INTDIV = C.FPE_INTDIV
    97  	FPE_INTOVF = C.FPE_INTOVF
    98  	FPE_FLTDIV = C.FPE_FLTDIV
    99  	FPE_FLTOVF = C.FPE_FLTOVF
   100  	FPE_FLTUND = C.FPE_FLTUND
   101  	FPE_FLTRES = C.FPE_FLTRES
   102  	FPE_FLTINV = C.FPE_FLTINV
   103  	FPE_FLTSUB = C.FPE_FLTSUB
   104  
   105  	BUS_ADRALN = C.BUS_ADRALN
   106  	BUS_ADRERR = C.BUS_ADRERR
   107  	BUS_OBJERR = C.BUS_OBJERR
   108  
   109  	SEGV_MAPERR = C.SEGV_MAPERR
   110  	SEGV_ACCERR = C.SEGV_ACCERR
   111  
   112  	ITIMER_REAL    = C.ITIMER_REAL
   113  	ITIMER_VIRTUAL = C.ITIMER_VIRTUAL
   114  	ITIMER_PROF    = C.ITIMER_PROF
   115  
   116  	EV_ADD       = C.EV_ADD
   117  	EV_DELETE    = C.EV_DELETE
   118  	EV_CLEAR     = C.EV_CLEAR
   119  	EV_ERROR     = C.EV_ERROR
   120  	EV_EOF       = C.EV_EOF
   121  	EVFILT_READ  = C.EVFILT_READ
   122  	EVFILT_WRITE = C.EVFILT_WRITE
   123  )
   124  
   125  type TforkT C.struct___tfork
   126  
   127  type Sigcontext C.struct_sigcontext
   128  type Siginfo C.siginfo_t
   129  type Sigset C.sigset_t
   130  type Sigval C.union_sigval
   131  
   132  type StackT C.stack_t
   133  
   134  type Timespec C.struct_timespec
   135  type Timeval C.struct_timeval
   136  type Itimerval C.struct_itimerval
   137  
   138  type KeventT C.struct_kevent
   139  
   140  type Pthread C.pthread_t
   141  type PthreadAttr C.pthread_attr_t
   142  type PthreadCond C.pthread_cond_t
   143  type PthreadCondAttr C.pthread_condattr_t
   144  type PthreadMutex C.pthread_mutex_t
   145  type PthreadMutexAttr C.pthread_mutexattr_t
   146  

View as plain text