This topic was published by DevynCJohnson and viewed 76 times since "". The last page revision was "".
- Topics - 444
Computer and communication systems require standards and protocols to ensure that systems using such standards can efficiently and effectively communicate with one another. Also, standards ensure compatibility and a common framework for developers to use. Standards, protocols, and other specifications make programming and telecommunications easy, predictable, compatible, and universal. Obviously, Linux has standards that it follows. Besides the standards that are common to all computer operating systems (like TCP/IP and IEEE 802.11), there are standards that are specific to Unix, POSIX, and Linux systems. There is a lot that can be learned about various standards that pertain to Linux.
NOTE: Linux is a "Unix-like" and "mostly POSIX-compliant" system. This indicates that Linux follows most POSIX and Unix standards.
Linux Standard Base (LSB)
The Linux Standard Base (LSB) is an ISO standard for GNU/Linux. The main purpose of the LSB standard is to keep all Linux distros compatible with each other and standardized. Notice that the Linux Standard Base (LSB) is a standard among Linux distros, but not Unix systems. Yet, some of the adopted specifications (like POSIX) are used among Unix and Unix-like systems. LSB includes several other standards such as POSIX. LSB sets standards for various portions of Linux systems including run levels, file system hierarchy, and many other subsystems. The LSB standard supports seven architectures - IA32, IA64, PPC32, PPC64, S390, S390X, and x86-64. The LSB standard itself (not a contained specification) requires support for large files. The LSB standard includes many "stand-alone" standards as listed below.
- DWARF Debugging Information Format - This is a format used by debuggers and compilers for reporting bugs.
- Filesystem Hierarchy Standard (FHS)
- IEC 60559/IEEE 754 Floating Point - Floating-point computation standard
- ISO C
- ISO/IEC TR14652 - Character format specification
- Itanium C++ ABI
- ITU-T V.42 - Error correction standard
- Li18nux Globalization Specification - Linux internationalization specifications
- Linux Allocated Device Registry - Each type of /dev/ file has a special and official number set by the registry
- Mozilla's NSS SSL Reference - This is a reference for Network Security Services and Secure Socket Layer
- Portable Operating System Interface (POSIX)
- NSPR Reference - This is a reference for Netscape Portable Runtime (NSPR)
- RFC 791 - Internet Protocols
- RFC 1321 - The MD5 Message-Digest Algorithm
- RFC 1831/1832 - Remote Procedure Call Protocol Specification
- RFC 1833 - Binding Protocols for ONC RPC
- RFC 1950 - ZLIB Compressed Data Format Specification
- RFC 1951 - DEFLATE Compressed Data Format Specification
- RFC 1952 - GZIP File Format Specification
- RFC 2440 - OpenPGP Message Format
- RFC 2821 - Simple Mail Transfer Protocol (SMTP)
- RFC 2822 - Internet Message Format
- RPM Package Format - RPM installation package standard
- Single UNIX Specification (SUS)
- System V ABI - System V Application Binary Interface specification
- System V Interface Definition (SVID)
- X/Open-Curses - A standard for ncurses (text-based interface)
NOTE: ABI stands for Application Binary Interface. An ABI is the interface between the software and the operating system.
NOTE: An ISO standard is a standard set by the International Organization for Standardization (ISO). ISO sets various standards; not all pertain to computers.
Cygnus (Cygnus, Your GNU Support) is a deprecated standard for porting GNU software to Windows and Unix systems. This standard was made by "Cygnus Solutions", the original developers of Cygwin (GNU + Cygnus + Windows = Cygwin).
Filesystem Hierarchy Standard (FHS)
The Filesystem Hierarchy Standard (http://refspecs.linuxfoundation.org/FHS_3.0/fhs-3.0.html) is made by the Linux Foundation, and specifies the file and directory layout. This standard is to be followed by Linux system, although some Unix systems may optionally comply.
Gnits (GNU nit-pickers) Standards is a set of specifications and recommendations for distributing, maintaining, and programming software. Most of these "standards" are just advice. The Gnits Standards also act as improvements and unofficial additions to the GNU Coding Standards. The Gnits Standards pertain to program interface and interaction, documentation, software behavior, etc. Automake can apply the Gnits Standards (https://www.gnu.org/software/automake/manual/html_node/Gnits.html).
FUN FACT: At the time of writing this article (Aug. 23, 2015), the Gnits Standard has not been officially written or released.
GNU Coding Standards
The GNU Coding Standards (http://www.gnu.org/prep/standards/) is a specification that provides recommendations and rules for programming software that will execute in the GNU userland or environment. Below are some examples of rules and recommendations. For the complete standards, visit the GNU website.
- Format for many C programming language constructs
- Treat code blocks as statements (for indentation)
- Mandatory space before parentheses
- Closing braces, brackets, and parentheses appear to the right or in the same column of the corresponding opening delimiter
- Write programming comments in English
- Use complete, capitalized sentences as comments
- Programs must be able to operate when /usr/ and /etc/ are mounted read-only
- Unix portability is recommended
- No GNU support for 16-bit systems
- 32-bit and 64-bit GNU support is required
FUN FACT: The GNU C Library (glibc) is compliant with the ISO C and POSIX standards.
Portable Operating System Interface (POSIX)
The Portable Operating System Interface, or POSIX, (http://www.unix.org/version4/ieee_std.html && http://pubs.opengroup.org/onlinepubs/9699919799/) defines a standard operating system interface and shell environment. POSIX is defined by the IEEE Computer Society and is the core of the Single UNIX Specification (SUS).
Single UNIX Specification (SUS)
The Single UNIX Specification (http://www.unix.org/what_is_unix/single_unix_specification.html) sets requirements for systems to be considered a true Unix operating system. Unix-like systems are operating systems that do not fully satisfy the standard. The different versions of the Unix standard are designated as UNIX93, UNIX95, UNIX98, and UNIX03. Obviously, they were made in 1993, 1995, 1998, and 2003, respectively. HP-Unix and Mac OS X are examples of two commonly used Unix systems. Linux and *BSD are considered Unix-like because they do not satisfy all of the criteria in SUSv3 (UNIX03).
SUSv3 defines 1742 interfaces and spans over 3700 pages. The SUS standard includes the "X/Open Curses" specification and is divided into four parts listed below.
- Base Definitions (XBD) - lists and defines terms and conventions used in SUS; list of eighty-four required C-header files
- Shell and Utilities (XCU) - lists 160 commands/utilities required for the POSIX shell (#!/bin/sh) and requirements for the command-line environment
- System Interfaces (XSH) - defines system calls and library functions (1123 system interfaces total)
- Rationale (XRAT) - explains the need for SUS
- POSIX:2008 (IEEE Std 1003.1-2008) is the core of SUSv4 and POSIX:2001 (IEEE Std 1003.1-2001) is the core of SUSv3 and UNIX03.
- UNIX03 Specification - http://www.unix.org/unix03.html
- SUSv3 Specification - http://www.unix.org/version3/
- SUSv4 Specification - http://www.unix.org/version4/
FUN FACT: All Unix systems are POSIX compliant, but not all POSIX systems are Unix systems (SUS-compliant).
System V (sometimes called "Unix System V" or "SysV") is the old Unix standard by AT&T. System V inter-process communication is still used in Linux. However, POSIX:2008 defines a replacement for such inter-process communication. Modern Unix systems follow the Single UNIX Specification (SUS).
FUN FACT: Plan 9 (an OS by Bell Labs) was intended to develop a new standard to improve and replace Unix and POSIX standards.
System V Interface Definition (SVID)
The System V Interface Definition (http://www.sco.com/developers/devspecs/) covers various AT&T UNIX System V behaviors such as C-libraries, system calls, software, and hardware management. SVID v4 was updated and published in 1995 and includes compliance with XPG4 and POSIX (1003.1-1990). SVID is a subset of System V.
X/Open Portability Guide (XPG)
XPG defines SQL data-access interfaces, internationalization, terminal interfaces, inter-process communication, general OS interfaces, and other interfaces. XPG contains the X/Open-Curses standard. XPG merged with POSIX.
All of these specifications, references, protocols, etc. are very important in making Linux distros standard and compatible with other distros and computer operating systems. Some of these standards are also used in Unix systems and Unix-like systems. If these specifications were followed entirely among all operating systems, then more software could be cross-platform and compatible.
- Mozilla's NSS SSL Reference - https://developer.mozilla.org/en-US/docs/NSS_reference
- Linux Standard Base (LSB) - http://dcjtech.info/topic/linux-standard-base-lsb/