How to Edit one .cpp file and debug it each time without recompiling the whole library ? Topic is solved

Do you have a question about makefiles, a compiler or IDE you are using and need to know how to set it up for wxWidgets or why it doesn't compile but other IDE's do ? Post your questions here.
Post Reply
tomay3000
Filthy Rich wx Solver
Filthy Rich wx Solver
Posts: 207
Joined: Mon Apr 24, 2017 4:23 am

How to Edit one .cpp file and debug it each time without recompiling the whole library ?

Post by tomay3000 »

Hello,
is it possible to edit, for example lets say: src/msw/anybutton.cpp of my installed wxWidgets and try to fix bugs without the need of recompiling the whole library ? Because it takes forever to compile, and if it did compile I would not know if my fixes are correct.

BTW: I am using wxWidgets v3.1.1 and Code::Blocks latest svn with gcc version 7.3.0 (Rev2, Built by MSYS2 project) under Window 7 Professional 32 bit

Thank you for your understanding.
User avatar
doublemax
Moderator
Moderator
Posts: 19158
Joined: Fri Apr 21, 2006 8:03 pm
Location: $FCE2

Re: How to Edit one .cpp file and debug it each time without recompiling the whole library ?

Post by doublemax »

If only one .cpp file changed, the compiler should compile only that one file. Make sure that you don't run "make [...] clean" each time before you build.
Use the source, Luke!
tomay3000
Filthy Rich wx Solver
Filthy Rich wx Solver
Posts: 207
Joined: Mon Apr 24, 2017 4:23 am

Re: How to Edit one .cpp file and debug it each time without recompiling the whole library ?

Post by tomay3000 »

doublemax wrote:If only one .cpp file changed, the compiler should compile only that one file. Make sure that you don't run "make [...] clean" each time before you build.
OUCH! Just because I was afraid to recompile the whole library I did not try it.
Post Reply