I'm doing a command line build with KDS. I followed Erich Styger's guide and I was able to get it to build. However, I need it to do a "clean" build. I found the -cleanBuild option but it does a "clean" followed by a "build". Is there a way to make it just do a clean without building?
Hi Mike,
there are only a few options if you run the build with Eclipse on the command line (see https://mcuoneclipse.com/2014/09/12/building-projects-with-eclipse-from-the-command-line/ ).
After the make files have been created, you could run the normal make. See the makefile inside the output (Debug) folder which has the following target:
# Other Targets
clean:
-$(RM) $(SECONDARY_SIZE)$(OBJS)$(C_DEPS)$(ASM_DEPS)$(SECONDARY_FLASH)$(S_UPPER_DEPS) FRDM-K64F_Demo.elf
-@echo ' '
so you could call it with
make -f makefile clean
Erich
I'm gonna plead ignorance so forgive me if I sound dumb.
If I go to my Build Configuration directory and type 'make clean', it only deletes the .elf file, not the object files. If I go to KDS and do a 'clean', I see in the console that it deletes the .elf file AND the objects. Not sure what's going on there.
My goal is to build the project from the command line. To do that, I used the command from your guide and it works great. But I can't get it to do a 'clean' only. To build, I used the build command below:
"c:\My Program Files\freescale\kds_3.0.0\eclipse\eclipsec.exe" -nosplash -application org.eclipse.cdt.managedbuilder.core.headlessbuild -data "..\..\..\KDS Workspaces" -build ATS_ANN_App --launcher.ini "c:\My Program files\Freescale\KDS_3.0.0\eclipse\kinetis-design-studio.ini" --launcher.suppressErrors
I changed -build to -clean, it didn't like that at all. I changed it to -cleanBuild and it does a clean then a build. Is there a way to make the above command line do a 'clean' only?
call the make file with the clean target:
make clean
This is equivalent to
Erich
PS: articles on that subject:
https://mcuoneclipse.com/2016/05/26/build-and-clean-selected-files-in-eclipse-cdt/
https://mcuoneclipse.com/2012/02/13/make-my-make-with-eclipse-and-mcu10/
Hello MIKE,
How about the -clean command ?
For Erich have so many guides , could you please tell me which one do you used ?
BR
Alice