Archive of the libbitcoin Slack #general channel.
bx, I am trying to code some of the examples from mastering bitcoin and I'm unable to get anything to compile referencing libbitcoin there. I also installed libbitcoin from source and it fails on installing boost. I went through trying to install boost, multiple versions but I continue to get errors when trying to compile a file where I include <bitcoin/bitcoin.hpp>
Some errors for example:
undeclared identifier '_1'; did you mean 'placeholders::_1'?
Undefined symbols for architecture x86_64: "libbitcoin::config::checkpoint::check(edited)
libbitcoin beyond installing with homebrew, which seemed to worklibbitcoin-system I got this failure:
Building Boost.Build engine with toolset darwin... Failed to build Boost.Build build engine Consult 'bootstrap.log' for more details
bootstrap.log anywhere but I didn't use --prefix so I am trying with that. I'm also now realizing I'm not sure if I should be using libbitcoin-system or another package, that is the parent project, right?libbitcoin-system is the base project required by all others. if you want bx, you'll want libbitcoin-explorer - the install.sh from a downlevel project will install the required dependencies###
### Using 'darwin' toolset.
###
rm -rf bootstrap
mkdir bootstrap
cc -o bootstrap/jam0 command.c compile.c constants.c debug.c execcmd.c frames.c function.c glob.c hash.c hdrmacro.c headers.c jam.c jambase.c jamgram.c lists.c make.c make1.c object.c option.c output.c parse.c pathsys.c regexp.c rules.c scan.c search.c subst.c timestamp.c variable.c modules.c strings.c filesys.c builtins.c class.c cwd.c native.c md5.c w32_getreg.c modules/set.c modules/path.c modules/regex.c modules/property-set.c modules/sequence.c modules/order.c execunix.c fileunix.c pathunix.c
execcmd.c:120:5: error: implicit declaration of function 'out_printf' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
out_printf( "...interrupted\n" );
^
1 error generated.
make.c:132:13: error: implicit declaration of function 'out_printf' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
out_printf( "...found %d target%s...\n", counts->targets,
^
make.c:184:17: error: implicit declaration of function 'out_printf' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
out_printf( "fate change %s from %s to %s (as dependant of %s)\n",
^
make.c:215:17: error: implicit declaration of function 'out_printf' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
out_printf( "fate change %s from %s to %s (by rebuild)\n",
^
make.c:300:9: error: implicit declaration of function 'out_printf' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
out_printf( "make\t--\t%s%s\n", spaces( depth ), object_str( t->name ) );
^
make.c:300:41: warning: adding 'int' to a string does not append to the string [-Wstring-plus-int]
out_printf( "make\t--\t%s%s\n", spaces( depth ), object_str( t->name ) );
^~~~~~~~~~~~~~~
make.c:85:44: note: expanded from macro 'spaces'
#define spaces(x) ( " " + ( x > 20 ? 0 : 20-x ) )
~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~
make.c:300:41: note: use array indexing to silence this warning
make.c:85:44: note: expanded from macro 'spaces'
#define spaces(x) ( " " + ( x > 20 ? 0 : 20-x ) )
^
make.c:307:41: warning: adding 'int' to a string does not append to the string [-Wstring-plus-int]
out_printf( "make\t--\t%s%s\n", spaces( depth ), object_str( t->name ) );
^~~~~~~~~~~~~~~
make.c:85:44: note: expanded from macro 'spaces'
#define spaces(x) ( " " + ( x > 20 ? 0 : 20-x ) )
~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~
make.c:307:41: note: use array indexing to silence this warning
make.c:85:44: note: expanded from macro 'spaces'full filehonk at Honk-Mac in ~/src $ clang --version Apple clang version 12.0.0 (clang-1200.0.32.27) Target: x86_64-apple-darwin20.1.0 Thread model: posix InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin honk at Honk-Mac in ~/src $ clang++ --version Apple clang version 12.0.0 (clang-1200.0.32.27) Target: x86_64-apple-darwin20.1.0 Thread model: posix InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
Apple LLVM version 9.1.0 (clang-902.0.39.2) 75Target: x86_64-apple-darwin17.7.0