#1 2022-07-18 07:55:34

Alek
Member
From: Russia
Registered: 2014-07-04
Posts: 44

The attribute "dPUREPASCAL" affects the compilation of the project

Hello.

I have found a problem when compiling an empty project mORMot 1.18 in Lazarus IDE 32 bit, on Windows 64bit, intel core. May be it is not an error, but "As designed". But it took me quite a while to find the cause of the error. And I would like others to be able to avoid such a situation.

It turned out by chance when I converted the empty Delphi project with unit SynCommons to Lazarus and selected(checked) the compatibility with Delphi7.
The IDE automatically added these parameters to "Custom Options:  -dBorland -dVer150 -dDelphi7 -dCompiler6_Up -dPUREPASCAL". The last attribute "-dPUREPASCAL" in these parameters leads to compilation errors

Build project the unit SynCommons I get 2 errors.

First of all, in a inplementation of function crc32cfast I see many errors like this:
SynCommons.pas(25067,17) Error: Unknown identifier "R8"
AFAIK R8 and R9 and so on, these are 64-bit registers, but I have IDE 32 bit.

And second, functions StrCompSSE42 and StrLenSSE42 is active in a declaration, but disable(gray colour, for a reason "defines") in an inplementation and consequently i see errors:
SynCommons.pas(2324,10) Error: Forward declaration not solved "StrCompSSE42(Pointer;Pointer):LongInt;" and
SynCommons.pas(2331,10) Error: Forward declaration not solved "StrLenSSE42(Pointer):LongInt;"


Is it necessary to describe this situation to users?

Last edited by Alek (2022-07-18 13:57:26)

Offline

#2 2022-07-18 08:31:22

ab
Administrator
From: France
Registered: 2010-06-21
Posts: 14,659
Website

Re: The attribute "dPUREPASCAL" affects the compilation of the project

PUREPASCAL is not to be called on Intel.
It is defined internally e.g. for ARM.

Why do you want to define it?

It was indeed something confusing, which is not existing any more in mORMot 2.

Offline

#3 2022-07-18 08:40:56

Alek
Member
From: Russia
Registered: 2014-07-04
Posts: 44

Re: The attribute "dPUREPASCAL" affects the compilation of the project

Thanks for the quick response.

I don't want to define. Simply, the IDE just did it (added custom options) automatically without my knowledge

Last edited by Alek (2022-07-18 13:53:09)

Offline

Board footer

Powered by FluxBB