Page 1 of 1

Very slow build/compile

Posted: Sun Jan 09, 2022 1:39 pm
by DrBanana
Hi there,
I've been using RogerClark's core and the first build used to take a minute or half but after first build, it takes around 5 to 10 seconds. But with this new core, the first build is like 10 minutes and after first build, it takes 3 minutes each time.
So if I make a little change like update value of a numeric variable and now i have to wait 3 minutes for whole thing to finish building. Which is really really not good, could you please tell me is there any way I can make it faster ?

PS: I have no code, just empty sketch with empty loop() and setup() and using core version 2.0.0 and xpack-arm-none-eabi-gcc 9.3.1-1.3

Re: Very slow build/compile

Posted: Sun Jan 09, 2022 2:05 pm
by ag123
try different platforms like vscode, platform io etc.
https://github.com/stm32duino/wiki/wiki/How-to-debug

I used makefiles (unofficial - unsupported)
viewtopic.php?f=41&t=183

but they worked well enough for me.
I'm thinking of transiting to cmake https://cmake.org/, that is a *much* better setup for building with stm32duino.
if we try cmake as an alternative platform, compile time can drastically reduce to only that relevant to the particular series and board and modules.
the hard part is you'd need to create a cmakelist.txt for each new project, newbies will fluster over this.