POSIX Support

From Open Watcom

Revision as of 12:21, 10 May 2012; view current revision
←Older revision | Newer revision→
Jump to: navigation, search

This is an ongoing effort to improve compatibility with the current edition of the Single UNIX Specification and IEEE Std 1003.1.

This is a two-pronged project:

POSIX Operating Systems
These include Linux, possibly QNX, BSD variants (DragonFly BSD, FreeBSD, NetBSD, OpenBSD), or other UNIX systems. The goal is to implement fully compliant POSIX interfaces built on the facilities provided by the underlying operating system. This is obviously a very large project and currently there is much work to do. The Linux clib is rudimentary (though useful) and QNX runtime is incomplete due to missing pieces from QSSL.
Non-POSIX Operating Systems
These include Windows, OS/2, DOS, Netware -- essentially all non-UNIX platforms. The goal is not to provide a complete POSIX environment or 100% adherence to POSIX. Instead, the objective is to implement enough of POSIX to be useful in the real world.

The Single UNIX Specification is considered to be the authoritative source of information for this project.

For non-POSIX platforms, the aim is to support easy porting of command line tools from the UNIX world -- archivers, compression utilities, filters, development tools, etc. It is considered highly desirable to support native conventions where feasible - drive letters, backslashes as path separators, and so on.

Wherever it makes sense, the implementation should share code for POSIX and non-POSIX systems. This is possible in many cases; functions such as strcasecmp() or ffs() are completely platform independent, and functions such as basename() only need minor adjustments for platform differences.

A no longer supported but potentially useful public domain POSIX test suite is available at NIST.

Potentially useful POSIX libs for Win32

  • POSIX threads for Win32: pthreads (LGPL)
  • POSIX API (dll) & env. emulation: UWIN (CPL)
  • UNIXEm: UNIX Emulation Library for Win32: UNIXem (BSD)
  • Thread_emulation.h (quick and dirty minimal pthread-compatible macros): [1] (licence unknown, see text)

See also Unix Style Utilities section from User Resources.

Personal tools