0
votes

In Python I can write

import platform
>>> platform.system()
'Darwin'
>>> platform.release()
'8.11.1'

How can I find out my systems name and release number in Pascal?

2

2 Answers

1
votes

There is no universal way, but the for all *nixes including OS X there is baseunix.fpuname

0
votes

The platform version can be retrieved using the operating system API. The platform and the architecture can be detected using conditional compilation

{$IFDEF DARWIN}
// darwin specific code
{$ENDIF}
{$IFDEF LINUX}
// linux specific code
{$ENDIF}
{$IFDEF WINDOWS}
// windows specific code
{$ENDIF}
{$IFDEF CPU32}
// X86 specific code
{$ENDIF}    
{$IFDEF CPU64}
// X86_64 specific code
{$ENDIF}    

read more here and here.