Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

create boost tool executable

I want to know how to create a tool executable, for example bcp, with the boost libraries. I have unzip the sources, but I do not know how to build to create the tool.

Thanks

like image 444
david Avatar asked Jan 28 '11 17:01

david


People also ask

Can I build Boost with CMake?

That infrastructure does warn in their README that building Boost with CMake does not work yet and is not supported .

Is Boost included in C++?

Boost is a set of libraries for the C++ programming language that provides support for tasks and structures such as linear algebra, pseudorandom number generation, multithreading, image processing, regular expressions, and unit testing. It contains 164 individual libraries (as of version 1.76).

Is Boost free C++?

Welcome to Boost.org!Boost provides free peer-reviewed portable C++ source libraries. We emphasize libraries that work well with the C++ Standard Library. Boost libraries are intended to be widely useful, and usable across a broad spectrum of applications.


2 Answers

Complementing hkaiser answer:

Run ./bootstrap.sh from $BOOST_ROOT (refer to Getting Started for additional options)

./bootstrap.sh

This will generate the a ./bjam executable. You may then do

./bjam tools/bcp

Or even copy this executable to tools/bcp and do

./bjam 

The ./bcp executable will be in $BOOST_ROOT/dist/bin

like image 61
kunigami Avatar answered Sep 21 '22 14:09

kunigami


All tools in the directory $BOOST_ROOT/tools can be build by invoking bjam from the directory where the corresponding Jamfile[.v2] is located. For bcp this needs to be done in the directory $BOOST_ROOT/tools/bcp. If you have not built bjam yet, please refer to the Getting Started document explaining the necessary steps. The built executable by default will end up in $BOOST_ROOT/dist/bin.

like image 36
hkaiser Avatar answered Sep 21 '22 14:09

hkaiser