os

Interaction with OS.

os_name() : string

Returns OS name

OS(Platfrom)os_name() output
Windows 32-Bitwin32
Windows 64-Bitwin64
Mac OSmacos
Linuxlinux
FreeBSDfreebsd
AmigaOSamiga
Androidandroid
OpenBSD, NetBSD, DragonFlybsd
Cygwincygwin
Minixminix
Solarissolaris
Symbiansymbian
z/VMzvm

For other OSs, os_name will return unknown.

system(command:string) : int

Executes a command and returns command's exit code.

Example :

system("gcc main.c")

compiler_name() : string

Returns Sacalon C\C++ compiler name.

Compilercompiler_name() output
GCC\G++gcc
Clang(LLVM)clang
Microsoft Visual C++msvc
Digital Mars C\C++dmc
Intel C\C++icc

For other compilers, compiler_name will return unknown.

arch() : string

Returns CPU architecture.

Architecturearch() output
x86intel32
x86_64amd64
Armarm
Intel Itanium 64-Bitia64
Mipsmips
PowerPCpowerpc

is_x86() : bool

Returns true if CPU architecture is x86.

is_x64() : bool

Returns true if CPU architecture is x86_64.