Go Back   Rhinocerus > Newsgroup > Newsgroup comp.language.c++

Reply
 
Thread Tools Display Modes
  #1 (permalink)  
Old 06-11-2012, 09:26 PM
woodbrian77@gmail.com
Guest
 
Posts: n/a
Default OT: VS 11 build problem


I'm in the process of updating this page --
http://webEbenezer.net/comparison.html -- that compares
the performance between the serialization library in Boost
with results from the C++ Middleware Writer.

I've updated the Linux results already, but am having a
problem getting a test case to build on Windows 7. Previously
with VS 10 I used:

cl -O2 -I /Users/Store/boost_1_50_0_beta1/ -EHsc bser.cc /link /nodefaultlib:msvcprt /nodefaultlib:libcmt libboost_serialization-vc110-1_50.lib

The version of Boost was an earlier one, but other than that
the command is the same. When I use that command with
VS 11 I get errors like this:

libboost_serialization-vc110-1_50.lib(basic_archive.obj) : error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MD_DynamicRelease' doesn't match value 'MT_StaticRelease' in bser.obj

I built the serialization library in Boost with this command:
bjam variant=release link=static

Any ideas on how to resolve this? Tia.
Reply With Quote
Alt Today
Advertising
 
and become member of Rhinocerus
Standard Sponsored Links

  #2 (permalink)  
Old 06-11-2012, 10:55 PM
Geoff
Guest
 
Posts: n/a
Default Re: OT: VS 11 build problem

On Mon, 11 Jun 2012 14:26:24 -0700 (PDT), woodbrian77@gmail.com wrote:

>
>I'm in the process of updating this page --
>http://webEbenezer.net/comparison.html -- that compares
>the performance between the serialization library in Boost
>with results from the C++ Middleware Writer.
>
>I've updated the Linux results already, but am having a
>problem getting a test case to build on Windows 7. Previously
>with VS 10 I used:
>
>cl -O2 -I /Users/Store/boost_1_50_0_beta1/ -EHsc bser.cc /link /nodefaultlib:msvcprt /nodefaultlib:libcmt libboost_serialization-vc110-1_50.lib
>
>The version of Boost was an earlier one, but other than that
>the command is the same. When I use that command with
>VS 11 I get errors like this:
>
>libboost_serialization-vc110-1_50.lib(basic_archive.obj) : error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MD_DynamicRelease' doesn't match value 'MT_StaticRelease' in bser.obj
>
>I built the serialization library in Boost with this command:
>bjam variant=release link=static
>
>Any ideas on how to resolve this? Tia.


You have built the library as statically linked (/MT switch) and you
built the application as dynamically linked (/MD). Change the project
settings.
Reply With Quote
  #3 (permalink)  
Old 06-12-2012, 07:47 PM
woodbrian77@gmail.com
Guest
 
Posts: n/a
Default Re: OT: VS 11 build problem

On Monday, June 11, 2012 6:55:01 PM UTC-4, Geoff wrote:
>
> You have built the library as statically linked (/MT switch) and you
> built the application as dynamically linked (/MD).


I tried adding MT when building the application like this:

cl -MT -O2 -I /Users/Store/boost_1_50_0_beta1/ -EHsc bser.cc /link /nodefaultlib:msvcprt /nodefaultlib:libcmt libboost_serialization-vc110-1_50.lib

But that didn't seem to help -- I still got the same errors.

> Change the project
> settings.


I'm not using an IDE.


Brian
Ebenezer Enterprises
http://webEbenezer.net
Reply With Quote
  #4 (permalink)  
Old 06-13-2012, 03:01 PM
A. W. Dunstan
Guest
 
Posts: n/a
Default Re: OT: VS 11 build problem

By any chance are you mixing debug and release versions of libraries in a
single build? I ran into a similar problem when moving from VS2008 to
VS2010. I'd been mixing debug & release all along but didn't know it (and
it didn't matter, apparently) until I moved to VS2010.


woodbrian77@gmail.com wrote:

> On Monday, June 11, 2012 6:55:01 PM UTC-4, Geoff wrote:
>>
>> You have built the library as statically linked (/MT switch) and you
>> built the application as dynamically linked (/MD).

>
> I tried adding MT when building the application like this:
>
> cl -MT -O2 -I /Users/Store/boost_1_50_0_beta1/ -EHsc bser.cc /link
> /nodefaultlib:msvcprt /nodefaultlib:libcmt
> libboost_serialization-vc110-1_50.lib
>
> But that didn't seem to help -- I still got the same errors.
>
>> Change the project
>> settings.

>
> I'm not using an IDE.
>
>
> Brian
> Ebenezer Enterprises
> http://webEbenezer.net


--
Al Dunstan, Software Engineer
OptiMetrics, Inc.
3115 Professional Drive
Ann Arbor, MI 48104-5131

"There are two ways of constructing a software design. One way is to
make it so simple that there are obviously no deficiencies. And the
other way is to make it so complicated that there are no obvious
deficiencies."
- C. A. R. Hoare
Reply With Quote
  #5 (permalink)  
Old 06-21-2012, 05:42 PM
woodbrian77@gmail.com
Guest
 
Posts: n/a
Default Re: OT: VS 11 build problem

On Wednesday, June 13, 2012 11:01:51 AM UTC-4, A. W. Dunstan wrote:
> By any chance are you mixing debug and release versions of libraries in a
> single build? I ran into a similar problem when moving from VS2008 to
> VS2010. I'd been mixing debug & release all along but didn't know it (and
> it didn't matter, apparently) until I moved to VS2010.
>


I'm not sure how to tell.
Reply With Quote
 
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off




All times are GMT. The time now is 02:56 AM.


Copyright ©2009

LinkBacks Enabled by vBSEO 3.3.0 RC2 © 2009, Crawlability, Inc.