I have the same issue with Kaspersky, but instead of adding every file I compile, I just added my entire Projects folder to the exclusions list - way faster!
Go: Settings > Advanced Settings > Threats and Exclusions > Exclusions > Settings, and click "Add". In the new window, click ""select Object", enter the root of your projects/Lazarus folder (wherever you save your files) - make sure the "include sub-folders" box is ticked, and click OK.
Leave the "Threats Type" box un-ticked, and click OK again - your folder should now be in the list of excluded items. This is the fastest way to get Kaspersky off your back for when you recompile.
Sure the initial launch on your end users machine will be slow as well (for pretty much any AV), but every time after that will be very fast. Not that I'm an expert, but I figure it has to do with the heuristic analysis of the AV engine. Once it scanned a file and knows its clean it doesn't bother again - and since you don't distribute every build to the end users it shouldn't be a problem...
This way you don't really mess with the operation of the AV when it comes to protecting the rest of your system, and you also get the compiling speed you want.
