-
Notifications
You must be signed in to change notification settings - Fork 33
Description
I would like to use this library in conjunction with https://crates.io/crates/bdk
But when I uncomment the block starting on line 160 of https://github.com/ulrichard/bdk/blob/feature/proof_of_reserves/src/wallet/reserves.rs, I get a linker error. I never had a linker error in rust before.
DWARF error: could not find variable specification at offset 739b
bdk/target/debug/deps/libbitcoinconsensus-76f1899f601e64c9.rlib(pubkey.o): in function ecdsa_signature_parse_der_lax(secp256k1_context_struct const*, secp256k1_ecdsa_signature*, unsigned char const*, unsigned long)': .cargo/registry/src/github.com-1ecc6299db9ec823/bitcoinconsensus-0.17.1/bitcoin/src/pubkey.cpp:35: undefined reference to secp256k1_ecdsa_signature_parse_compact'
/usr/bin/ld: .cargo/registry/src/github.com-1ecc6299db9ec823/bitcoinconsensus-0.17.1/bitcoin/src/pubkey.cpp:164: undefined reference to secp256k1_ecdsa_signature_parse_compact' /usr/bin/ld: .cargo/registry/src/github.com-1ecc6299db9ec823/bitcoinconsensus-0.17.1/bitcoin/src/pubkey.cpp:158: undefined reference to secp256k1_ecdsa_signature_parse_compact'
/usr/bin/ld: bdk/target/debug/deps/libbitcoinconsensus-76f1899f601e64c9.rlib(pubkey.o): in function CPubKey::Verify(uint256 const&, std::vector<unsigned char, std::allocator<unsigned char> > const&) const': .cargo/registry/src/github.com-1ecc6299db9ec823/bitcoinconsensus-0.17.1/bitcoin/src/pubkey.cpp:174: undefined reference to secp256k1_ec_pubkey_parse'
/usr/bin/ld: .cargo/registry/src/github.com-1ecc6299db9ec823/bitcoinconsensus-0.17.1/bitcoin/src/pubkey.cpp:182: undefined reference to secp256k1_ecdsa_signature_normalize' /usr/bin/ld: .cargo/registry/src/github.com-1ecc6299db9ec823/bitcoinconsensus-0.17.1/bitcoin/src/pubkey.cpp:183: undefined reference to secp256k1_ecdsa_verify'
/usr/bin/ld: bdk/target/debug/deps/libbitcoinconsensus-76f1899f601e64c9.rlib(pubkey.o): in function CPubKey::CheckLowS(std::vector<unsigned char, std::allocator<unsigned char> > const&)': .cargo/registry/src/github.com-1ecc6299db9ec823/bitcoinconsensus-0.17.1/bitcoin/src/pubkey.cpp:279: undefined reference to secp256k1_ecdsa_signature_normalize'
/usr/bin/ld: bdk/target/debug/deps/libbitcoinconsensus-76f1899f601e64c9.rlib(pubkey.o): in function ECCVerifyHandle::ECCVerifyHandle()': .cargo/registry/src/github.com-1ecc6299db9ec823/bitcoinconsensus-0.17.1/bitcoin/src/pubkey.cpp:288: undefined reference to secp256k1_context_create'
/usr/bin/ld: bdk/target/debug/deps/libbitcoinconsensus-76f1899f601e64c9.rlib(pubkey.o): in function ECCVerifyHandle::~ECCVerifyHandle()': .cargo/registry/src/github.com-1ecc6299db9ec823/bitcoinconsensus-0.17.1/bitcoin/src/pubkey.cpp:299: undefined reference to secp256k1_context_destroy'
collect2: error: ld returned 1 exit status
If I try to use bitcoinconsensus = "0.19.0-2", I get the following:
error: failed to select a version for cc.
... required by package bitcoinconsensus v0.19.0-2
... which is depended on by bdk v0.5.2-dev (bdk)
versions that meet the requirements >=1.0.36, <=1.0.41 are: 1.0.41, 1.0.40, 1.0.39, 1.0.38, 1.0.37, 1.0.36
all possible versions conflict with previously selected packages.
previously selected package cc v1.0.64
... which is depended on by `bdk v0.5.2-dev
So what is the reason for requiring an older version of cc?