github.com/go-darwin/sys@v0.0.0-20220510002607-68fd01f054ca/defs_darwin_amd64.go (about) 1 // Copyright 2021 The Go Darwin Authors 2 // SPDX-License-Identifier: BSD-3-Clause 3 4 //go:build ignore 5 // +build ignore 6 7 package sys 8 9 /* 10 #cgo CFLAGS: -mmacosx-version-min=12.0 11 12 typedef long long long_long; 13 14 #include <stdlib.h> 15 #include <stdint.h> 16 #include <stdbool.h> 17 #include <libproc.h> 18 #include <mach/mach.h> 19 */ 20 import "C" 21 22 type ( 23 c_short C.short 24 c_int C.int 25 c_int8 C.int8_t 26 c_int16 C.int16_t 27 c_int32 C.int32_t 28 c_int64 C.int64_t 29 c_long C.long 30 c_longLong C.long_long 31 c_uint C.uint 32 c_uint8 C.uint8_t 33 c_uint16 C.uint16_t 34 c_uint32 C.uint32_t 35 c_uint64 C.uint64_t 36 c_char C.char 37 c_float C.float 38 c_double C.double 39 c_size_t C.size_t 40 ) 41 42 type kernReturn C.kern_return_t 43 44 const ( 45 kernSuccess kernReturn = C.KERN_SUCCESS 46 kernInvalidAddress kernReturn = C.KERN_INVALID_ADDRESS 47 kernProtectionFailure kernReturn = C.KERN_PROTECTION_FAILURE 48 kernNoSpace kernReturn = C.KERN_NO_SPACE 49 kernInvalidArgument kernReturn = C.KERN_INVALID_ARGUMENT 50 kernFailure kernReturn = C.KERN_FAILURE 51 kernResourceShortage kernReturn = C.KERN_RESOURCE_SHORTAGE 52 kernNotReceiver kernReturn = C.KERN_NOT_RECEIVER 53 kernNoAccess kernReturn = C.KERN_NO_ACCESS 54 kernMemoryFailure kernReturn = C.KERN_MEMORY_FAILURE 55 KernMemoryError kernReturn = C.KERN_MEMORY_ERROR 56 kernAlreadyInSet kernReturn = C.KERN_ALREADY_IN_SET 57 kernNotInSet kernReturn = C.KERN_NOT_IN_SET 58 kernNameExists kernReturn = C.KERN_NAME_EXISTS 59 kernAborted kernReturn = C.KERN_ABORTED 60 kernInvalidName kernReturn = C.KERN_INVALID_NAME 61 kernInvalidTask kernReturn = C.KERN_INVALID_TASK 62 kernInvalidRight kernReturn = C.KERN_INVALID_RIGHT 63 kernInvalidValue kernReturn = C.KERN_INVALID_VALUE 64 kernUrefsOverflow kernReturn = C.KERN_UREFS_OVERFLOW 65 kernInvalidCapability kernReturn = C.KERN_INVALID_CAPABILITY 66 kernRightExists kernReturn = C.KERN_RIGHT_EXISTS 67 kernInvalidHost kernReturn = C.KERN_INVALID_HOST 68 kernMemoryPresent kernReturn = C.KERN_MEMORY_PRESENT 69 kernMemoryDataMoved kernReturn = C.KERN_MEMORY_DATA_MOVED 70 kernMemoryRestartCopy kernReturn = C.KERN_MEMORY_RESTART_COPY 71 kernInvalidProcessorSet kernReturn = C.KERN_INVALID_PROCESSOR_SET 72 kernPolicyLimit kernReturn = C.KERN_POLICY_LIMIT 73 kernInvalidPolicy kernReturn = C.KERN_INVALID_POLICY 74 kernInvalidObject kernReturn = C.KERN_INVALID_OBJECT 75 kernAlreadyWaiting kernReturn = C.KERN_ALREADY_WAITING 76 kernDefaultSet kernReturn = C.KERN_DEFAULT_SET 77 kernExceptionProtected kernReturn = C.KERN_EXCEPTION_PROTECTED 78 kernInvalidLedger kernReturn = C.KERN_INVALID_LEDGER 79 kernInvalidMemoryControl kernReturn = C.KERN_INVALID_MEMORY_CONTROL 80 kernInvalidSecurity kernReturn = C.KERN_INVALID_SECURITY 81 kernNotDepressed kernReturn = C.KERN_NOT_DEPRESSED 82 kernTerminated kernReturn = C.KERN_TERMINATED 83 kernLockSetDestroyed kernReturn = C.KERN_LOCK_SET_DESTROYED 84 kernLockUnstable kernReturn = C.KERN_LOCK_UNSTABLE 85 kernLockOwned kernReturn = C.KERN_LOCK_OWNED 86 kernLockOwnedSelf kernReturn = C.KERN_LOCK_OWNED_SELF 87 kernSemaphoreDestroyed kernReturn = C.KERN_SEMAPHORE_DESTROYED 88 kernRPCServerTerminated kernReturn = C.KERN_RPC_SERVER_TERMINATED 89 kernRPCTerminateOrphan kernReturn = C.KERN_RPC_TERMINATE_ORPHAN 90 kernRPCContinueOrphan kernReturn = C.KERN_RPC_CONTINUE_ORPHAN 91 kernNotSupported kernReturn = C.KERN_NOT_SUPPORTED 92 kernNodeDown kernReturn = C.KERN_NODE_DOWN 93 kernNotWaiting kernReturn = C.KERN_NOT_WAITING 94 kernOperationTimedOut kernReturn = C.KERN_OPERATION_TIMED_OUT 95 kernCodesignError kernReturn = C.KERN_CODESIGN_ERROR 96 kernPolicyStatic kernReturn = C.KERN_POLICY_STATIC 97 kernInsufficientBufferSize kernReturn = C.KERN_INSUFFICIENT_BUFFER_SIZE 98 kernDenied kernReturn = C.KERN_DENIED 99 kernMissingKC kernReturn = C.KERN_MISSING_KC 100 kernInvalidKC kernReturn = C.KERN_INVALID_KC 101 kernReturnMax kernReturn = C.KERN_RETURN_MAX 102 )