Forum > FPC development

RTL rebuild optimization

(1/2) > >>

avra:
I have used fpcupdeluxe to download trunks of FPC and LAZ into c:/Prg/Lazarus/TrunkAll.

For testing purpose I have made a small RTL change to sysutils.pp and used these to recompile RTL:

--- Quote ---c:\Prg\Lazarus\TrunkAll\fpcsrc> c:\Prg\Lazarus\fpc.3.2.2\bin\i386-win32\make.exe clean distclean
c:\Prg\Lazarus\TrunkAll\fpcsrc> c:\Prg\Lazarus\fpc.3.2.2\bin\i386-win32\make.exe all
c:\Prg\Lazarus\TrunkAll\fpcsrc> c:\Prg\Lazarus\fpc.3.2.2\bin\i386-win32\make.exe install INSTALL_PREFIX=c:\Prg\Lazarus\TrunkAll\fpc
--- End quote ---

My test project which uses that small RTL change compiles from both command line and Lazarus, and Lazarus can rebuild (if needed) without problems. Everything works fine but takes time.

The question is (since I am going to do this a lot), is there a way to speed this up? Is it safe to avoid make clean distclean, and do I really need full make all? I will only change several sub files of sysutils.

marcov:
Only if your programs don't depend on units that depend on sysutils.

I do this a lot when debugging package chm, just recompile and move it over the old units. But few units depend on units in package CHM (only lhelp, but that can be kept as exe without recompilation).

So in short: yes, you can, but for a core unit as sysutils this is pretty useless.

avra:

--- Quote from: marcov on July 13, 2021, 01:52:28 pm ---So in short: yes, you can, but for a core unit as sysutils this is pretty useless.
--- End quote ---
I was afraid that would be the case.

Thanks!

Jonas Maebe:
You can just use distclean, it already includes clean.

You can add the following options to make to speed it up: -j X FPMAKEOPT="-T X", with X = the number of parallel processes to use

avra:

--- Quote from: Jonas Maebe on July 13, 2021, 06:49:48 pm ---You can just use distclean, it already includes clean.
--- End quote ---
Thanks!


--- Quote from: Jonas Maebe on July 13, 2021, 06:49:48 pm ---You can add the following options to make to speed it up: -j X FPMAKEOPT="-T X", with X = the number of parallel processes to use
--- End quote ---
You nailed it. That was going to be my next search/question, but didn't have a chance with such mind reading devs.  :D 8-) :D

Navigation

[0] Message Index

[#] Next page

Go to full version