Source file src/runtime/defs_netbsd.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 -cdefs defs_netbsd.go defs_netbsd_amd64.go >defs_netbsd_amd64.h
    11  GOARCH=386 go tool cgo -cdefs defs_netbsd.go defs_netbsd_386.go >defs_netbsd_386.h
    12  GOARCH=arm go tool cgo -cdefs defs_netbsd.go defs_netbsd_arm.go >defs_netbsd_arm.h
    13  */
    14  
    15  // +godefs map __fpregset_t [644]byte
    16  
    17  package runtime
    18  
    19  /*
    20  #include <sys/types.h>
    21  #include <sys/mman.h>
    22  #include <sys/signal.h>
    23  #include <sys/event.h>
    24  #include <sys/time.h>
    25  #include <sys/ucontext.h>
    26  #include <sys/unistd.h>
    27  #include <errno.h>
    28  #include <signal.h>
    29  */
    30  import "C"
    31  
    32  const (
    33  	EINTR  = C.EINTR
    34  	EFAULT = C.EFAULT
    35  	EAGAIN = C.EAGAIN
    36  
    37  	O_NONBLOCK = C.O_NONBLOCK
    38  	O_CLOEXEC  = C.O_CLOEXEC
    39  
    40  	PROT_NONE  = C.PROT_NONE
    41  	PROT_READ  = C.PROT_READ
    42  	PROT_WRITE = C.PROT_WRITE
    43  	PROT_EXEC  = C.PROT_EXEC
    44  
    45  	MAP_ANON    = C.MAP_ANON
    46  	MAP_PRIVATE = C.MAP_PRIVATE
    47  	MAP_FIXED   = C.MAP_FIXED
    48  
    49  	MADV_FREE = C.MADV_FREE
    50  
    51  	SA_SIGINFO = C.SA_SIGINFO
    52  	SA_RESTART = C.SA_RESTART
    53  	SA_ONSTACK = C.SA_ONSTACK
    54  
    55  	SIGHUP    = C.SIGHUP
    56  	SIGINT    = C.SIGINT
    57  	SIGQUIT   = C.SIGQUIT
    58  	SIGILL    = C.SIGILL
    59  	SIGTRAP   = C.SIGTRAP
    60  	SIGABRT   = C.SIGABRT
    61  	SIGEMT    = C.SIGEMT
    62  	SIGFPE    = C.SIGFPE
    63  	SIGKILL   = C.SIGKILL
    64  	SIGBUS    = C.SIGBUS
    65  	SIGSEGV   = C.SIGSEGV
    66  	SIGSYS    = C.SIGSYS
    67  	SIGPIPE   = C.SIGPIPE
    68  	SIGALRM   = C.SIGALRM
    69  	SIGTERM   = C.SIGTERM
    70  	SIGURG    = C.SIGURG
    71  	SIGSTOP   = C.SIGSTOP
    72  	SIGTSTP   = C.SIGTSTP
    73  	SIGCONT   = C.SIGCONT
    74  	SIGCHLD   = C.SIGCHLD
    75  	SIGTTIN   = C.SIGTTIN
    76  	SIGTTOU   = C.SIGTTOU
    77  	SIGIO     = C.SIGIO
    78  	SIGXCPU   = C.SIGXCPU
    79  	SIGXFSZ   = C.SIGXFSZ
    80  	SIGVTALRM = C.SIGVTALRM
    81  	SIGPROF   = C.SIGPROF
    82  	SIGWINCH  = C.SIGWINCH
    83  	SIGINFO   = C.SIGINFO
    84  	SIGUSR1   = C.SIGUSR1
    85  	SIGUSR2   = C.SIGUSR2
    86  
    87  	FPE_INTDIV = C.FPE_INTDIV
    88  	FPE_INTOVF = C.FPE_INTOVF
    89  	FPE_FLTDIV = C.FPE_FLTDIV
    90  	FPE_FLTOVF = C.FPE_FLTOVF
    91  	FPE_FLTUND = C.FPE_FLTUND
    92  	FPE_FLTRES = C.FPE_FLTRES
    93  	FPE_FLTINV = C.FPE_FLTINV
    94  	FPE_FLTSUB = C.FPE_FLTSUB
    95  
    96  	BUS_ADRALN = C.BUS_ADRALN
    97  	BUS_ADRERR = C.BUS_ADRERR
    98  	BUS_OBJERR = C.BUS_OBJERR
    99  
   100  	SEGV_MAPERR = C.SEGV_MAPERR
   101  	SEGV_ACCERR = C.SEGV_ACCERR
   102  
   103  	ITIMER_REAL    = C.ITIMER_REAL
   104  	ITIMER_VIRTUAL = C.ITIMER_VIRTUAL
   105  	ITIMER_PROF    = C.ITIMER_PROF
   106  
   107  	EV_ADD       = C.EV_ADD
   108  	EV_DELETE    = C.EV_DELETE
   109  	EV_CLEAR     = C.EV_CLEAR
   110  	EV_RECEIPT   = 0
   111  	EV_ERROR     = C.EV_ERROR
   112  	EV_EOF       = C.EV_EOF
   113  	EVFILT_READ  = C.EVFILT_READ
   114  	EVFILT_WRITE = C.EVFILT_WRITE
   115  )
   116  
   117  type Sigset C.sigset_t
   118  type Siginfo C.struct__ksiginfo
   119  
   120  type StackT C.stack_t
   121  
   122  type Timespec C.struct_timespec
   123  type Timeval C.struct_timeval
   124  type Itimerval C.struct_itimerval
   125  
   126  type McontextT C.mcontext_t
   127  type UcontextT C.ucontext_t
   128  
   129  type Kevent C.struct_kevent
   130  

View as plain text