Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] Building the repo fails on Mac M1 machine #147

Open
venkateshatr opened this issue Jul 27, 2024 · 0 comments
Open

[BUG] Building the repo fails on Mac M1 machine #147

venkateshatr opened this issue Jul 27, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@venkateshatr
Copy link

Describe the bug
I am trying to build the project on my Mac M1 laptop using the go build grofer.go. But it is failing to build the package with logs like

github.com/pesos/grofer/pkg/sink/tui/misc

pkg/sink/tui/misc/signals.go:174:23: undefined: syscall.SIGCLD
pkg/sink/tui/misc/signals.go:184:23: undefined: syscall.SIGPOLL
pkg/sink/tui/misc/signals.go:186:23: undefined: syscall.SIGPWR
pkg/sink/tui/misc/signals.go:189:23: undefined: syscall.SIGSTKFLT
pkg/sink/tui/misc/signals.go:197:23: undefined: syscall.SIGUNUSED

github.com/shirou/gopsutil/disk

iostat_darwin.c:28:2: warning: 'IOMasterPort' is deprecated: first deprecated in macOS 12.0 [-Wdeprecated-declarations]
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/System/Library/Frameworks/IOKit.framework/Headers/IOKitLib.h:143:1: note: 'IOMasterPort' has been explicitly marked deprecated here

github.com/shirou/gopsutil/host

smc_darwin.c:75:41: warning: 'kIOMasterPortDefault' is deprecated: first deprecated in macOS 12.0 [-Wdeprecated-declarations]
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/System/Library/Frameworks/IOKit.framework/Headers/IOKitLib.h:133:19: note: 'kIOMasterPortDefault' has been explicitly marked deprecated here

To Reproduce
Steps to reproduce the behavior:

  1. Clone the repo on a Apple Mac book M1/M2 laptop
  2. Goto folder where project is cloned and issue the command go build grofer.go (golang already installed)
  3. Check the logs printed.

Expected behavior
Build should succeed.

Screenshots
image

Desktop (please complete the following information):

  • OS: Macbook
  • Chip Info: Apple M1 Pro
  • Go Version go1.20.2 darwin/amd64

Additional context
Existing binary with AMD64 architecture doesn't run on M1 machines.

@venkateshatr venkateshatr added the bug Something isn't working label Jul 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant