Skip to content

Does tested_libversions need updating? #4

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

Closed
MrNaif2018 opened this issue Nov 16, 2024 · 4 comments · Fixed by #5
Closed

Does tested_libversions need updating? #4

MrNaif2018 opened this issue Nov 16, 2024 · 4 comments · Fixed by #5

Comments

@MrNaif2018
Copy link

MrNaif2018 commented Nov 16, 2024

Hi! I'm trying to launch electrum from source on macos, and it can't find libsecp256k1
When I do brew install secp256k1, it installs the recent libsecp256k1 0.6.0 released two weeks ago: https://github.com/bitcoin-core/secp256k1/releases/tag/v0.6.0
So inside the folder, I see libsecp256k1.5.dylib
But tested versions are up to 2 only.
See

tested_libversions = [2, 1, 0, ] # try latest version first

When on ubuntu, I usually just run
sudo apt install libsecp256k1-dev
And because of ubuntu slow rollover of packages I guess, the max version I would get is the number 2
Can this list be updated? Is it like, to prevent breaking ABI changes? Or any blocker in recent libsecp which prevents it from using?
Because when I manually added tested versions it does start at least (:

Hmm but also, I tried compiling the 0.5.1 version, and it has ABI version of 2. So I'm not sure, maybe it's their bug that they jumped 3 versions at once?

EDIT: just tested on linux, and it's also a jump of 3 versions there

@SomberNight
Copy link
Member

They only bump the ABI version when they make an incompatible change to it. So 0.3.x, 0.4.x, and 0.5.x all used version 2. Now there was a change in 0.6.0, so the ABI version got bumped to 5.
See the changelog re "ABI Compatibility".

The versions themselves are calculated in a somewhat weird way, see bitcoin-core/secp256k1#1055 (comment)

@Midar
Copy link

Midar commented Mar 30, 2025

This just hit Fedora 42, breaking Electrum there. Do I see it right that at least for what libsecp256k1 is used, just adding 5 to tested versions is fine? I might just patch it in Fedora then to unbreak Electrum.

@SomberNight
Copy link
Member

Yes, abi versions 2 and 5 do not differ as far as electrum-ecc is concerned.

Instead of patching, you could also update electrum-ecc to 0.0.4. Or maybe I misunderstand -- how exactly do you install libsecp / electrum-ecc / electrum? Note that the latest release of electrum still does not use this library, only the master branch does.

Ahh actually that's probably what is going on then -- you mean patching https://github.com/spesmilo/electrum/blob/657199155526b825735dcd3e11aeb8179d5a91de/electrum/ecc_fast.py#L42

@Midar
Copy link

Midar commented Apr 3, 2025

Yes, that's what I mean :). Thanks, that was how it looked to me, too. I pushed the updated / fixed package to Fedora 42.

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

Successfully merging a pull request may close this issue.

3 participants