Box2D Forums

It is currently Mon May 20, 2013 3:12 pm

All times are UTC - 8 hours [ DST ]




Post new topic Reply to topic  [ 4 posts ] 
Author Message
 Post subject: How to build box2d_d.lib
PostPosted: Thu Feb 09, 2012 3:38 pm 
Offline

Joined: Thu Feb 09, 2012 3:31 pm
Posts: 3
Hi there,

I feel really dumb for asking this but I just can't seem to get there. I'm trying to get the little packaged project for Marmalade SDK given by a forum user over there (find it here). When I try to build it, the compiler requires Box2d_d.lib for the debug build.

I've grabbed Box2d 2.2.0 which is the same version as the one used in the marmalade package. I have created the VC10 files with CMake and I can build and run the testbed fine. But can I get it to output the '_d' version of the .lib!? Nope.

I've tried just using Box2d.lib with the debug build for the marmalade package, but I just get linker errors. Am I being totally dumb about getting box2d_d.lib or what?

Any help much appreciated.


Top
 Profile  
 
PostPosted: Fri Feb 10, 2012 3:30 am 
Offline

Joined: Tue Jun 24, 2008 8:25 pm
Posts: 1515
Location: Tokyo
(Just a stab in the dark...)
Run CMake again with the parameter -DCMAKE_BUILD_TYPE=Debug

Although this may not put a '_d' in the name, it should build a debug lib. You can tell by the size of the file if it is debug or release. The setting above is a 'sticky' setting so to build the release version again use 'Release'.


Top
 Profile  
 
PostPosted: Fri Feb 10, 2012 5:20 am 
Offline

Joined: Thu Feb 09, 2012 3:31 pm
Posts: 3
Forgive my ignorance here but are you suggesting that CMake should give the the .lib file directly? Or rather that using the parameter you suggested, I will get VS files that might then lead to building the '_d.lib' flavour I need?

At work now, so going to have to try your idea at home.

Edit:Managed to try it during my lunch. I just get the following message after it has done all it's stuff:

Quote:
Manually-specified variables were not used by the project:

CMAKE_BUILD_TYPE


Perhaps I'm misunderstanding something here. When building in debug say the 'HelloWorld' box2d example, does it output a debug library? It must do right?


Top
 Profile  
 
PostPosted: Mon Feb 13, 2012 6:18 am 
Offline

Joined: Thu Feb 09, 2012 3:31 pm
Posts: 3
SOLVED.

Thanks to all those that took a look, but as it turns out I needed to create all the libs needed by opening the .mkb file given as part of the download and build the libs from there.

After that you can just use the library .mkb file to include Box2d in your Marmalade project. See discussion here.

I was being a little dumb, but just in case anyone in the future come across a similar problem.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 4 posts ] 

All times are UTC - 8 hours [ DST ]


Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Group