GongYu wrote 11 lines
hello,I create a project,only write one line
procedure Tform.FormCreate1(sender:Tobject)
begin
caption:='aa';
end;
the execute file project1 size is 3.6m
when I use smartlink the size is 3.3m
why the file size is so big
Part is because Lazarus defaults to building with some debug code.
Check your compiler options under "linking" and uncheck "display line numbers" and check "Strip symbols from executable". I don't recommend this for testing, but for released software it helps.
Also, Lazarus apps fall under the same category as Delphi apps when it comes to this. Since there's very little external dependancy with Lazarus, much of the basic stuff is built into every windowing application. You can write a console app and it end up very small, but for a windowing application it will carry a little weight. Probably around a meg minimum...?
-Tony