POSIX: Difference between revisions

From Wikipedia, the free encyclopedia
Jump to navigation Jump to search
imported>Edgar.bonet
512- vs 1024-byte blocks: Fix {{when}} and {{citation needed}}
 
Line 14: Line 14:
| website          = {{URL|https://posix.opengroup.org}}
| website          = {{URL|https://posix.opengroup.org}}
}}
}}
The '''Portable Operating System Interface''' ('''POSIX'''; {{IPAc-en|IPA|ˈ|p|ɒ|z|.|ɪ|k|s}}<ref name="FAQ">{{cite web|date=13 June 2020|title=POSIX.1 FAQ|url=https://www.opengroup.org/austin/papers/posix_faq.html|publisher=The Open Group|access-date=20 February 2023}}</ref>) is a family of [[standardization|standard]]s specified by the [[IEEE Computer Society]] for maintaining compatibility between [[operating system]]s.<ref name="FAQ"/> POSIX defines [[API|application programming interface]]s (APIs), along with command line [[Unix shell|shell]]s and utility interfaces, for software compatibility (portability) with variants of [[Unix]] and other operating systems.<ref name="FAQ"/><ref name="IET">{{cite web|title=IEEE 1003.1-2024|url =https://standards.ieee.org/ieee/1003.1/7700/|website=IEEE Standards Association}}</ref> POSIX is also a [[trademark]] of the IEEE.<ref name="FAQ"/> POSIX is intended to be used by both application and system developers.<ref>{{Cite web|title=Introduction|url=https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap01.html|access-date=22 July 2021|work=The Open Group Base Specifications Issue 7, 2018 edition}}</ref> As of POSIX 2024, the standard is aligned with the [[C17 (C standard revision)|C17]] language standard<!-- up from C99 seemingly -->.
The '''Portable Operating System Interface''' ('''POSIX'''; {{IPAc-en|IPA|ˈ|p|ɒ|z|.|ɪ|k|s}}<ref name="FAQ">{{cite web|date=13 June 2020|title=POSIX.1 FAQ|url=https://www.opengroup.org/austin/papers/posix_faq.html|publisher=The Open Group|access-date=20 February 2023}}</ref>) is a family of [[standardization|standard]]s specified by the [[IEEE Computer Society]] for maintaining compatibility between [[operating system]]s.<ref name="FAQ"/> In order to define a level of compatibility, POSIX specifies many aspects of functionality that can be classified as [[application programming interface]] (API), [[command-line shell]], and [[command (computing)|shell commands]]. Originally derived from commonly-found Unix APIs, shells, and commands (partly because Unix was considered manufacturer-neutral), today many systems conform to the standard {{endash}} including [[branded Unix]] systems, [[Unix-like]] systems, and many systems that were historically unrelated to Unix.<ref name="FAQ"/><ref name="IET">{{cite web|title=IEEE 1003.1-2024|url =https://standards.ieee.org/ieee/1003.1/7700/|website=IEEE Standards Association}}</ref>
 
The standardized user command line and [[command-line interface#Command-line interpreter |scripting interface]] were based on the [[UNIX System V]] [[Bourne shell]].<ref>{{cite web|url=https://pubs.opengroup.org/onlinepubs/9699919799/xrat/V4_xcu_chap02.html|title=Shell Command Language - The Open Group Base Specifications Issue 7, 2013 Edition|access-date=28 April 2020}}</ref> Many user-level programs, services, and utilities (including [[AWK|awk]], [[echo (command)|echo]], [[ed (text editor)|ed]]) were also standardized, based on UNIX System V versions of them, along with required program-level services (including basic [[input/output|I/O]]: [[computer file|file]], [[computer terminal|terminal]], and [[computer network|network]]). POSIX also defines a standard [[thread (computing)|threading]] library API which is supported by most modern operating systems.
 
The POSIX standard is developed by the [[Austin Group]] (a joint [[working group]] among the IEEE, [[The Open Group]], and the [[ISO/IEC JTC 1/SC 22]]/WG 15).
 
POSIX is intended to be used by both application and system developers.<ref>{{Cite web|title=Introduction|url=https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap01.html|access-date=22 July 2021|work=The Open Group Base Specifications Issue 7, 2018 edition}}</ref>{{Explain| as-is this is confusing and awkward; expand to make this more meaningful|date=December 2025}}


==Name==
==Name==
Originally, the name "POSIX" referred to IEEE Std 1003.1-1988, released in 1988. The family of POSIX standards is formally designated as '''IEEE 1003''' and the ISO/IEC standard number is [[International Organization for Standardization|ISO]]/[[International Electrotechnical Commission|IEC]] 9945.
The standards emerged from a project that began in 1984 building on work from related activity in the ''/usr/group'' association.<ref>{{Cite web|title=JimIsaak - POSIX Impact|url=https://sites.google.com/site/jimisaak/posix-impact|access-date=15 September 2022 |website=sites.google.com|language=en-US}}</ref> [[Richard Stallman]] suggested the name ''POSIX'' to the IEEE<ref>{{cite web |url=https://www.opengroup.org/austin/papers/backgrounder.html |title=A Backgrounder on IEEE Std 1003.1 |at=Footnotes}}</ref><ref>{{Cite web |title=The origin of the name POSIX. |url=https://stallman.org/articles/posix.html |access-date=2024-09-26 |website=stallman.org}}</ref> instead of the former ''IEEE-IX''.<ref>{{cite journal |url=https://www.usenix.org/legacy/bodinfo/login0207.html |title=An Update On Standards |first=Nicholas |last=Stoughton |journal=[[;login:]]}}</ref> The committee found it more easily pronounceable and memorable, and thus adopted it.{{cn|date=June 2024}}
 
Originally, POSIX referred to IEEE Std 1003.1-1988, released in 1988. The family of POSIX standards is formally designated as '''IEEE 1003''' and the ISO/IEC standard number is [[International Organization for Standardization|ISO]]/[[International Electrotechnical Commission|IEC]] 9945.


The standards emerged from a project that began in 1984 building on work from related activity in the ''/usr/group'' association.<ref>{{Cite web|title=JimIsaak - POSIX Impact|url=https://sites.google.com/site/jimisaak/posix-impact|access-date=15 September 2022 |website=sites.google.com|language=en-US}}</ref> [[Richard Stallman]] suggested the name ''POSIX'' to the IEEE<ref>{{cite web |url=https://www.opengroup.org/austin/papers/backgrounder.html |title=A Backgrounder on IEEE Std 1003.1 |at=Footnotes}}</ref><ref>{{Cite web |title=The origin of the name POSIX. |url=https://stallman.org/articles/posix.html |access-date=2024-09-26 |website=stallman.org}}</ref> instead of the former ''IEEE-IX''.<ref>{{cite journal |url=https://www.usenix.org/legacy/bodinfo/login0207.html |title=An Update On Standards |first=Nicholas |last=Stoughton |journal=[[;login:]]}}</ref> The committee found it more easily pronounceable and memorable, and thus adopted it.{{cn|date=June 2024}}
POSIX is a [[trademark]] of the IEEE.<ref name="FAQ"/>


==Overview==
==Versions==
[[Unix]] was selected as the basis for a standard system interface partly because it was "manufacturer-neutral". However, several major versions of Unix existed—so there was a need to develop a common-denominator system. The POSIX specifications for [[Unix-like]] operating systems originally consisted of a single document for the core [[programming interface]], but eventually grew to 19 separate documents (POSIX.1, POSIX.2, etc.).<ref>{{Cite report|date=4 December 2003|title=PASC Status (including POSIX)|url=https://collaboration.opengroup.org/external/pasc.org/standing/sd11.html|publisher=[[IEEE Computer Society]]|access-date=26 September 2024}}</ref> The standardized user [[command-line interface|command line]] and [[command-line interface#Command-line interpreter|scripting interface]] were based on the [[UNIX System V]] shell.<ref>{{cite web|url=https://pubs.opengroup.org/onlinepubs/9699919799/xrat/V4_xcu_chap02.html|title=Shell Command Language - The Open Group Base Specifications Issue 7, 2013 Edition|access-date=28 April 2020}}</ref> Many user-level programs, services, and utilities (including [[AWK|awk]], [[echo (command)|echo]], [[ed (text editor)|ed]]) were also standardized, along with required program-level services (including basic [[input/output|I/O]]: [[computer file|file]], [[computer terminal|terminal]], and [[computer network|network]]). POSIX also defines a standard [[thread (computing)|threading]] library API which is supported by most modern operating systems. In 2008, most parts of POSIX were combined into a single standard ''(IEEE Std 1003.1-2008'', also known as ''POSIX.1-2008).''
POSIX originally consisted of a single document for core services but over time additional documents were published to extend and revise the specification. Before 1997, POSIX comprised multiple documents that were published over the course of several years. After 1997, the [[Austin Group]] produces specifications titled [[Single UNIX Specification]] (SUS). Over time, the group publishes versions of this specification and later POSIX is amended per some or all of a SUS version. A SUS version consists of a collection of volumes {{endash}} each for a grouping of required behavior {{endash}} plus other information (outside of a volume).<ref>{{Cite report|date=4 December 2003|title=PASC Status (including POSIX)|url=https://collaboration.opengroup.org/external/pasc.org/standing/sd11.html|publisher=[[IEEE Computer Society]]|access-date=26 September 2024}}</ref> Each volume is assigned an issue number that is the same for each volume of a version, but is not the same value as the version. For example, SUS version 3 (SUSv3) includes volumes labeled issue 6.


{{As of | 2014 }}, POSIX documentation is divided into two parts:
{{As of | 2014 }}, POSIX documentation is divided into two parts:
Line 28: Line 36:
* POSIX Conformance Testing: A test suite for POSIX accompanies the standard: '''VSX-PCTS''' or the '''VSX POSIX Conformance Test Suite'''.<ref name = "VSX-PCTS">{{cite web | url = https://www.opengroup.org/testing/testsuites/vsxpcts2003.htm | title = Test Suites VSX-PCTS2003 | publisher = The Open Group}}</ref>
* POSIX Conformance Testing: A test suite for POSIX accompanies the standard: '''VSX-PCTS''' or the '''VSX POSIX Conformance Test Suite'''.<ref name = "VSX-PCTS">{{cite web | url = https://www.opengroup.org/testing/testsuites/vsxpcts2003.htm | title = Test Suites VSX-PCTS2003 | publisher = The Open Group}}</ref>


The development of the POSIX standard takes place in the [[Austin Group]] (a joint [[working group]] among the IEEE, [[The Open Group]], and the [[ISO/IEC JTC 1/SC 22]]/WG 15).
===Before 1997===
 
====POSIX.1====
''Core Services'' (IEEE Std 1003.1-1988) incorporates standard [[ANSI C]] and includes:
:; [[Process (computing)|Process Creation and Control]]
:; [[Signal (IPC)|Signals]]
::; [[SIGFPE |Floating Point Exceptions]]
::; [[SIGSEGV |Segmentation / Memory Violations]]
::; [[SIGILL |Illegal Instructions]]
::; [[SIGBUS |Bus Errors]]
::; [[SIGALRM |Timers]]
:; File and Directory Operations
:; [[Pipeline (Unix)|Pipes]]
:; [[C standard library |C Library (Standard C)]]
:; The [[POSIX terminal interface]]
 
====POSIX.1b====
''Real-time extensions'' (IEEE Std 1003.1b-1993, later appearing as librt—the Realtime Extensions library) includes:<ref>


==Versions==
===Parts before 1997===
Before 1997, POSIX comprised several standards:
* '''POSIX.1''': Core Services (incorporates Standard [[ANSI C]]) (IEEE Std 1003.1-1988)
** [[Process (computing)|Process]] Creation and Control
** [[Signal (IPC)|Signals]]
*** [[SIGFPE|Floating Point Exceptions]]
*** [[SIGSEGV|Segmentation / Memory Violations]]
*** [[SIGILL|Illegal Instructions]]
*** [[SIGBUS|Bus Errors]]
*** [[SIGALRM|Timers]]
** File and Directory Operations
** [[Pipeline (Unix)|Pipes]]
** [[C standard library|C Library (Standard C)]]
** The [[POSIX terminal interface]]
* '''POSIX.1b''': Real-time extensions (IEEE Std 1003.1b-1993, later appearing as librt—the Realtime Extensions library)<ref>
{{cite web|url=https://docs.oracle.com/cd/E19455-01/806-0632/6j9vm89ic/index.html|title=librt(3LIB)|date=4 August 1998|website=docs.oracle.com|series=man pages section 3: Library Interfaces and Headers|publisher=Oracle Corporation|access-date=18 February 2016|quote=librt, libposix4- POSIX.1b Realtime Extensions library [...] librt is the preferred name for this library. The name libposix4 is maintained for backward compatibility and should be avoided. Functions in this library provide most of the interfaces specified by the POSIX.1b Realtime Extension.}}</ref>
{{cite web|url=https://docs.oracle.com/cd/E19455-01/806-0632/6j9vm89ic/index.html|title=librt(3LIB)|date=4 August 1998|website=docs.oracle.com|series=man pages section 3: Library Interfaces and Headers|publisher=Oracle Corporation|access-date=18 February 2016|quote=librt, libposix4- POSIX.1b Realtime Extensions library [...] librt is the preferred name for this library. The name libposix4 is maintained for backward compatibility and should be avoided. Functions in this library provide most of the interfaces specified by the POSIX.1b Realtime Extension.}}</ref>
** Priority [[Scheduling (computing)|Scheduling]]
:; Priority [[Scheduling (computing)|Scheduling]]
** [[SIGRTMIN and SIGRTMAX|Real-Time Signals]]
:; [[SIGRTMIN and SIGRTMAX|Real-Time Signals]]
** Clocks and Timers
:; Clocks and Timers
** [[Semaphore (programming)|Semaphores]]
:; [[Semaphore (programming)|Semaphores]]
** [[Message Passing]]
:; [[Message Passing]]
** [[Shared memory|Shared Memory]]
:; [[Shared memory|Shared Memory]]
** [[Asynchronous I/O|Asynchronous]] and Synchronous I/O
:; [[Asynchronous I/O|Asynchronous]] and Synchronous I/O
** Memory Locking Interface
:; Memory Locking Interface
* '''POSIX.1c''': [[POSIX Threads|Threads extensions]] (IEEE Std 1003.1c-1995)
** Thread Creation, Control, and Cleanup
** Thread Scheduling
** Thread Synchronization
** Signal Handling
* '''POSIX.2''': Shell and Utilities (IEEE Std 1003.2-1992)
** [[Command-line interpreter|Command Interpreter]]
** Utility Programs


===Versions after 1997===
====POSIX.1c====
After 1997, the [[Austin Group]] developed the POSIX revisions. The specifications are known under the name [[Single UNIX Specification]], before they become a POSIX standard when formally approved by the ISO.
[[POSIX Threads |''Threads extensions'']] (IEEE Std 1003.1c-1995) includes:


====POSIX.1-2001 (with two TCs)====
:; Thread Creation, Control, and Cleanup
''POSIX.1-2001'' (or IEEE Std 1003.1-2001) equates to the ''Single UNIX Specification, version 3'' minus ''X/Open Curses''.<ref>{{cite web|url=https://unix.org/version3/overview.html|title=The Single UNIX Specification Version 3 - Overview|website=unix.org}}</ref>
:; Thread Scheduling
:; Thread Synchronization
:; Signal Handling


This standard consisted of:
====POSIX.2====
* the Base Definitions, Issue 6,
''Shell and Utilities'' (IEEE Std 1003.2-1992) includes:
* the System Interfaces and Headers, Issue 6,
* the Commands and Utilities, Issue 6.


IEEE Std 1003.1-2004 involved a minor update of POSIX.1-2001. It incorporated two minor updates or [[Erratum|errata]] referred to as ''Technical Corrigenda'' (TCs).<ref>{{cite web|url=http://www.unix.org/version3/ieee_std.html|title=IEEE Std 1003.1|edition = 2004|publisher=Unix.org|access-date=26 July 2009}}</ref> Its contents are available on the web.<ref>{{cite web|url=https://pubs.opengroup.org/onlinepubs/009695399/|title=Base Specifications, Issue 6|edition=2004|access-date=20 July 2024|publisher=The Open Group}}.</ref>
:; [[Command-line interpreter|Command Interpreter]]
:; Utility Programs


====POSIX.1-2008 (with two TCs)====
===POSIX.1-2001===
''Base Specifications, Issue 7'' (or ''IEEE Std 1003.1-2008'', 2016 Edition).<ref name=AustinGroup>{{cite web|url=https://www.opengroup.org/austin/|title=The Austin Common Standards Revision Group|access-date=20 July 2024|publisher=The Open Group}}</ref>
''POSIX.1-2001'' (IEEE Std 1003.1-2001) consists of most of SUSv3 which consists of volumes (issue 6): ''Base Definitions'', ''System Interfaces and Headers'', and ''Commands and Utilities''. The POSIX specification specifically excludes the SUSv3 requirements for a curses API (often called ''X/Open Curses'', even though there is no distinct grouping of this in SUSv3).<ref>{{cite web|url=https://unix.org/version3/overview.html|title=The Single UNIX Specification Version 3 - Overview|website=unix.org}}</ref>


This standard consists of:
IEEE Std 1003.1-2004 modifies POSIX.1-2001 via two minor updates or [[Erratum |errata]] referred to as technical corrigenda documents.<ref>{{cite web|url=http://www.unix.org/version3/ieee_std.html|title=IEEE Std 1003.1|edition = 2004|publisher=Unix.org|access-date=26 July 2009}}</ref><ref>{{cite web|url=https://pubs.opengroup.org/onlinepubs/009695399/|title=Base Specifications, Issue 6|edition=2004|access-date=20 July 2024|publisher=The Open Group}}.</ref>
* the Base Definitions, Issue 7,
* the System Interfaces and Headers, Issue 7,
* the Commands and Utilities, Issue 7,
* the Rationale volume.


====POSIX.1-2017====
===POSIX.1-2008===
IEEE Std 1003.1-2017 (Revision of IEEE Std 1003.1-2008) - IEEE Standard for Information Technology—Portable Operating System Interface (POSIX(R)) Base Specifications, Issue 7 is available from either The Open Group or IEEE. It is technically identical to POSIX.1-2008 with Technical Corrigenda 1 and 2 applied. Its contents are available on the web.<ref>{{cite web|url=https://pubs.opengroup.org/onlinepubs/9699919799/|title=Base Specifications, Issue 7, 2018 Edition|edition=2018|access-date=20 July 2024|publisher=The Open Group}}</ref>
Similar to its predecessor, POSIX.1-2008 (''IEEE Std 1003.1-2008'', 2016 Edition) consists of most of the normative material of SUSv4 (issue 7 of volumes ''Base Definitions'', ''System Interfaces and Headers'', ''Commands and Utilities'').<ref name=AustinGroup>{{cite web|url=https://www.opengroup.org/austin/|title=The Austin Common Standards Revision Group|access-date=20 July 2024|publisher=The Open Group}}</ref> SUSv4 also includes rationale information that largely applies to POSIX although not included per se.


====POSIX.1-2024====
===POSIX.1-2017===
IEEE Std 1003.1-2024 - IEEE Standard for Information Technology—Portable Operating System Interface (POSIX(R)) Base Specifications, Issue 8 was published on 14 June 2024.<ref name=AustinGroup/> Its contents are available on the web.<ref>{{cite web|url=https://pubs.opengroup.org/onlinepubs/9799919799/|title=Base Specifications, Issue 8|edition=2024|publisher=The Open Group}}.</ref>
POSIX.1-2017 (''IEEE Std 1003.1-2017'') revises the previous version (POSIX.1-2008) via two technical corrigenda.<ref>{{cite web|url=https://pubs.opengroup.org/onlinepubs/9699919799/|title=Base Specifications, Issue 7, 2018 Edition|edition=2018|access-date=20 July 2024|publisher=The Open Group}}</ref>
 
===POSIX.1-2024===
POSIX.1-2024 (''IEEE Std 1003.1-2024'') was published on 14 June 2024.<ref name=AustinGroup/><ref>{{cite web|url=https://pubs.opengroup.org/onlinepubs/9799919799/|title=Base Specifications, Issue 8|edition=2024|publisher=The Open Group}}.</ref>
 
As of POSIX 2024, the standard is aligned with the [[C17 (C standard revision)|C17]] language standard.


==Controversies==
==Controversies==
Line 97: Line 100:
POSIX mandates 512-byte default [[Block (computer memory)|block]] sizes for the [[Df (Unix)|df]] and [[Du (Unix)|du]] utilities, reflecting the typical size of blocks on disks. When [[Richard M. Stallman|Richard Stallman]] and the [[GNU]] team were implementing POSIX for the [[GNU operating system]], they objected to this on the grounds that most people think in terms of 1024 byte (or 1 [[Kibibyte|KiB]]) blocks. The environment variable {{tt|POSIX_ME_HARDER}} was introduced to allow the user to force the standards-compliant behaviour.<ref>{{Cite newsgroup|last=Stallman|first=Richard|title=Democracy Triumphs in Disk Units|date=28 August 1991|newsgroup=gnu.announce|message-id=9108281809.AA03552@mole.gnu.ai.mit.edu|via=Google Groups |url=http://groups.google.com/group/gnu.announce/msg/6c6e20b57ddb1a82?pli=1}}</ref> The variable name was later changed to {{tt|POSIXLY_CORRECT}}.<ref>{{cite web|publisher=GNU|url=https://www.gnu.org/prep/standards/standards.html#Non_002dGNU-Standards|title=GNU Coding Standards}}</ref> As of 2025, this variable is also used for a number of other behaviour quirks.<ref>{{cite web|author=<!-- not stated -->|date=2025-05-17|title=environ(7) — Linux manual page|url=https://man7.org/linux/man-pages/man7/environ.7.html|website=man7.org|publisher=Michael Kerrisk|access-date=2025-10-10}}</ref><ref>{{cite web|author=<!-- not stated -->|date=April 7, 2025|title=bash(1) — Linux manual page|url=https://man7.org/linux/man-pages/man1/bash.1.html|website=man7.org|publisher=Michael Kerrisk|access-date=2025-10-10}}</ref><ref>{{cite web|author=<!-- not stated -->|date=June 17, 2025|title=file(1) — Linux manual page|url=https://man7.org/linux/man-pages/man1/file.1.html|website=man7.org|publisher=Michael Kerrisk|access-date=2025-10-10}}</ref><ref>{{cite web|author=<!-- not stated -->|date=2025-07-09|title=find(1) — Linux manual page|url=https://man7.org/linux/man-pages/man1/find.1.html|website=man7.org|publisher=Michael Kerrisk|access-date=2025-10-10}}</ref><ref>{{cite web|author=<!-- not stated -->|date=2025-03-21|title=grep(1) — Linux manual page|url=https://man7.org/linux/man-pages/man1/grep.1.html|website=man7.org|publisher=Michael Kerrisk|access-date=2025-10-10}}</ref><ref>{{cite web|author=<!-- not stated -->|date=2025-08-09|title=more(1) — Linux manual page|url=https://man7.org/linux/man-pages/man1/more.1.html|website=man7.org|publisher=Michael Kerrisk|access-date=2025-10-10}}</ref><ref>{{cite web|author=<!-- not stated -->|date=2025-05-01|title=patch(1) — Linux manual page|url=https://man7.org/linux/man-pages/man1/patch.1.html|website=man7.org|publisher=Michael Kerrisk|access-date=2025-10-10}}</ref><ref>{{cite web|author=<!-- not stated -->|date=2025-04-23|title=ps(1) — Linux manual page|url=https://man7.org/linux/man-pages/man1/ps.1.html|website=man7.org|publisher=Michael Kerrisk|access-date=2025-10-10}}</ref><ref>{{cite web|author=<!-- not stated -->|date=2025-08-09|title=renice(1) — Linux manual page|url=https://man7.org/linux/man-pages/man1/renice.1.html|website=man7.org|publisher=Michael Kerrisk|access-date=2025-10-10}}</ref>
POSIX mandates 512-byte default [[Block (computer memory)|block]] sizes for the [[Df (Unix)|df]] and [[Du (Unix)|du]] utilities, reflecting the typical size of blocks on disks. When [[Richard M. Stallman|Richard Stallman]] and the [[GNU]] team were implementing POSIX for the [[GNU operating system]], they objected to this on the grounds that most people think in terms of 1024 byte (or 1 [[Kibibyte|KiB]]) blocks. The environment variable {{tt|POSIX_ME_HARDER}} was introduced to allow the user to force the standards-compliant behaviour.<ref>{{Cite newsgroup|last=Stallman|first=Richard|title=Democracy Triumphs in Disk Units|date=28 August 1991|newsgroup=gnu.announce|message-id=9108281809.AA03552@mole.gnu.ai.mit.edu|via=Google Groups |url=http://groups.google.com/group/gnu.announce/msg/6c6e20b57ddb1a82?pli=1}}</ref> The variable name was later changed to {{tt|POSIXLY_CORRECT}}.<ref>{{cite web|publisher=GNU|url=https://www.gnu.org/prep/standards/standards.html#Non_002dGNU-Standards|title=GNU Coding Standards}}</ref> As of 2025, this variable is also used for a number of other behaviour quirks.<ref>{{cite web|author=<!-- not stated -->|date=2025-05-17|title=environ(7) — Linux manual page|url=https://man7.org/linux/man-pages/man7/environ.7.html|website=man7.org|publisher=Michael Kerrisk|access-date=2025-10-10}}</ref><ref>{{cite web|author=<!-- not stated -->|date=April 7, 2025|title=bash(1) — Linux manual page|url=https://man7.org/linux/man-pages/man1/bash.1.html|website=man7.org|publisher=Michael Kerrisk|access-date=2025-10-10}}</ref><ref>{{cite web|author=<!-- not stated -->|date=June 17, 2025|title=file(1) — Linux manual page|url=https://man7.org/linux/man-pages/man1/file.1.html|website=man7.org|publisher=Michael Kerrisk|access-date=2025-10-10}}</ref><ref>{{cite web|author=<!-- not stated -->|date=2025-07-09|title=find(1) — Linux manual page|url=https://man7.org/linux/man-pages/man1/find.1.html|website=man7.org|publisher=Michael Kerrisk|access-date=2025-10-10}}</ref><ref>{{cite web|author=<!-- not stated -->|date=2025-03-21|title=grep(1) — Linux manual page|url=https://man7.org/linux/man-pages/man1/grep.1.html|website=man7.org|publisher=Michael Kerrisk|access-date=2025-10-10}}</ref><ref>{{cite web|author=<!-- not stated -->|date=2025-08-09|title=more(1) — Linux manual page|url=https://man7.org/linux/man-pages/man1/more.1.html|website=man7.org|publisher=Michael Kerrisk|access-date=2025-10-10}}</ref><ref>{{cite web|author=<!-- not stated -->|date=2025-05-01|title=patch(1) — Linux manual page|url=https://man7.org/linux/man-pages/man1/patch.1.html|website=man7.org|publisher=Michael Kerrisk|access-date=2025-10-10}}</ref><ref>{{cite web|author=<!-- not stated -->|date=2025-04-23|title=ps(1) — Linux manual page|url=https://man7.org/linux/man-pages/man1/ps.1.html|website=man7.org|publisher=Michael Kerrisk|access-date=2025-10-10}}</ref><ref>{{cite web|author=<!-- not stated -->|date=2025-08-09|title=renice(1) — Linux manual page|url=https://man7.org/linux/man-pages/man1/renice.1.html|website=man7.org|publisher=Michael Kerrisk|access-date=2025-10-10}}</ref>


==POSIX-oriented operating systems==
==Conformance==
Depending upon the degree of compliance with the standards, operating systems can be classified as fully or partly POSIX compatible.
An operating system can be classified depending upon the degree of conformance with a POSIX standard.


===POSIX-certified===
===Certified===
Current versions of the following operating systems have been certified to conform to one or more of the various POSIX standards. This means that they passed the automated conformance tests<ref name="achieve_status">{{cite web|url=https://posix.opengroup.org/certification_guide.html#Howto|title=POSIX Certified by IEEE and The Open Group - Program Guide|at=Section 2, How to Achieve Certification|access-date=26 September 2024}}</ref> and their certification has not expired and the operating system has not been discontinued.<ref name="renew_certification">{{cite web |url=https://posix.opengroup.org/certification_guide.html#Renewals|title=POSIX Certified by IEEE and The Open Group - Program Guide|at=Section 4, Renewals and Certified Product Updates|access-date=26 September 2024}}</ref><ref>{{cite web|url=https://www.opengroup.org/openbrand/register/company.htm|title=Certified Products by Company|author=<!--Not stated-->|date=n.d.|publisher=The Open Group |access-date=22 January 2022}}</ref>
Current versions of the following operating systems have been certified to conform to one or more of the various POSIX standards. This means that they passed the automated conformance tests<ref name="achieve_status">{{cite web|url=https://posix.opengroup.org/certification_guide.html#Howto|title=POSIX Certified by IEEE and The Open Group - Program Guide|at=Section 2, How to Achieve Certification|access-date=26 September 2024}}</ref> and their certification has not expired and the operating system has not been discontinued.<ref name="renew_certification">{{cite web |url=https://posix.opengroup.org/certification_guide.html#Renewals|title=POSIX Certified by IEEE and The Open Group - Program Guide|at=Section 4, Renewals and Certified Product Updates|access-date=26 September 2024}}</ref><ref>{{cite web|url=https://www.opengroup.org/openbrand/register/company.htm|title=Certified Products by Company|author=<!--Not stated-->|date=n.d.|publisher=The Open Group |access-date=22 January 2022}}</ref>
<!-- Please don't add additional operating systems without also citing a source for the information. -->
<!-- Please don't add additional operating systems without also citing a source for the information. -->
Line 107: Line 110:
*[[HP-UX]]<ref name="hp">{{cite web |url=https://www.opengroup.org/openbrand/register/hp.htm |title=Hewlett-Packard  |publisher=The Open Group |access-date=26 January 2014}}</ref>
*[[HP-UX]]<ref name="hp">{{cite web |url=https://www.opengroup.org/openbrand/register/hp.htm |title=Hewlett-Packard  |publisher=The Open Group |access-date=26 January 2014}}</ref>
*[[Integrity (operating system)|INTEGRITY]]<ref name="posix-register">{{Cite web|url=https://posix.opengroup.org/register.html|title=POSIX Certification Register|website=[[The Open Group]]|access-date=22 August 2024}}</ref>
*[[Integrity (operating system)|INTEGRITY]]<ref name="posix-register">{{Cite web|url=https://posix.opengroup.org/register.html|title=POSIX Certification Register|website=[[The Open Group]]|access-date=22 August 2024}}</ref>
*[[macOS]] (since [[Mac OS X Leopard]]<ref>{{cite web|title=macOS version 10.5 Leopard on Intel-based Mac computers |url=https://www.opengroup.org/openbrand/register/brand3555.htm|work=Register of Open Branded Products|publisher=The Open Group |access-date=20 May 2015}}</ref> to [[macOS Tahoe]]<ref>{{cite web|url=https://www.opengroup.org/openbrand/register/brand3720.htm|title=macOS version 26.0 Tahoe on Intel-based Mac computers|publisher=The Open Group|access-date=5 October 2025}}</ref><ref>{{cite web|url=https://www.opengroup.org/openbrand/register/brand3725.htm|title=macOS version 26.0 Tahoe on Apple Silicon-based Mac computers|publisher=The Open Group|access-date=5 October 2025}}</ref>)
*[[macOS]] (from [[Mac OS X Leopard]]<ref>{{cite web|title=macOS version 10.5 Leopard on Intel-based Mac computers |url=https://www.opengroup.org/openbrand/register/brand3555.htm|work=Register of Open Branded Products|publisher=The Open Group |access-date=20 May 2015}}</ref> to [[macOS Tahoe]]<ref>{{cite web|url=https://www.opengroup.org/openbrand/register/brand3720.htm|title=macOS version 26.0 Tahoe on Intel-based Mac computers|publisher=The Open Group|access-date=5 October 2025}}</ref><ref>{{cite web|url=https://www.opengroup.org/openbrand/register/brand3725.htm|title=macOS version 26.0 Tahoe on Apple Silicon-based Mac computers|publisher=The Open Group|access-date=5 October 2025}}</ref>)
*[[OpenServer]]<ref>{{cite web|url=https://www.opengroup.org/openbrand/register/brand2574.htm|title=SCO OpenServer Release 5  |date=3 May 1995|publisher=The Open Group|access-date=24 December 2021}}</ref>
*[[OpenServer]]<ref>{{cite web|url=https://www.opengroup.org/openbrand/register/brand2574.htm|title=SCO OpenServer Release 5  |date=3 May 1995|publisher=The Open Group|access-date=24 December 2021}}</ref>
*[[UnixWare]]<ref>{{cite web|url=https://www.opengroup.org/openbrand/register/brand2713.htm |title=UnixWare ® 7.1.3 and later  |date=16 May 2003|publisher=The Open Group|access-date=24 December 2021}}</ref>
*[[UnixWare]]<ref>{{cite web|url=https://www.opengroup.org/openbrand/register/brand2713.htm |title=UnixWare ® 7.1.3 and later  |date=16 May 2003|publisher=The Open Group|access-date=24 December 2021}}</ref>
Line 114: Line 117:
{{div col end}}
{{div col end}}


===Formerly POSIX-certified===
===Formerly certified===
Some versions of the following operating systems had been certified to conform to one or more of the various POSIX standards. This means that they passed the automated conformance tests. The certification has expired and some of the operating systems have been discontinued.<ref name="renew_certification" />
Some versions of the following operating systems had been certified to conform to one or more of the various POSIX standards. This means that they passed the automated conformance tests. The certification has expired and some of the operating systems have been discontinued.<ref name="renew_certification" />
<!-- Please don't add additional operating systems without also citing a source for the information. -->
<!-- Please don't add additional operating systems without also citing a source for the information. -->
Line 128: Line 131:
{{div col end}}
{{div col end}}


===Mostly POSIX-compliant===
===Partially conformant===
The following are not certified as POSIX compliant yet comply in large part:
The following are not certified as POSIX conforming yet are considered partially conforming which is sometimes called ''compliant'':{{cn|date=December 2025}}
{{div col|colwidth=18em}}
{{div col|colwidth=18em}}
*[[Android (operating system)|Android]] (Available through Android NDK){{citation needed|date=December 2014}}
*[[Android (operating system)|Android]] (Available through Android NDK){{citation needed|date=December 2014}}
Line 139: Line 142:
*[[Linux]] (most distributions)
*[[Linux]] (most distributions)
*[[LynxOS]]
*[[LynxOS]]
*[[Minix]] (now{{when|date=July 2025}} [[Minix 3]])
*[[Minix]] (since 2005 [[Minix 3]])
*[[HP Multi-Programming Executive|MPE/iX]]<ref>{{Cite magazine|magazine=Computerworld|url=https://books.google.com/books?id=-6GcSQAVaHgC&q=posix&pg=PA24|title = HP 3000 sales catch market by surprise|author=Mark Halper|volume = 28|issue=4|publisher=IDG Enterprise|date= 7 November 1994}}</ref>
*[[HP Multi-Programming Executive|MPE/iX]]<ref>{{Cite magazine|magazine=Computerworld|url=https://books.google.com/books?id=-6GcSQAVaHgC&q=posix&pg=PA24|title = HP 3000 sales catch market by surprise|author=Mark Halper|volume = 28|issue=4|publisher=IDG Enterprise|date= 7 November 1994}}</ref>
*[[NetBSD]]
*[[NetBSD]]
Line 162: Line 165:
{{div col end}}
{{div col end}}


====POSIX for Microsoft Windows====
===Partially conformant via compatibility layer {{Anchor |Compliant via compatibility feature}}===
*[[Cygwin]] provides a largely POSIX-compliant development and run-time environment for [[Microsoft Windows]].
*[[MinGW]], a [[fork (software development)|fork]] of Cygwin, provides a less POSIX-compliant development environment and supports compatible [[C (programming language)|C]]-programmed applications via [[Msvcrt]], Microsoft's old Visual C [[runtime library]].
*libunistd, a largely POSIX-compliant development library originally created to build the Linux-based C/[[C++]] source code of [[CinePaint]] as is in [[Microsoft Visual Studio]]. A lightweight implementation that has POSIX-compatible header files that map POSIX APIs to call their Windows API counterparts.<ref>{{cite web|url = https://github.com/robinrowe/libunistd|title=libunistd| last=Rowe|first=Robin|date=8 September 2022|website=Github|publisher=|access-date=18 February 2023|quote=If you want to build single codebase C++ code to run on Windows, Linux and MacOS, you need this for Windows}}</ref>
*[[Microsoft POSIX subsystem]], an optional Windows subsystem included in Windows NT-based operating systems up to Windows 2000. It supported POSIX.1 as it stood in the 1990 revision, without [[pthreads|threads]] or [[Berkeley socket|sockets]].
*[[Interix]], originally OpenNT by Softway Systems, Inc., is an upgrade and replacement for [[Microsoft POSIX subsystem]] that was purchased by [[Microsoft]] in 1999. It was initially marketed as a stand-alone add-on product and then later included as a component in [[Windows Services for UNIX]] (SFU) and finally incorporated as a component in [[Windows Server 2003 R2]] and later Windows OS releases under the name "Subsystem for UNIX-based Applications" (SUA); later made deprecated in 2012 (Windows 8)<ref>{{cite web|url=https://docs.microsoft.com/en-us/previous-versions/windows/it-pro/windows-server-2012-R2-and-2012/hh831568(v=ws.11)|title=Features Removed or Deprecated in Windows Server 2012|date=31 August 2016|website=[[Microsoft Docs]]}}</ref> and dropped in 2013 (2012 R2, 8.1). It enables full POSIX compliance for certain [[Microsoft Windows]] products.{{Citation needed|date=March 2011}}
*[[Windows Subsystem for Linux]], also known as WSL, is a compatibility layer for running Linux binary executables natively on Windows 10 and 11 using a Linux image such as Ubuntu, Debian, or OpenSUSE among others, acting as an upgrade and replacement for Windows Services for UNIX. It was released in beta in April 2016. The first distribution available was Ubuntu.
*[[UWIN]] from AT&T Research implements a POSIX layer on top of the Win32 APIs.
*[[MKS Toolkit]], originally created for MS-DOS, is a software package produced and maintained by [[MKS Inc.]] that provides a [[Unix-like]] environment for scripting, connectivity and porting [[Unix]] and [[Linux]] software to both 32- and 64-bit [[Microsoft Windows]] systems. A subset of it was included in the first release of [[Windows Services for UNIX]] (SFU) in 1998.<ref>{{cite web|url=http://www.microsoft.com/ntserver/nts/exec/overview/sfu.asp|title=Windows NT Services for UNIX Add-On Pack|website=[[Microsoft]]|archive-url=https://web.archive.org/web/19990508011234/http://www.microsoft.com/ntserver/nts/exec/overview/sfu.asp|archive-date=8 May 1999}}</ref><ref>{{cite press release|url=http://mks.com/press/981109a.htm|title=MKS Solves Enterprise Interoperability Challenges|archive-url=https://web.archive.org/web/19990428003638/http://mks.com/press/981109a.htm|archive-date=28 April 1999}}</ref>
*[[Microsoft Windows library files#Runtime libraries|Windows C Runtime Library]] and [[Winsock|Windows Sockets API]] implement commonly used POSIX API functions for file, time, environment, and socket access,<ref>{{cite web |url=https://docs.microsoft.com/en-us/previous-versions/ms235384(v=vs.100) |title=Deprecated CRT Functions |date=15 October 2009 |access-date=23 July 2022 |website=[[Microsoft Docs]]}}</ref> although the support remains largely incomplete and not fully interoperable with POSIX-compliant implementations.<ref>{{cite web |url=https://docs.microsoft.com/en-us/windows/win32/winsock/porting-socket-applications-to-winsock?redirectedfrom=MSDN |title=Porting Socket Applications to Winsock |date=7 January 2021 |access-date=23 July 2022 |website=[[Microsoft Docs]]}}</ref><ref>{{cite web|url=https://tangentsoft.net/wskfaq/articles/bsd-compatibility.html|title=Winsock Programmer's FAQ Articles: BSD Sockets Compatibility|date=31 August 2015 |access-date=8 October 2015 |publisher=Warren Young}}</ref>{{discuss|BSD sockets as "POSIX"}}
 
====POSIX for OS/2====
Mostly POSIX compliant environments for [[OS/2]]:
* [[EMX (programming environment)|emx+gcc]] – largely POSIX compliant
 
====POSIX for DOS====
Partially POSIX compliant environments for [[DOS]] include:
* [[EMX (programming environment)|emx+gcc]] – largely POSIX compliant
* [[DJGPP]] – partially POSIX compliant
* [[DR-DOS]] multitasking core via {{mono|[[EMM386]] /MULTI}} – a POSIX threads frontend API extension is available
{{Anchor|Compliant via compatibility feature}}
 
====Compliant via compatibility layer====
<!-- linked from redirect [[Ixemul.library]] -->
<!-- linked from redirect [[Ixemul.library]] -->
The following are not officially certified as POSIX compatible, but they conform in large part to the standards by implementing POSIX support via some sort of compatibility feature (usually translation libraries, or a layer atop the kernel). Without these features, they are usually non-compliant.
The following operating systems are not certified as POSIX conformant, but they conform in large part to the standard by implementing POSIX support via a compatibility feature (usually translation libraries, or a layer atop the kernel).


*[[AmigaOS]] (through the ixemul library or [[vbcc]]_PosixLib<ref>{{Cite web|url=http://aminet.net/package/dev/c/vbcc_PosixLib|title=Aminet - dev/C/Vbcc_PosixLib.lha}}</ref>)
*[[AmigaOS]] (through the ixemul library or [[vbcc]]_PosixLib<ref>{{Cite web|url=http://aminet.net/package/dev/c/vbcc_PosixLib|title=Aminet - dev/C/Vbcc_PosixLib.lha}}</ref>)
Line 197: Line 178:
*[[Symbian|Symbian OS]] with [[PIPS]] (PIPS Is POSIX on Symbian)
*[[Symbian|Symbian OS]] with [[PIPS]] (PIPS Is POSIX on Symbian)
*[[VAXELN]] (partial support of 1003.1 and 1003.4 through the VAXELN POSIX runtime library)<ref>{{cite manual|url=http://www.bitsavers.org/pdf/dec/vax/realtime/EK-RPTSS-TM-004_Real-Time_Products_Technical_Summary_Dec92.pdf|title=Realtime Products Technical Summary, Fifth Edition|publisher=[[Digital Equipment Corporation]]|date=December 1992|access-date=8 December 2021}}</ref>
*[[VAXELN]] (partial support of 1003.1 and 1003.4 through the VAXELN POSIX runtime library)<ref>{{cite manual|url=http://www.bitsavers.org/pdf/dec/vax/realtime/EK-RPTSS-TM-004_Real-Time_Products_Technical_Summary_Dec92.pdf|title=Realtime Products Technical Summary, Fifth Edition|publisher=[[Digital Equipment Corporation]]|date=December 1992|access-date=8 December 2021}}</ref>
*[[Architecture of Windows NT|Windows NT kernel]] when using Microsoft [[Windows Services for UNIX|SFU]] 3.5 or [[Subsystem for UNIX-based Applications|SUA]]
*[[Architecture of Windows NT |Windows NT kernel]] when using [[Windows Services for UNIX]] 3.5 or [[Subsystem for UNIX-based Applications]]. To be POSIX compliant, one must activate optional features of Windows NT and Windows 2000 Server.<ref name="MS">{{cite web|url=http://www.microsoft.com/technet/archive/ntwrkstn/reskit/poscomp.mspx|title=Chapter 29 - POSIX Compatibility|work=MS Windows NT Workstation Resource Kit|publisher=Microsoft|archive-url=https://web.archive.org/web/20080115185233/http://www.microsoft.com/technet/archive/ntwrkstn/reskit/poscomp.mspx|archive-date=15 January 2008}}</ref>
**[[Windows 2000|Windows 2000 Server or Professional with Service Pack 3 or later]]. To be POSIX compliant, one must activate optional features of Windows NT and Windows 2000 Server.<ref name="MS">{{cite web|url=http://www.microsoft.com/technet/archive/ntwrkstn/reskit/poscomp.mspx|title=Chapter 29 - POSIX Compatibility|work=MS Windows NT Workstation Resource Kit|publisher=Microsoft|archive-url=https://web.archive.org/web/20080115185233/http://www.microsoft.com/technet/archive/ntwrkstn/reskit/poscomp.mspx|archive-date=15 January 2008}}</ref>
 
**[[Windows XP|Windows XP Professional with Service Pack 1 or later]]
===Conformance via subsystem===
**[[Windows Server 2003]]
Some technologies allow an operating system to enjoy a level of conformance to POSIX even though the operating system itself has little or no conformance.
**[[Windows Server 2008]] and Ultimate and Enterprise versions of [[Windows Vista]]
 
**[[Windows Server 2008 R2]] and Ultimate and Enterprise versions of [[Windows 7]]
====For Windows====
**albeit deprecated, still available for [[Windows Server 2012]] and Enterprise version of [[Windows 8]]
Although [[Windows]] does not conform to POSIX, the following technologies provide a level of compliance.
; [[Cygwin]]: Provides a largely POSIX-compliant development and run-time environment for [[Microsoft Windows]].
; [[MinGW]]: A [[fork (software development)|fork]] of Cygwin, provides a less POSIX-compliant development environment and supports compatible [[C (programming language)|C]]-programmed applications via [[Msvcrt]], Microsoft's old Visual C [[runtime library]].
; libunistd: A largely POSIX-compliant development library originally created to build the Linux-based C/[[C++]] source code of [[CinePaint]] as is in [[Microsoft Visual Studio]]. A lightweight implementation that has POSIX-compatible header files that map POSIX APIs to call their Windows API counterparts.<ref>{{cite web|url = https://github.com/robinrowe/libunistd|title=libunistd| last=Rowe|first=Robin|date=8 September 2022|website=Github|publisher=|access-date=18 February 2023|quote=If you want to build single codebase C++ code to run on Windows, Linux and MacOS, you need this for Windows}}</ref>
; [[Microsoft POSIX subsystem]]: An optional Windows subsystem included in Windows NT-based operating systems up to Windows 2000. It supported POSIX.1 as it stood in the 1990 revision, without [[pthreads|threads]] or [[Berkeley socket|sockets]].
; [[Interix]]: originally OpenNT by Softway Systems, Inc., is an upgrade and replacement for [[Microsoft POSIX subsystem]] that was purchased by [[Microsoft]] in 1999. It was initially marketed as a stand-alone add-on product and then later included as a component in [[Windows Services for UNIX]] (SFU) and finally incorporated as a component in [[Windows Server 2003 R2]] and later Windows OS releases under the name "Subsystem for UNIX-based Applications" (SUA), later made deprecated in 2012 (Windows 8)<ref>{{cite web|url=https://docs.microsoft.com/en-us/previous-versions/windows/it-pro/windows-server-2012-R2-and-2012/hh831568(v=ws.11)|title=Features Removed or Deprecated in Windows Server 2012|date=31 August 2016|website=[[Microsoft Docs]]}}</ref> and dropped in 2013 (2012 R2, 8.1). It enables full POSIX compliance for certain [[Microsoft Windows]] products.{{Citation needed|date=March 2011}}
; [[Windows Subsystem for Linux]] (WSL): A compatibility layer for running Linux binary executables natively on Windows 10 and 11 using a Linux image such as Ubuntu, Debian, or OpenSUSE among others, acting as an upgrade and replacement for Windows Services for UNIX. It was released in beta in April 2016. The first distribution available was Ubuntu.
; [[UWIN]]: From AT&T Research implements a POSIX layer on top of the Win32 APIs.
; [[MKS Toolkit]]: Originally created for MS-DOS, is a software package produced and maintained by [[MKS Inc.]] that provides a [[Unix-like]] environment for scripting, connectivity and porting [[Unix]] and [[Linux]] software to both 32- and 64-bit [[Microsoft Windows]] systems. A subset of it was included in the first release of [[Windows Services for UNIX]] (SFU) in 1998.<ref>{{cite web|url=http://www.microsoft.com/ntserver/nts/exec/overview/sfu.asp|title=Windows NT Services for UNIX Add-On Pack|website=[[Microsoft]]|archive-url=https://web.archive.org/web/19990508011234/http://www.microsoft.com/ntserver/nts/exec/overview/sfu.asp|archive-date=8 May 1999}}</ref><ref>{{cite press release|url=http://mks.com/press/981109a.htm|title=MKS Solves Enterprise Interoperability Challenges|archive-url=https://web.archive.org/web/19990428003638/http://mks.com/press/981109a.htm|archive-date=28 April 1999}}</ref>
; [[Microsoft Windows library files#Runtime libraries|Windows C Runtime Library]] and [[Winsock|Windows Sockets API]]: Implement commonly used POSIX API functions for file, time, environment, and socket access,<ref>{{cite web |url=https://docs.microsoft.com/en-us/previous-versions/ms235384(v=vs.100) |title=Deprecated CRT Functions |date=15 October 2009 |access-date=23 July 2022 |website=[[Microsoft Docs]]}}</ref> although the support remains largely incomplete and not fully interoperable with POSIX-compliant implementations.<ref>{{cite web |url=https://docs.microsoft.com/en-us/windows/win32/winsock/porting-socket-applications-to-winsock?redirectedfrom=MSDN |title=Porting Socket Applications to Winsock |date=7 January 2021 |access-date=23 July 2022 |website=[[Microsoft Docs]]}}</ref><ref>{{cite web|url=https://tangentsoft.net/wskfaq/articles/bsd-compatibility.html|title=Winsock Programmer's FAQ Articles: BSD Sockets Compatibility|date=31 August 2015 |access-date=8 October 2015 |publisher=Warren Young}}</ref>{{discuss|BSD sockets as "POSIX"}}
 
====For OS/2====
POSIX environments for [[OS/2]]:
; [[EMX (programming environment) |emx+gcc]]: Largely POSIX compliant.
 
====For DOS====
POSIX environments for [[DOS]] include:
; [[EMX (programming environment) |emx+gcc]]: Largely POSIX compliant
; [[DJGPP]]: Partially POSIX compliant
; [[DR-DOS]]: Multitasking core via {{mono|[[EMM386]] /MULTI}} – a POSIX threads frontend API extension is available


==See also==
==See also==

Latest revision as of 12:15, 27 December 2025

Template:Short description Script error: No such module "Distinguish". Template:Use dmy dates Template:Infobox technology standard The Portable Operating System Interface (POSIX; Template:IPAc-en[1]) is a family of standards specified by the IEEE Computer Society for maintaining compatibility between operating systems.[1] In order to define a level of compatibility, POSIX specifies many aspects of functionality that can be classified as application programming interface (API), command-line shell, and shell commands. Originally derived from commonly-found Unix APIs, shells, and commands (partly because Unix was considered manufacturer-neutral), today many systems conform to the standard

  1. REDIRECT Template:En dash

Template:R protected including branded Unix systems, Unix-like systems, and many systems that were historically unrelated to Unix.[1][2]

The standardized user command line and scripting interface were based on the UNIX System V Bourne shell.[3] Many user-level programs, services, and utilities (including awk, echo, ed) were also standardized, based on UNIX System V versions of them, along with required program-level services (including basic I/O: file, terminal, and network). POSIX also defines a standard threading library API which is supported by most modern operating systems.

The POSIX standard is developed by the Austin Group (a joint working group among the IEEE, The Open Group, and the ISO/IEC JTC 1/SC 22/WG 15).

POSIX is intended to be used by both application and system developers.[4]Template:Explain

Name

The standards emerged from a project that began in 1984 building on work from related activity in the /usr/group association.[5] Richard Stallman suggested the name POSIX to the IEEE[6][7] instead of the former IEEE-IX.[8] The committee found it more easily pronounceable and memorable, and thus adopted it.Script error: No such module "Unsubst".

Originally, POSIX referred to IEEE Std 1003.1-1988, released in 1988. The family of POSIX standards is formally designated as IEEE 1003 and the ISO/IEC standard number is ISO/IEC 9945.

POSIX is a trademark of the IEEE.[1]

Versions

POSIX originally consisted of a single document for core services but over time additional documents were published to extend and revise the specification. Before 1997, POSIX comprised multiple documents that were published over the course of several years. After 1997, the Austin Group produces specifications titled Single UNIX Specification (SUS). Over time, the group publishes versions of this specification and later POSIX is amended per some or all of a SUS version. A SUS version consists of a collection of volumes

  1. REDIRECT Template:En dash

Template:R protected each for a grouping of required behavior

  1. REDIRECT Template:En dash

Template:R protected plus other information (outside of a volume).[9] Each volume is assigned an issue number that is the same for each volume of a version, but is not the same value as the version. For example, SUS version 3 (SUSv3) includes volumes labeled issue 6.

since 2014Template:Dated maintenance category (articles)Script error: No such module "Check for unknown parameters"., POSIX documentation is divided into two parts:

  • POSIX.1, 2013 Edition: POSIX Base Definitions, System Interfaces, and Commands and Utilities (which include POSIX.1, extensions for POSIX.1, Real-time Services, Threads Interface, Real-time Extensions, Security Interface, Network File Access and Network Process-to-Process Communications, User Portability Extensions, Corrections and Extensions, Protection and Control Utilities and Batch System Utilities. This is POSIX 1003.1-2008 with Technical Corrigendum 1.)
  • POSIX Conformance Testing: A test suite for POSIX accompanies the standard: VSX-PCTS or the VSX POSIX Conformance Test Suite.[10]

Before 1997

POSIX.1

Core Services (IEEE Std 1003.1-1988) incorporates standard ANSI C and includes:

Process Creation and Control
Signals
Floating Point Exceptions
Segmentation / Memory Violations
Illegal Instructions
Bus Errors
Timers
File and Directory Operations
Pipes
C Library (Standard C)
The POSIX terminal interface

POSIX.1b

Real-time extensions (IEEE Std 1003.1b-1993, later appearing as librt—the Realtime Extensions library) includes:[11]

Priority Scheduling
Real-Time Signals
Clocks and Timers
Semaphores
Message Passing
Shared Memory
Asynchronous and Synchronous I/O
Memory Locking Interface

POSIX.1c

Threads extensions (IEEE Std 1003.1c-1995) includes:

Thread Creation, Control, and Cleanup
Thread Scheduling
Thread Synchronization
Signal Handling

POSIX.2

Shell and Utilities (IEEE Std 1003.2-1992) includes:

Command Interpreter
Utility Programs

POSIX.1-2001

POSIX.1-2001 (IEEE Std 1003.1-2001) consists of most of SUSv3 which consists of volumes (issue 6): Base Definitions, System Interfaces and Headers, and Commands and Utilities. The POSIX specification specifically excludes the SUSv3 requirements for a curses API (often called X/Open Curses, even though there is no distinct grouping of this in SUSv3).[12]

IEEE Std 1003.1-2004 modifies POSIX.1-2001 via two minor updates or errata referred to as technical corrigenda documents.[13][14]

POSIX.1-2008

Similar to its predecessor, POSIX.1-2008 (IEEE Std 1003.1-2008, 2016 Edition) consists of most of the normative material of SUSv4 (issue 7 of volumes Base Definitions, System Interfaces and Headers, Commands and Utilities).[15] SUSv4 also includes rationale information that largely applies to POSIX although not included per se.

POSIX.1-2017

POSIX.1-2017 (IEEE Std 1003.1-2017) revises the previous version (POSIX.1-2008) via two technical corrigenda.[16]

POSIX.1-2024

POSIX.1-2024 (IEEE Std 1003.1-2024) was published on 14 June 2024.[15][17]

As of POSIX 2024, the standard is aligned with the C17 language standard.

Controversies

512- vs 1024-byte blocks

Script error: No such module "Unsubst". POSIX mandates 512-byte default block sizes for the df and du utilities, reflecting the typical size of blocks on disks. When Richard Stallman and the GNU team were implementing POSIX for the GNU operating system, they objected to this on the grounds that most people think in terms of 1024 byte (or 1 KiB) blocks. The environment variable Template:Tt was introduced to allow the user to force the standards-compliant behaviour.[18] The variable name was later changed to Template:Tt.[19] As of 2025, this variable is also used for a number of other behaviour quirks.[20][21][22][23][24][25][26][27][28]

Conformance

An operating system can be classified depending upon the degree of conformance with a POSIX standard.

Certified

Current versions of the following operating systems have been certified to conform to one or more of the various POSIX standards. This means that they passed the automated conformance tests[29] and their certification has not expired and the operating system has not been discontinued.[30][31]

<templatestyles src="Div col/styles.css"/>

Script error: No such module "Check for unknown parameters".

Formerly certified

Some versions of the following operating systems had been certified to conform to one or more of the various POSIX standards. This means that they passed the automated conformance tests. The certification has expired and some of the operating systems have been discontinued.[30]

<templatestyles src="Div col/styles.css"/>

Script error: No such module "Check for unknown parameters".

Partially conformant

The following are not certified as POSIX conforming yet are considered partially conforming which is sometimes called compliant:Script error: No such module "Unsubst".

<templatestyles src="Div col/styles.css"/>

Script error: No such module "Check for unknown parameters".

Partially conformant via compatibility layer Script error: No such module "anchor".

The following operating systems are not certified as POSIX conformant, but they conform in large part to the standard by implementing POSIX support via a compatibility feature (usually translation libraries, or a layer atop the kernel).

Conformance via subsystem

Some technologies allow an operating system to enjoy a level of conformance to POSIX even though the operating system itself has little or no conformance.

For Windows

Although Windows does not conform to POSIX, the following technologies provide a level of compliance.

Cygwin
Provides a largely POSIX-compliant development and run-time environment for Microsoft Windows.
MinGW
A fork of Cygwin, provides a less POSIX-compliant development environment and supports compatible C-programmed applications via Msvcrt, Microsoft's old Visual C runtime library.
libunistd
A largely POSIX-compliant development library originally created to build the Linux-based C/C++ source code of CinePaint as is in Microsoft Visual Studio. A lightweight implementation that has POSIX-compatible header files that map POSIX APIs to call their Windows API counterparts.[61]
Microsoft POSIX subsystem
An optional Windows subsystem included in Windows NT-based operating systems up to Windows 2000. It supported POSIX.1 as it stood in the 1990 revision, without threads or sockets.
Interix
originally OpenNT by Softway Systems, Inc., is an upgrade and replacement for Microsoft POSIX subsystem that was purchased by Microsoft in 1999. It was initially marketed as a stand-alone add-on product and then later included as a component in Windows Services for UNIX (SFU) and finally incorporated as a component in Windows Server 2003 R2 and later Windows OS releases under the name "Subsystem for UNIX-based Applications" (SUA), later made deprecated in 2012 (Windows 8)[62] and dropped in 2013 (2012 R2, 8.1). It enables full POSIX compliance for certain Microsoft Windows products.Script error: No such module "Unsubst".
Windows Subsystem for Linux (WSL)
A compatibility layer for running Linux binary executables natively on Windows 10 and 11 using a Linux image such as Ubuntu, Debian, or OpenSUSE among others, acting as an upgrade and replacement for Windows Services for UNIX. It was released in beta in April 2016. The first distribution available was Ubuntu.
UWIN
From AT&T Research implements a POSIX layer on top of the Win32 APIs.
MKS Toolkit
Originally created for MS-DOS, is a software package produced and maintained by MKS Inc. that provides a Unix-like environment for scripting, connectivity and porting Unix and Linux software to both 32- and 64-bit Microsoft Windows systems. A subset of it was included in the first release of Windows Services for UNIX (SFU) in 1998.[63][64]
Windows C Runtime Library and Windows Sockets API
Implement commonly used POSIX API functions for file, time, environment, and socket access,[65] although the support remains largely incomplete and not fully interoperable with POSIX-compliant implementations.[66][67][discuss]

For OS/2

POSIX environments for OS/2:

emx+gcc
Largely POSIX compliant.

For DOS

POSIX environments for DOS include:

emx+gcc
Largely POSIX compliant
DJGPP
Partially POSIX compliant
DR-DOS
Multitasking core via <templatestyles src="Mono/styles.css" />EMM386 /MULTI – a POSIX threads frontend API extension is available

See also

  1. REDIRECT Template:En dash

Template:R protected set of characters which should be supported in any POSIX-compliant character set locale

References

<templatestyles src="Reflist/styles.css" />

  1. a b c d Script error: No such module "citation/CS1".
  2. Script error: No such module "citation/CS1".
  3. Script error: No such module "citation/CS1".
  4. Script error: No such module "citation/CS1".
  5. Script error: No such module "citation/CS1".
  6. Script error: No such module "citation/CS1".
  7. Script error: No such module "citation/CS1".
  8. Script error: No such module "Citation/CS1".
  9. Script error: No such module "citation/CS1".
  10. Script error: No such module "citation/CS1".
  11. Script error: No such module "citation/CS1".
  12. Script error: No such module "citation/CS1".
  13. Script error: No such module "citation/CS1".
  14. Script error: No such module "citation/CS1"..
  15. a b Script error: No such module "citation/CS1".
  16. Script error: No such module "citation/CS1".
  17. Script error: No such module "citation/CS1"..
  18. Script error: No such module "citation/CS1".
  19. Script error: No such module "citation/CS1".
  20. Script error: No such module "citation/CS1".
  21. Script error: No such module "citation/CS1".
  22. Script error: No such module "citation/CS1".
  23. Script error: No such module "citation/CS1".
  24. Script error: No such module "citation/CS1".
  25. Script error: No such module "citation/CS1".
  26. Script error: No such module "citation/CS1".
  27. Script error: No such module "citation/CS1".
  28. Script error: No such module "citation/CS1".
  29. Script error: No such module "citation/CS1".
  30. a b Script error: No such module "citation/CS1".
  31. Script error: No such module "citation/CS1".
  32. a b Script error: No such module "citation/CS1".
  33. Script error: No such module "citation/CS1".
  34. a b Script error: No such module "citation/CS1".
  35. Script error: No such module "citation/CS1".
  36. Script error: No such module "citation/CS1".
  37. Script error: No such module "citation/CS1".
  38. Script error: No such module "citation/CS1".
  39. Script error: No such module "citation/CS1".
  40. Script error: No such module "citation/CS1".
  41. Script error: No such module "citation/CS1".
  42. Script error: No such module "citation/CS1".
  43. Script error: No such module "citation/CS1".
  44. Script error: No such module "citation/CS1".
  45. Script error: No such module "citation/CS1".
  46. Script error: No such module "citation/CS1".
  47. Script error: No such module "citation/CS1".
  48. Script error: No such module "citation/CS1".
  49. Script error: No such module "Citation/CS1".
  50. Script error: No such module "citation/CS1".
  51. Script error: No such module "citation/CS1".
  52. Script error: No such module "citation/CS1".
  53. Script error: No such module "citation/CS1".
  54. Script error: No such module "citation/CS1".
  55. Script error: No such module "citation/CS1".
  56. Script error: No such module "citation/CS1".
  57. Script error: No such module "citation/CS1".
  58. Script error: No such module "citation/CS1".
  59. Script error: No such module "citation/CS1".
  60. Script error: No such module "citation/CS1".
  61. Script error: No such module "citation/CS1".
  62. Script error: No such module "citation/CS1".
  63. Script error: No such module "citation/CS1".
  64. Script error: No such module "citation/CS1".
  65. Script error: No such module "citation/CS1".
  66. Script error: No such module "citation/CS1".
  67. Script error: No such module "citation/CS1".

Script error: No such module "Check for unknown parameters".

External links

Template:Sister project

  • Script error: No such module "citation/CS1".
  • Script error: No such module "citation/CS1".

Template:Open Group standards Template:IEEE standards Template:ISO standards Template:List of International Electrotechnical Commission standards Template:Inter-process communication Template:Authority control