As far as I know ERS C++ Builder 2010 comes with Boost libraries. During installation it will also install Boost libraries.
As new libraries will be realeased or modified(optimized), it gets me to upgrade to the latest version.
So i'm asking can i do this by replacing boost directory?
It's not as simple as updating the $(CG_BOOST_ROOT) directory with a new boost.
See this question previously asked on SO.
Someone could put the effort in, and it could be possible to run many of the latest boost libraries with bcc. (and hopefully submit those changes back to boost) That hasn't really happened yet.
However, even with a Herculean effort there are some constructs used by boost that bcc just doesn't handle yet, so there will be some boost libraries that won't be usable by bcc.
Related
Have recently become a great boost fan !!
But sometime components seem to be hidden.
eg I see example code on this site with:
#include <boost/network/uri.hpp>
etc
But my 1.55 boost install does not have a network folder.
What am I missing here?
Thanks in advance for any help
You are missing the fact that cpp-netlib is not an accepted Boost C++ Library (current Boost C++ Libraries). And further it's not even in the review schedule. So it's not going to be a Boost C++ Library for some time.
For those who may come down the same path ...
boost/network is not part of the standard boost release.
It is a candidate which may at some time become part of the boost distribution.
Sources/Docs etc for boost/network can be found at:
http://cpp-netlib.org/
Acknowledgement to GrafikRobot for pointing the way.
I would like to know if it is possible to get the binaries for the static library for windows (x86 and x64) now present in cpp-netlib for the version 0.9.1?
Frankly it is a pain to compile this on windows for me.
Thanks
New version's of cpp-netlib now do require building. I have answered how to build it on here
It seems that cpp-netlib is a header-only library, although it relies on some boost compiled libraries, such as Boost.System, Boost.Date_time, and Boost.Regex. You can easily find boost pre-compiled libraries all over the Internet. You will also need the boost headers to be in your build path as well. Even though cpp-netlib says that Boost 1.41.0 will do, in actuality, version 0.9.1 requires Boost version 1.46.0 or later (just grab the latest which is 1.47.0).
You could also try defining BOOST_NETWORK_NO_LIB which should help out.
im just installing the boost library using an installer.
Its asking me which variants (about 8 options, 6 multithreaded and 2 single threaded) do i want to install. Im only installing this to get to grips and have a practice with boost, so im unsure?
Also, how do i use the libraries from VS02010 once ive 'installed' them using the installer?
thank you in advance
Boost documentation is your friend. A read of the information on getting started on Windows would save you much time.
Most of the libraries are header-only. You can use these just by including the correct headers as described in the individual library docs. If you want to use any of the ones that are not, you are going to need either to build your own libraries, or install the ones that come prebuilt. This is what your question pertains to. So you really must answer your own question - what is your target platform, and do you have to support multi-threaded programming? if in doubt, install them all and use the ones you need on a case-by-case basis.
To use the Boost libs once you have installed or built them, just include the relevant library in your project Linker options as for any other static library.
I made a small program with Boost in Linux 2 yrs ago. Now I want to make it work in Windows. I found there are few .a files in my libs folder. I am wondering how to make it works in Windows? do I need to build Boost in Windows to get library or I can download somewhere? I am using Visual Studio 6.
Yes, you'll need to recompile for different platforms. Coincidentally, I posted instructions on this not long ago.
I hugely recommend you do not use Visual Studio 6. It's very dated, and terribly non-conforming. You can get the newer versions for free, as Express. You won't be missing anything.
Many boost libraries are header-only, you don't need to link against anything to use them. Libraries such as boost::filesystem require you to build libs appropriate for your platform and link against them.
Precompiled boost for MSVC7,8,9 can be found here (in the hope that you follow GMan's advice and get rid of VS6 …)
.a files from Unix are like .lib files in Windows. They will not work, and there is no way of "converting" them, short of using a compiler on the original source code.
However, Boost does build on Windows. Just download it (or more likely, the closest version you can find to the one your code was using).
Older versions of Boost did work under VS6, but with a whole lot of stuff disabled (VS6 really just barely qualified as a C++ compiler). If you can, I highly suggest you use a newer version of Visual Studio.
You have a few options. Building Boost will give you the greatest flexibility in working with your application and boost libraries. However, you can download pre-built Boost libraries wrapped up in a nice windows installer here, Boost Packages
But one thing to keep in mind, depending on what you used in Boost, a lot of it is template based so no libraries are required. If you're only using some templatized portions, you don't need to worry about any of this. Just make sure you have boost in your include path when building.
As a side note, you can get free but limited versions of newer MS compilers here: http ://www.microsoft.com/exPress/
Is Boost the only way for VS2005 users experience TR2? Also is there a idiot proof way of downloading only the TR2 related packages?
I was looking at the boost installer provided by BoostPro Consulting. If I select the options for all the threading options with all the packages for MSVC8 it requires 1.1GB. While I am not short of space, it seems ridiculous that a library needs over a gigabyte of space and it takes BPC a long time to catch up with the current release.
What packages do I need? I'm really only interested in those that comprise std::tr2 and can find that out by comparing those on offer to those in from the TR2 report and selecting those from the list but even then it isn't clear what is needed and the fact that it is a version behind annoys me.
I know from previous encounters with Boost (1.33.1) that self compiling is a miserable experience: A lot of time wasted to get it started and then a hoard of errors passes across your screen faster than you can read, so what you are left with is an uneasy feeling that something is broken but you don't quite know what.
I've never had these problems with any Apache library but that is another rant...
I believe you're actually referring to TR1, rather than TR2. The call for proposals for TR2 is open, but don't expect to see much movement until the new C++ standard is out. Also, although boost is a provider of an implementation of TR1, dinkumware and the GNU FSF are other providers - on VC2005 boost is probably the easiest way to access this functionality.
The libraries from boost which are likely to be of most importance are
reference
smart pointer
bind
type traits
array
regular expressions
The documentation for building boost has been gradually improving for the last few releases, the current getting started guide is quite detailed. smart pointer and bind, should work from header files, and IMO, these are the most useful elements of TR1.
Part of the beauty of Boost is that all code is in header files. They have to for template reasons. So probably downloading the code and including it in your project will work. There are some libraries in Boost that do need compiling, but as long as you don't need those...
The libraries I am most interested in from TR1/TR2 are threads and the related atomics.
Compiling the boost libraries for yourself is actually quite simple, if not that well documented. The documentation is in the jamroot file. Run bjam --help in the boost root directory for a detailed list of options. As an example I used the following command line to build my current set up with boost 1.36.0:
bjam --build-type=complete --toolset=msvc --build-dir=c:\boost\build install
It ran for about a half hour on my machine and put the resulting files into c:\boost