Can anyone at least confirm that Create refers to a build? Please.
function GetAppConfigDirUtf8(Global: Boolean; Create: boolean = false): string;
...
begin
...
if Create and not ForceDirectoriesUtf8(Result) then
raise EInOutError.Create(Format(lrsUnableToCreateConfigDirectoryS,[Result]));
end;
I am not sure what you mean by "a build", so my answer may be far off => the only build you do is your project. But the build itself does not run the code. I.e. the error does not happen when the code is executed, but when compiled.
The code is compiled regardless if that function will be used or called.
The code is compiled because,
- either: something in that packages (LazUtils / the units that are in that folder) is required
- or: you managed to include the unit in some other way
If the code were successfully compiled, and if it would then be executed, it would try to get a folder inside the systems config area. I.e. possible in
%PROFILESPATH%\All Users\Application Data or %USERPROFILE%\Local Settings\Application Data
It would try to get a folder with the app-name (and maybe vendor).
"CREATE" would mean if that folder does not exist, then that folder would be created.
But, it does not compile, it does not try to get the config folder, it does not try to create that folder....
"lrsUnableToCreateConfigDirectoryS" is a contstant.
Normally that code is compiled as part of the unit LazFileUtils, which contains "{$I winlazfileutils.inc}".
But...
- if it was compiled through this, it should not give that error. (and it did indeed not give that error when you rebuild the IDE)
- normally LazUtils should not need to be compiled. There can be reasons, but its suspicious.
So my suspicion is, that this file is referred to in some other way, and the compiler tries to compile it in a way it was not meant to.
But from the tiny snippet of errors shown on the screenshot, I can not tell what it is...
Try at least (context menu): Copy > Copy all/original messages
And the post the entire text of all those messages (or at least the last 300).