Code Monkey home page Code Monkey logo

Comments (15)

kaovilai avatar kaovilai commented on July 18, 2024 1

Gitpod gives you a Linux box that your ide can connect to.

from gpgme.

proglottis avatar proglottis commented on July 18, 2024 1

@sylvek @kaovilai thanks for investigating.

IIUC libassuan implements one of the protocols between gpg-agent and gpgme. This protocol is swappable, so it might be possible that your version has it compiled out.

I realised while you were removing things from LD_FLAGS that the reason it still works is probably because pkg-config is already setting these correctly. pkg-config is pretty new to this project #26

So I think the fix is just to remove LD_FLAGS entirely and leave it to pkg-config which should know how gpgme was configured.

I've raised an MR #35 - Before I merge, would you be able to test that it works? Thanks!

from gpgme.

kaovilai avatar kaovilai commented on July 18, 2024

My current workaround is https://gitpod.io/

from gpgme.

proglottis avatar proglottis commented on July 18, 2024

@sylvek It should work on macos though I've never used M1. I've even setup a macos workflow https://github.com/proglottis/gpgme/blob/master/.github/workflows/go.yml#L41

I wonder if your gpgme is unlinked or something? Sorry I can't be more specific as I don't have macos right now.

from gpgme.

kaovilai avatar kaovilai commented on July 18, 2024

Could try install libassuan as well but didn't work for me.

brew install gpgme libassuan

from gpgme.

sylvek avatar sylvek commented on July 18, 2024

My current workaround is https://gitpod.io/

Sorry @kaovilai i didn'yt understand what your link could help 🤔

from gpgme.

sylvek avatar sylvek commented on July 18, 2024

@proglottis is it possible that the issue is coming from the version of gnupg?

▶ brew info gnupg
gnupg: stable 2.3.6 (bottled)
GNU Pretty Good Privacy (PGP) package
https://gnupg.org/
/opt/homebrew/Cellar/gnupg/2.3.6 (149 files, 13.6MB) *
  Poured from bottle on 2022-04-27 at 16:41:13
From: https://github.com/Homebrew/homebrew-core/blob/HEAD/Formula/gnupg.rb
License: GPL-3.0-or-later
==> Dependencies
Build: pkg-config ✔
Required: gettext ✔, gnutls ✔, libassuan ✔, libgcrypt ✔, libgpg-error ✔, libksba ✔, libusb ✔, npth ✔, pinentry ✔
==> Analytics
install: 70,313 (30 days), 264,446 (90 days), 990,320 (365 days)
install-on-request: 66,918 (30 days), 249,849 (90 days), 931,477 (365 days)
build-error: 11 (30 days)
▶ brew info libassuan
libassuan
libassuan: stable 2.5.5 (bottled)
Assuan IPC Library
https://www.gnupg.org/related_software/libassuan/
/opt/homebrew/Cellar/libassuan/2.5.5 (17 files, 525.9KB) *
  Poured from bottle on 2021-04-06 at 21:24:23
From: https://github.com/Homebrew/homebrew-core/blob/HEAD/Formula/libassuan.rb
License: GPL-3.0-only
==> Dependencies
Required: libgpg-error ✔
==> Analytics
install: 30,825 (30 days), 90,514 (90 days), 424,130 (365 days)
install-on-request: 730 (30 days), 1,979 (90 days), 10,253 (365 days)
build-error: 0 (30 days)

from gpgme.

kaovilai avatar kaovilai commented on July 18, 2024

This might do something haven't tested yet. It's possible libassuan brew package currently doesn't install everything for aarch64.

https://www.wisdomgeek.com/development/installing-intel-based-packages-using-homebrew-on-the-m1-mac/#:~:text=Installing%20Homebrew%20on%20the%20M1%20mac%20was%20pretty,have%20a%20separate%20installation%20for%20the%20Rosetta%20emulator.

from gpgme.

kaovilai avatar kaovilai commented on July 18, 2024

Maybe if this line can remove -lassuan we'd be good.

// #cgo LDFLAGS: -lgpgme -lassuan -lgpg-error

from gpgme.

kaovilai avatar kaovilai commented on July 18, 2024

@sylvek I believe the issue is not on other libs but libassuan installation alone.

The homebrew recipe only checks that a binary exists and works.

  test do
    system bin/"libassuan-config", "--version"
  end

It doesn't check that header files are available for other programs.

https://github.com/Homebrew/homebrew-core/blob/b5637433c581c4fe4c9d0600c0e241aa63c3538a/Formula/libassuan.rb#L43-L45

from gpgme.

sylvek avatar sylvek commented on July 18, 2024

🤔 I removed -lassuan and -lgpg-error and it seems building.

// #cgo pkg-config: gpgme
// #cgo LDFLAGS: -lgpgme

I'll do more tests tomorrow.

from gpgme.

kaovilai avatar kaovilai commented on July 18, 2024

you can brew install libgpg-error so no need to remove that.

from gpgme.

kaovilai avatar kaovilai commented on July 18, 2024

@proglottis can you enlighten us why we need to link libassuan? can it be avoided?

from gpgme.

sylvek avatar sylvek commented on July 18, 2024

@proglottis i did a test, and everything worked as expected 👍

from gpgme.

proglottis avatar proglottis commented on July 18, 2024

Thanks all. I've cut a release with the fix https://github.com/proglottis/gpgme/releases/tag/v0.1.3

from gpgme.

Related Issues (12)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.