Opened 16 months ago

Last modified 16 months ago

#67716 assigned defect

wormhole-william @1.0.6: //go:linkname must refer to declared function or variable

Reported by: jrabinow Owned by: jasperweiss (Jasper Weiss)
Priority: Normal Milestone:
Component: ports Version: 2.8.1
Keywords: Cc: herbygillot (Herby Gillot)
Port: wormhole-william

Description

I'm not sure if this is a bug or an issue on my system.

Machine info:

macOS 13.3 22E252 arm64
Xcode 14.3 14E222b
$ sudo port install wormhole-william
--->  Computing dependencies for wormhole-william
--->  Fetching archive for wormhole-william
--->  Attempting to fetch wormhole-william-1.0.6_0.darwin_22.arm64.tbz2 from https://packages.macports.org/wormhole-william
--->  Attempting to fetch wormhole-william-1.0.6_0.darwin_22.arm64.tbz2 from http://mirror.fcix.net/macports/packages/wormhole-william
--->  Attempting to fetch wormhole-william-1.0.6_0.darwin_22.arm64.tbz2 from https://ywg.ca.packages.macports.org/mirror/macports/packages/wormhole-william
--->  Fetching distfiles for wormhole-william
--->  Verifying checksums for wormhole-william
--->  Extracting wormhole-william
--->  Configuring wormhole-william
--->  Building wormhole-william
Error: Failed to build wormhole-william: command execution failed
Error: See /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_sysutils_wormhole-william/wormhole-william/main.log for details.
Error: Follow https://guide.macports.org/#project.tickets if you believe there is a bug.
Error: Processing of port wormhole-william failed
[Exit 1]

Logs (main.log) attached.

$ sudo -u macports bash
Password:
shell-init: error retrieving current directory: getcwd: cannot access parent directories: Permission denied
bash: /Users/julien/.bashrc: Permission denied
bash-5.2$ cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_sysutils_wormhole-william/wormhole-william/work/gopath/src/github.com/psanford/wormhole-william/"
bash-5.2$ ls
LICENSE    build_release.go  cmd       go.mod  internal  rendezvous      version   wormhole
README.md  ci                examples  go.sum  main.go   tag_version.go  wordlist
bash-5.2$ go build
failed to initialize build cache at /Users/julien/Library/Caches/go-build: mkdir /Users/julien/Library/Caches: permission denied
bash-5.2$ exit
[Exit 1]
$ /bin/ls -lde ~/Library/Caches/
drwx------+ 127 julien  staff  4064 Jul  3 18:39 /Users/julien/Library/Caches/
 0: group:everyone deny delete
$

I'm not sure how to debug this, if anyone could provide me with a hint or 2 I'd be most grateful.

Attachments (1)

main.log (125.9 KB) - added by jrabinow 16 months ago.

Download all attachments as: .zip

Change History (6)

Changed 16 months ago by jrabinow

Attachment: main.log added

comment:1 Changed 16 months ago by jmroot (Joshua Root)

Owner: set to jasperweiss
Port: wormhole-william added
Status: newassigned

Please remember to fill in the Port field and Cc the maintainer.

comment:2 Changed 16 months ago by jrabinow

Sorry I missed that, thanks for the tidying up

comment:3 Changed 16 months ago by ryandesign (Ryan Carsten Schmidt)

Cc: herbygillot added
Summary: wormhole-william 1.0.6 build error on Mac OS M1wormhole-william @1.0.6: //go:linkname must refer to declared function or variable
Version: 2.8.1

The errors in the log start with:

:info:build # github.com/fatih/color/vendor/golang.org/x/sys/unix
:info:build ../../fatih/color/vendor/golang.org/x/sys/unix/syscall_darwin.1_13.go:25:3: //go:linkname must refer to declared function or variable

It's not just your system. We see it on a build machine too. I think something must have changed in the go ecosystem since wormhole-william was updated to 1.0.6 but there is no newer version of wormhole-william that we could update to yet. I guess the problem should be reported to the developer of wormhole-william so they can update whatever needs to be updated.

This post suggests go 1.18 and later are what caused the problem; fatih/color's vendored x/sys dependency would need to be updated to a newer version that is compatible with go 1.18 and later.

This port uses fatih/color 1.10.0. The release notes for fatih/color 1.15.0 say x/sys was updated to 0.6.0 in that version so that may resolve the problem, however x/sys 0.9.0 is available today; I don't know in which version of x/sys the go 1.18 incompatibility was resolved. And I don't know if we can just update wormhole-william's fatih/color dependency without disturbing the rest of wormhole-william; I'm not familiar with how go works. Herby has done a lot of work on the go ports in MacPorts so I'm Cc'ing him for possible input.

wormhole-william does not list fatih/color in its dependencies so I guess it is an indirect dependency but I don't know of what.

Last edited 16 months ago by ryandesign (Ryan Carsten Schmidt) (previous) (diff)

comment:4 Changed 16 months ago by jrabinow

I saw those errors as well and wondered if they might not be related, but the logs keep going after. I tried sudoing to macports and running go build myself, I put the log of how that went in the description. According to that attempt, I suspect a permissions error when attempting to create ~/Library/Caches. go build is being run as macports but tries to create a new directory in the user's homedir is my read on things.

comment:5 Changed 16 months ago by jrabinow

For the record I ran go get github.com/psanford/wormhole-william and go install github.com/psanford/wormhole-william and it's running just fine on my system today

Note: See TracTickets for help on using tickets.