chia-blockchain/lib/bip158
Yostra 5115577da2 expose api to bip158 binding 2020-02-24 10:24:54 -08:00
..
lib/pybind11 Remove submodules 2019-11-20 00:03:34 +02:00
python-bindings expose api to bip158 binding 2020-02-24 10:24:54 -08:00
src reorg python bindings. copyright 2019-07-28 18:05:07 -07:00
CMakeLists.txt build bip158 2020-02-24 10:24:54 -08:00
README.md installed by brew 2019-09-10 15:46:46 -07:00
main.cpp pybind and cmake support 2019-07-27 11:20:10 -07:00
setup.py pybind and cmake support 2019-07-27 11:20:10 -07:00

README.md

BIP158

This implements the compact block filter construction in BIP 158. The code is not used anywhere in the Bitcoin Core code base yet. The next step towards BIP 157 support would be to create an indexing module similar to TxIndex that constructs the basic and extended filters for each validated block.

Install

git submodule update --init --recursive
python3 -m venv env
. env/bin/activate
pip3 install .

Run python tests

python3 python-bindings/test.py

Installation steps on a fresh OSX image

Install brew:

ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

brew install python3
brew install cmake
brew install boost
brew install openssl

At this point the only error is cant find boost_thread lib

The issue is the homebrew boost ships libboost_thread-mt libs but doesnt include plain libboost_thread, so clang cant find it. Interestingly, homebrew boost does have both plain and -mt files for the libboost_system libraries.

$ find /usr/local/lib/ | grep boost_thread
libboost_thread-mt.a
libboost_thread-mt.dylib

Solution, with no guarantees that this is “the Right Way to do things”, but appears to work fine for the configure stage:

$ cd /usr/local/lib
$ ln -s libboost_thread-mt.a libboost_thread.a
$ ln -s libboost_thread-mt.dylib libboost_thread.dylib