"Debug" in Quickstart panel always results in rebuilding already builded Project

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

"Debug" in Quickstart panel always results in rebuilding already builded Project

2,263 Views
Emin
Contributor III

When I press "Debug" in quickstart panel, it always starts from the building before doing debugging. Additionally, when I reopen my workspace and press "debug", again it will start building. How can I use "debug" without building an already builded project, and how can I make sure that when I make a change in a certain file, only that file is built (not the whole project)?

0 Kudos
Reply
7 Replies

2,248 Views
ErichStyger
Specialist I

First, you can disable the build before launching, see https://mcuoneclipse.com/2020/07/17/eclipse-gems-tips-tricks-faster-debugger-start/

If your project always builds even if you don't have changed anything, then you probably have copied your project and did not change the 'refresh policy' setting, see https://mcuoneclipse.com/2015/06/06/eclipse-project-refresh-policy-broken-incremental-build-with-ext...

 

I hope this helps,

Erich

0 Kudos
Reply

2,240 Views
Emin
Contributor III

It partially solved the problem I had when I debug the project, now it builds only the files I changed and debugs. However, when I close and reopen the ide and press debug, it will automatically starts from the building(i did not unpick the option of build(if required) since I would like to see build on those files which I changed) even if i totally builded and run debug from previos session.

I would like to see building inside debug when I make changes on certain files and building should be done on those files then running debug. Additionally, when I reopen the ide and run the debug, I do not want to have the build process(unless I make changes) before debug, since I have not changed anything.

0 Kudos
Reply

2,227 Views
lpcxpresso_supp
NXP Employee
NXP Employee

The IDE uses incremental builds whenever required. For disabling incremental builds when initiating a debug session, you have the option to disable this in the launch configuration.

lpcxpresso_supp_0-1680192296308.png

Regards,
MCUXpresso IDE Support

0 Kudos
Reply

2,185 Views
ErichStyger
Specialist I

Hi @lpcxpresso_supp ,

I think the point of @Emin is missed here.

Yes, the setting below (if disabled in the workspace settings or disabled in the launch), prevents a 'build-before-debug'):

ErichStyger_0-1680414440534.png

But the main point (which I can confirm is): whenever you start/restart the 11.7.0 IDE and load a workspace, it will perform a full build of the project, even if nothing has been changed.

Steps to reproduce:

1. open a workspace and build a project

2. close the IDE and re-open that project. Do a build again (e.g. with Project > Build)

3. Issue: the IDE will compile all files of that project again as seen in the console output. Expected: not all files are compiled again, only the ones which would have changed.

 

I wondering what is causing this, and how to prevent this?

 

Erich

0 Kudos
Reply

2,154 Views
Emin
Contributor III

You are indeed correct @ErichStyger. That's what I meant as an issue in the reply.

@lpcxpresso_supp, do you know how to solve this issue?

 

0 Kudos
Reply

2,136 Views
lpcxpresso_supp
NXP Employee
NXP Employee

My understanding - based on your comments - was that the build process was always initiated. This is perfectly normal given that incremental builds are used. However, if you're now saying that project is always rebuilt (i.e. clean and build), this needs investigation. We'll look into this. Thanks.

Regards,
MCUXpresso IDE Support

0 Kudos
Reply

2,133 Views
ErichStyger
Specialist I

The projects are always built if you exit the workspace and re-open it again.

Steps:

- build a project

- observation: 'nothing to build for ....' in the console

- restart the IDE with the same workspace

- build the project again

- expected: 'nothing to build for ....' in the console

- issue: full build of the project again

It looks like in the above case the build does a 'clean' first and then the build. Somehow this is only the case of your re-open the workspace.

 

0 Kudos
Reply