From 9d26ff9bf79fba207d0d071e2b5adbb4ad756c58 Mon Sep 17 00:00:00 2001 From: Marian Minar Date: Tue, 18 Feb 2020 16:13:26 +0100 Subject: [PATCH] DoOpenDll fix for FPC --- PythonForDelphi/Components/Sources/Core/PythonEngine.pas | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/PythonForDelphi/Components/Sources/Core/PythonEngine.pas b/PythonForDelphi/Components/Sources/Core/PythonEngine.pas index 5264b533..c30d8501 100644 --- a/PythonForDelphi/Components/Sources/Core/PythonEngine.pas +++ b/PythonForDelphi/Components/Sources/Core/PythonEngine.pas @@ -3135,9 +3135,9 @@ implementation AnsiStrings, {$ENDIF} {$IFDEF MSWINDOWS} - Math, - Registry; + Registry, {$ENDIF} + Math; (*******************************************************) @@ -3308,7 +3308,7 @@ procedure TPythonInputOutput.UpdateCurrentThreadLine; (** **) (*******************************************************) -procedure TDynamicDll.DoOpenDll(const aDllName : string); +procedure TDynamicDll.DoOpenDll(const aDllName : String); begin if not IsHandleValid then begin @@ -3323,7 +3323,7 @@ procedure TDynamicDll.DoOpenDll(const aDllName : string); {$ELSE} //Linux: need here RTLD_GLOBAL, so Python can do "import ctypes" FDLLHandle := THandle(dlopen(PAnsiChar(AnsiString(GetDllPath+DllName)), - RTLD_LAZY+RTLD_GLOBAL)); + RTLD_LAZY+RTLD_GLOBAL) {$ENDIF} ); end;