You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
cgo is required to build on darwin (see #66). I think this error is related to cgo. Could you check your installed go argument? Go should be build with cgo-enabled.
i meet a problem when build gopsutil on mac
full error output:
not-type:1:35: error: use of undeclared identifier 'cgo_undefined'
void *cgo_f_1_2(void) { GoBytes __cgo_undefined; }
not-const:1:63: error: invalid operands to binary expression ('GoBytes (_)(void *, int)' and 'int')
void cgo_f_1_3(void) { enum { __cgo__undefined = (GoBytes)_1 }; }
not-type:2:52: error: use of undeclared identifier 'cgo_undefined'
void *cgo_f_2_2(void) { HOST_CPU_LOAD_INFO_COUNT __cgo_undefined; }
not-const:3:81: error: indirection requires pointer operand ('int' invalid)
void cgo_f_3_3(void) { enum { __cgo__undefined = (host_cpu_load_info_data_t)*1 }; }
not-const:4:67: error: indirection requires pointer operand ('int' invalid)
void cgo_f_4_3(void) { enum { __cgo__undefined = (host_info_t)*1 }; }
not-type:5:47: error: use of undeclared identifier 'cgo_undefined'
void *cgo_f_5_2(void) { host_processor_info __cgo_undefined; }
not-const:5:75: error: invalid operands to binary expression ('kern_return_t (_)(host_t, processor_flavor_t, natural_t *, processor_info_array_t *, mach_msg_type_number_t *)' and 'int')
void cgo_f_5_3(void) { enum { __cgo__undefined = (host_processor_info)_1 }; }
not-type:6:43: error: use of undeclared identifier 'cgo_undefined'
void *cgo_f_6_2(void) { host_statistics __cgo_undefined; }
not-const:6:71: error: invalid operands to binary expression ('kern_return_t (_)(host_t, host_flavor_t, host_info_t, mach_msg_type_number_t *)' and 'int')
void cgo_f_6_3(void) { enum { __cgo__undefined = (host_statistics)_1 }; }
not-const:7:62: error: indirection requires pointer operand ('int' invalid)
void cgo_f_7_3(void) { enum { __cgo__undefined = (host_t)*1 }; }
The text was updated successfully, but these errors were encountered: