Delphi Linux support for DWS
Issue #219
new
Initial commit for Linux support for Delphi.Notes:
- dwsXPlatform.pas - look my comments on line 42
- found no any usage of FileMemoryMapReadOnly in sources. NOWHERE! But anyway, made if multiplatform, using MMF access code from my main application source. If its needed no longer - maybe better to remove it?
- dwsRTTIConnector.pas - "Windows" removed from uses, no usage.
- no any tests for FPC.
for other platforms, like MacOS - will check&update in few weeks later.
Comments (2)
-
repo owner -
reporter For Posix.Syslog it’s part of FreePascal
its so strange - by compilation defines in dwsXPlatform.pas it will be linked ONLY in Delphi, not in FPC.
This will change when/if embarcadero makes a version available in community edition.
“if” is much more correct word. If i remember correctly, Emba many times tell about multiplatform available only in non-free editions.
commit with some changes according to this.
So right now Linux support is stuck between FPC incompatibility and Delphi compiler unavailability.
But i dont touch anything in FPC, only Delphi part.
- Log in to comment
For Posix.Syslog it’s part of FreePascal. I do not have access to a Delphi compiler that targets Linux, so most of the work in progress towards Linux support was actually for FreePascal. This will change when/if embarcadero makes a version available in community edition.
Memory mapped files are not used just yet in pushed code, they are used in experimental code for now. The GetFileSizeEx was meant to be a lightweight way to both check for existence and size, which FileExists + TFileStream isn't (a lot of the code in dwsXPlatform actually is there to avoid using TFileStream in the first place).
To run the tests under Lazarus you can just convert/open the dpr. I have not run them in years TBH, so they will likely fail horribly. The FreePascal/Lazarus work stalled on a lack of support for UnicodeString Variants in FPC, and FPC using utf-8 in their RTL rather than utf-16, which leads to a lot of corner case issues.
So right now Linux support is stuck between FPC incompatibility and Delphi compiler unavailability.