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

cgo compiler errors against go-alpm #46

Open
focusaurus opened this issue Mar 29, 2024 · 2 comments
Open

cgo compiler errors against go-alpm #46

focusaurus opened this issue Mar 29, 2024 · 2 comments

Comments

@focusaurus
Copy link

Are you on latest version of yup?

Yes, I am trying to build from the aur. I've also tried the current master branch from github as well as the most recent tag

Steps to Reproduce the Problem

  1. git clone https://aur.archlinux.org/yup.git
    1.cd yup && makepkg -si
# github.com/Jguer/go-alpm/v2
/home/plyons/go/pkg/mod/github.com/!jguer/go-alpm/[email protected]/db.go:148:103: cannot use _cgo0 (variable of type *_Ctype_struct___alpm_list_t) as *_Ctype_struct__alpm_list_t value in argument to _Cfunc_alpm_find_group_pkgs
/home/plyons/go/pkg/mod/github.com/!jguer/go-alpm/[email protected]/deps.go:22:75: cannot use _cgo0 (variable of type *_Ctype_struct___alpm_handle_t) as *_Ctype_struct__alpm_handle_t value in argument to _Cfunc_alpm_find_dbs_satisfier
/home/plyons/go/pkg/mod/github.com/!jguer/go-alpm/[email protected]/deps.go:22:75: cannot use _cgo1 (variable of type *_Ctype_struct___alpm_list_t) as *_Ctype_struct__alpm_list_t value in argument to _Cfunc_alpm_find_dbs_satisfier
/home/plyons/go/pkg/mod/github.com/!jguer/go-alpm/[email protected]/deps.go:38:78: cannot use _cgo0 (variable of type *_Ctype_struct___alpm_list_t) as *_Ctype_struct__alpm_list_t value in argument to _Cfunc_alpm_find_satisfier
/home/plyons/go/pkg/mod/github.com/!jguer/go-alpm/[email protected]/package.go:69:53: cannot use _cgo0 (variable of type *_Ctype_struct___alpm_list_t) as *_Ctype_struct__alpm_list_t value in argument to _Cfunc_alpm_list_count
/home/plyons/go/pkg/mod/github.com/!jguer/go-alpm/[email protected]/package.go:70:34: cannot use _cgo0 (variable of type *_Ctype_struct___alpm_list_t) as *_Ctype_struct__alpm_list_t value in argument to _Cfunc_alpm_list_msort
make: *** [Makefile:11: build] Error 1
==> ERROR: A failure occurred in prepare().
    Aborting...

Other Details

This only recently started happening with an arch system update.

@gal
Copy link
Collaborator

gal commented Mar 29, 2024

Works for me on latest master with go v1.22.1
Looks like it was an undisclosed dependency on debugedit for go-alpm

https://itsfoss.community/t/archlinux-problems-with-yay-after-system-upgrade/11818/9

@focusaurus
Copy link
Author

That forum seems to be entirely about issues with yay and libalpm. I have debugedit installed and can't get yup to compile. yay is installed and working OK for me currently. It seems the combination of libalpm14 and yup doesn't want to build on my system with go 1.22.1, but its unclear to me if yay has anything to do with this or not.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants