Author Topic: boost_1_47_0 with default Codeblocks compiler  (Read 8623 times)

12oclocker

  • Guest
boost_1_47_0 with default Codeblocks compiler
« on: October 31, 2011, 05:13:14 am »
I'm trying to setup boost_1_47_0 so I can use asio.
I have read the CodeBlocks tutorial (looks to be outdated and some things must have obviously changed), and read the boost install info, still no luck.
I should also mention, I have avrstudio4 installed, and for some reason that seems to cause problems with me doing command line builds.

I run "bootstrap.bat" and see this error, I don't know what to do about it, I have already changed.... set toolset=gcc  ...inside of the bat file.
Please if you know the answer explain to me as you would explain something to a stupid person.
it's calling cl.exe, even though I specified gcc, I thought cl.exe was a microsoft cmd line compiler tool.

Quote
D:\C++\Compilers\boost_1_47_0>bootstrap.bat
Building Boost.Build engine
'cl' is not recognized as an internal or external command,
operable program or batch file.

Failed to build Boost.Build engine.
Please consult bootstrap.log for furter diagnostics.

You can try to obtain a prebuilt binary from

   http://sf.net/project/showfiles.php?group_id=7586&package_id=72941

Also, you can file an issue at http://svn.boost.org
Please attach bootstrap.log in that case.

the log file....
Quote
###
### Using 'msvc' toolset.
###

D:\C++\Compilers\boost_1_47_0\tools\build\v2\engine>if exist bootstrap rd /S /Q bootstrap

D:\C++\Compilers\boost_1_47_0\tools\build\v2\engine>md bootstrap

D:\C++\Compilers\boost_1_47_0\tools\build\v2\engine>cl /nologo /GZ /Zi /MLd /Fobootstrap/ /Fdbootstrap/ -DNT -DYYDEBUG kernel32.lib advapi32.lib user32.lib /Febootstrap\jam0  command.c compile.c debug.c execnt.c expand.c filent.c glob.c hash.c hdrmacro.c headers.c jam.c jambase.c jamgram.c lists.c make.c make1.c newstr.c option.c output.c parse.c pathunix.c regexp.c rules.c scan.c search.c subst.c timestamp.c variable.c modules.c strings.c filesys.c builtins.c md5.c pwd.c class.c w32_getreg.c native.c modules/set.c modules/path.c modules/regex.c modules/property-set.c modules/sequence.c modules/order.c

« Last Edit: October 31, 2011, 05:18:18 am by 12oclocker »

12oclocker

  • Guest
Re: boost_1_47_0 with default Codeblocks compiler
« Reply #1 on: October 31, 2011, 05:30:12 am »
After a ton of goggling, I found this link... http://stackoverflow.com/questions/5299468/unable-to-build-boost-libraries-with-gcc
I'm now making a little progress, so far this is what I have done, and it looks like it is building everything.....

Quote
//open command line as administrator

//at command navigate to this directory
boost_1_47_0\tools\build\v2\engine

//now type...
build.bat mingw

//it will compile a couple exe files into a subfolder called "bin.ntx86"
//now copy these files back to the root directory of "boost_1_47_0"

//now navigate your command line back to the root directory of "boost_1_47_0", and type
bjam toolset=gcc --build-type=complete stage


...update: so the lib's are built, and I included them correctly (we at least I think I did)
if I tried to include... #include <boost/asio.hpp>
I get this error....
Quote
undefined reference to `boost::system::generic_category()'


...update2: got it working, had mispelled "libboost_system-mgw44-mt-s-1_47.a" I guess, I just coped and pasted the filename into linker, and works now ;-)
« Last Edit: October 31, 2011, 07:32:04 am by 12oclocker »