* Dotted filenames for package uuid

This commit is contained in:
Michaël Van Canneyt 2023-03-06 14:57:54 +01:00
parent 37e637b61f
commit e42a11fbfe
5 changed files with 26 additions and 0 deletions

View File

@ -0,0 +1,3 @@
unit System.Libuuid;
{$DEFINE FPC_DOTTEDUNITS}
{$i libuuid.pp}

View File

@ -0,0 +1,3 @@
unit System.Macuuid;
{$DEFINE FPC_DOTTEDUNITS}
{$i macuuid.pp}

View File

@ -0,0 +1,4 @@
src/macuuid.pp=namespaced/System.Macuuid.pp
{s*:src/}=namespaced/
{i+:src/}
src/libuuid.pp=namespaced/System.Libuuid.pp

View File

@ -1,10 +1,16 @@
{$mode objfpc}
{$H+}
{$IFNDEF FPC_DOTTEDUNITS}
Unit Libuuid;
{$ENDIF FPC_DOTTEDUNITS}
interface
{$IFDEF FPC_DOTTEDUNITS}
uses System.SysUtils,System.DynLibs;
{$ELSE FPC_DOTTEDUNITS}
uses SysUtils,dynlibs;
{$ENDIF FPC_DOTTEDUNITS}
Var
LibUUIDName : String = 'libuuid.so.1';

View File

@ -1,17 +1,27 @@
{$mode objfpc}
{$H+}
{$IFNDEF FPC_DOTTEDUNITS}
unit macuuid;
{$ENDIF FPC_DOTTEDUNITS}
Interface
{$IFDEF FPC_DOTTEDUNITS}
uses System.SysUtils;
{$ELSE FPC_DOTTEDUNITS}
uses SysUtils;
{$ENDIF FPC_DOTTEDUNITS}
Function CreateMacGUID(Out GUID : TGUID) : Integer;
Implementation
{$IFDEF FPC_DOTTEDUNITS}
uses UnixApi.Types, System.Net.Sockets, UnixApi.Base, UnixApi.Unix;
{$ELSE FPC_DOTTEDUNITS}
uses unixtype, sockets, baseunix, unix;
{$ENDIF FPC_DOTTEDUNITS}
Const
MAX_ADJUSTMENT = 10;