OS.typeR Documentation

Detect the Operating System Type

Description

OS.type is a list of TRUE / / FALSE values dependent on the platform under which this package was built.

Usage

OS.type

Value

A list with at least the following components:

AIX

Built under IBM AIX.

HPUX

Built under Hewlett-Packard HP-UX.

linux

Built under some distribution of Linux.

darwin

Built under Apple OSX and iOS (Darwin).

iOS.simulator

Built under iOS in Xcode simulator.

iOS

Built under iOS on iPhone, iPad, etc.

macOS

Built under OSX.

solaris

Built under Solaris (SunOS).

cygwin

Built under Cygwin POSIX under Microsoft Windows.

windows

Built under Microsoft Windows.

win64

Built under Microsoft Windows (64-bit).

win32

Built under Microsoft Windows (32-bit).

UNIX

Built under a UNIX-style OS.

Source

http://web.archive.org/web/20191012035921/http://nadeausoftware.com/articles/2012/01/c_c_tip_how_use_compiler_predefined_macros_detect_operating_system