Technical Report (informative) Topic: Conflicts between ISO/IEC 9945 (POSIX) and the Linux Standard Base. Status: Unapproved Draft in Progress Author: Andrew Josey, The Open Group Version 1.1-draft2 Date: 22 July 2004 Change History: This version is updated to report against the latest draft of the Linux Standard Base Core Specification 1.9.8-20040720 (20 July 2004) 001 1.Introduction 002 1.1 Purpose 003 The purpose of this Type 3 Technical Report (informative) is to document 004 the areas of conflict between ISO/IEC 9945 (POSIX) and the Free Standards 005 Group's Linux Standard Base specification such that it can be utilized 006 by the appropriate technical committees when considering harmonization 007 between the standards efforts. 008 ISO/IEC 9945 (POSIX) is an important standard in use throughout the world. 009 There is a significant investment in applications developed for the ISO 010 POSIX standard. With the emergence of a standardization initiative for 011 the Linux operating system there are some areas of conflict that have 012 been identified between the Linux Standard Base specification and the 013 ISO POSIX standards. There is an essential market requirement that the 014 conflicts be resolved so that an application can be written to conform 015 to both standards. Hundreds of millions of dollars of applications are 016 built upon these standards. This report is intended as a starting point 017 to look at resolution of this issue. 018 1.2 Scope 019 The JTC 1/SC 22 Linux Study Group meeting (May 2003) recommended future 020 action towards adopting Linux as a JTC1 standard, and most likely 021 adopting the Linux Standard Base (LSB) specification as a Publicly 022 Available Specification (PAS). The Free Standards Group has attained PAS 023 submitter status to JTC 1. The Free Standards Group intend to submit the 024 LSB for PAS approval. The scope of this technical report is to identify 025 areas of conflict between the LSB 2.0 specification and the ISO/IEC 9945 026 (POSIX) standard. 027 This report is based on the LSB Generic Specification 1.9.8-20040720 028 dated July 2004, and the ISO/IEC 9945:2003 edition dated 15th August 2003 029 with ISO/IEC 9945:2003/Cor.1:2004 (to be published). 030 1.3 Intended Audience 031 032 This document is intended to be submitted to JTC1 as a Technical Report. 033 It is anticipated that they should distribute it to workgroups such 034 as the Austin Group and the Linux Standard Base for which it is in 035 scope. It is also intended to be of interest to systems engineers, 036 technical managers and procurement officers. 037 1.4 Document Overview 038 This document is organized in the following ways: Section two provides 039 a list of differences that could be possible conflicts or extensions in 040 the System Interfaces. Section three provides a list of differences that 041 could be possible conflicts or extensions in the Shell and Utilities. 042 1.5 Acknowledgements 043 Extracts of this document are quoted from the ISO/IEC 9945:2003 and 044 Linux Standard Base documents. 045 Thanks to Paul Eggert for detailed feedback on the Utility Interfaces 046 section of the document. 047 Linux is a registered trademark of Linus Torvalds. 048 LSB is a trademark of the Free Standards Group. 049 POSIX is a registered trademark of the IEEE. 050 2. System Interfaces 051 This section describes possible areas of conflict between the LSB and 052 ISO/IEC 9945 (POSIX) for the System Interfaces. 053 This description is based on the work in progress version of the LSB 054 specification (Linux Standard Base Core Specification 1.9.8-20040720). 055 Note that the descriptions of the known conflicts are taken from the LSB 056 and have not been verified by the Austin Group, thus they may be subject 057 to interpretation of the standard. In some cases, the differences may 058 be upward compatible extensions. In cases where the LSB provides its 059 own API manual page rather than referencing ISO/IEC 9945 then that is 060 noted here and its possible that further investigation might determine 061 that there is no conflict. 062 2.1 Interface definitions 063 2.1.1 creat 064 LSB permits implementations to return ENODEV or ENXIO 065 for non-existent devices, whereas ISO/IEC 9945 requires ENXIO. 066 2.1.2 errno 067 LSB defines ENOTSUP to be EOPNOTSUPP, whereas ISO/IEC 9945 requires 068 that their values be unique. 069 2.1.3 fcntl 070 LSB permits implementation to set O_LARGEFILE 071 According to ISO/IEC 9945, only an application sets fcntl flags, such 072 as O_LARGEFILE. However, the LSB specification also allows implementations 073 to set O_LARGEFILE in a case in which the default behavior matches 074 the O_LARGEFILE behavior, for example off_t is 64 bits. The impact 075 is that applications when calling fcntl with the F_GETFL command may 076 receive the O_LARGEFILE flag set as well as the flags explicitly set by 077 the application. 078 2.1.4 fopen 079 LSB permits implementations to return ENODEV or ENXIO 080 for non-existent devices, whereas ISO/IEC 9945 requires ENXIO. 081 082 2.1.5 freopen 083 LSB permits implementations to return ENODEV or ENXIO 084 for non-existent devices, whereas ISO/IEC 9945 requires ENXIO. 085 2.1.6 getopt 086 The LSB documents a number of GNU extensions to getopt() as 087 well as descriptions of the POSIX requirements. The LSB 088 requires LSB implementations to implement the GNU behavior. 089 The POSIXLY_CORRECT environment variable is documented as a method 090 to obtain ISO/IEC 9945 conforming behavior. 091 A minor editorial observation with the LSB text: 092 1.It refers to "POSIX.2", with the approval of the most recent ISO/IEC 093 9945, the functionality of the former "POSIX.2" (ISO/IEC 9945-2:1993) is 094 included in the revised "POSIX.1", specifically in part 3 of ISO/IEC 9945. 095 2.1.7 ioctl 096 The LSB has its own definition of ioctl() and does not reference ISO/IEC 097 9945. The interface description says that applications may not call 098 ioctl() unless as explicitly described in the LSB. The sockio man page 099 describes a set of socket ioctl() calls. 100 This would imply that an application that uses the ioctl() function 101 as described in ISO/IEC 9945 is not conforming to the LSB. Such an 102 application would be using the XSR option (XSI STREAMS option) within 103 ISO/IEC 9945. 104 2.1.8 iswctype 105 The LSB has its own definition of iswctype() and does not 106 reference ISO/IEC 9945. It appears only to additionally define the 107 return value when WEOF is an argument (although that is written 108 as a Note). 109 2.1.9 kill 110 Process ID -1 doesn't affect calling process 111 If pid is specified as -1, LSB says that sig shall not be sent to the 112 calling process, whereas ISO/IEC 9945 states "If pid is -1, sig shall be 113 sent to all processes (excluding an unspecified set of system processes) 114 for which the process has permission to send that signal.". 115 This was a deliberate Linus decision after an unpopular experiment 116 in including the calling process in the 2.5.1 kernel. See "What does 117 it mean to signal everybody?", Linux Weekly News, 20 December 2001, 118 http://lwn.net/2001/1220/kernel.php3 119 On an editorial note the LSB text for this interface refers to Version 120 2 of the Single UNIX Specification and could be updated to Version 3 121 which is equivalent to ISO/IEC 9945. 122 2.1.10 open 123 LSB permits implementations to return ENODEV or ENXIO 124 for non-existent devices, whereas ISO/IEC 9945 requires ENXIO. 125 126 2.1.11 opterr, optind, optopt 127 The LSB has its own definition of opterr, optind and optopt and does not 128 reference ISO/IEC 9945. 129 2.1.12 strptime 130 The LSB documents an issue with limiting the number of leading zeroes. 131 This may be a conflict and needs further investigation 132 as to the interpretation of ISO/IEC 9945 . 133 LSB states: 134 "Number of leading zeroes limited 135 The Single UNIX Specification, Version 2 specifies fields for which 136 "leading zeros are permitted but not required"; however, applications must 137 not expect to be able to supply more leading zeroes for these fields than 138 would be implied by the range of the field. Implementations may choose 139 to either match an input with excess leading zeroes, or treat this as 140 a non-matching input. For example, %j has a range of 001 to 366, so 0, 141 00, 000, 001, and 045 are acceptable inputs, but inputs such as 0000, 142 0366 and the like are not. 143 Rationale 144 glibc developers consider it appropriate behavior to forbid excess 145 leading zeroes. When trying to parse a given input against several format 146 strings, forbidding excess leading zeroes could be helpful. For example, 147 if one matches 0011-12-26 against %m-%d-%Y and then against %Y-%m-%d, 148 it seems useful for the first match to fail, as it would be perverse to 149 parse that date as November 12, year 26. The second pattern parses it 150 as December 26, year 11. 151 The Single UNIX Specification is not explicit that an unlimited 152 number of leading zeroes are required, although it may imply this. 153 The LSB explicitly allows implementations to have either behavior. 154 Future versions of this standard may require implementations to forbid 155 excess leading zeroes." 156 On an editorial note the LSB text for this interface refers to Version 157 2 of the Single UNIX Specification and could be updated to Version 3 158 which is equivalent to ISO/IEC 9945. 159 2.1.13 strtok_r 160 The LSB has its own definition of strtok_r() and does not 161 reference ISO/IEC 9945. 162 On an editorial note the LSB text says under BUGS, "Never use this 163 function". 164 2.1.14 system 165 The LSB has its own definition of system() and does not 166 reference ISO/IEC 9945. 167 On an editorial note it refers to POSIX.2, this should be 168 updated to ISO/IEC 9945-2:2003 (the System Interfaces volume). 169 2.1.15 unlink 170 May return EISDIR on directories 171 The LSB states that if path specifies a directory, a return 172 of EISDIR is permitted instead of EPERM as required by ISO/IEC 9945. 173 LSB notes that "The Linux kernel has deliberately chosen EISDIR for this 174 case and does not expect to change (Al Viro, personal communication)." 175 On an editorial note the LSB text for this interface refers to Version 176 2 of the Single UNIX Specification and could be updated to Version 3 177 which is equivalent to ISO/IEC 9945. 178 2.1.16 waitid 179 The LSB has removed the waitid() function, whereas it is a first 180 class function in ISO/IEC 9945 (but in the XSI option group). 181 2.1.17 waitpid 182 The LSB does not require implementations to support the 183 WCONTINUED or WIFCONTINUED functionality within waitpid(). 184 3. Shell and Utilities Interfaces 185 This section describes possible areas of conflict between the LSB and 186 ISO/IEC 9945 (POSIX) for the Shell and Utilities. 187 This description is based on the work in progress version of the LSB 188 specification (LSB Generic 1.9.8). Note that the descriptions of 189 the known conflicts are taken from the LSB and have not been verified 190 by the Austin Group, thus they may be subject to interpretation of the 191 standard. Deprecated differences are not listed since they are assumed 192 to be removed at some future point. 193 In some cases, the differences may be upward compatible extensions. In 194 cases where the LSB provides its own API manual page rather than 195 referencing ISO/IEC 9945 then that is noted here and its possible that 196 further investigation might determine that there is no conflict. 197 3.1 Utility definitions 198 3.1.1 ar 199 The ar utility is deprecated in the LSB. 200 3.1.2 at 201 The LSB lists the following differences: 202 -d is functionally equivalent to the -r option specified in ISO/IEC 9945 203 -r need not be supported on LSB implementations, but the '-d' option 204 is equivalent. 205 -t time 206 need not be supported. 207 The files at.allow and at.deny reside in /etc rather than /usr/lib/cron 208 on LSB implementations. 209 3.1.3 awk 210 The LSB lists the following differences: 211 Certain aspects of internationalized regular expressions are optional. 212 3.1.4 batch 213 The LSB lists the following differences: 214 The files at.allow and at.deny reside in /etc rather than /usr/lib/cron 215 on LSB implementations. 216 3.1.5 bc 217 In order to obtain ISO/IEC 9945 conforming behavior, applications 218 are required to use the -s or --standard option to bc. 219 The -w option can provide warnings for bc extensions being 220 used over the ISO/IEC 9945 definition. 221 3.1.6 chgrp 222 The -L, -H, and -P options need not be supported by LSB implementations. 223 ISO/IEC 9945 defines these options for manipulating symbolic 224 links. 225 On an editorial note, the "Name" line in this draft states "chown". 226 Bug #388 has been submitted. 227 3.1.7 chown 228 The -L, -H, and -P options need not be supported by LSB implementations. 229 ISO/IEC 9945 defines these options for manipulating symbolic 230 links. 231 3.1.8 crontab 232 The LSB lists the following differences: 233 The files at.allow and at.deny reside in /etc rather than /usr/lib/cron 234 on LSB implementations. 235 3.1.9 cut 236 The LSB lists the following difference: 237 -n has unspecified behavior. 238 ISO/IEC 9945 defines the behavior of "-n" 239 Do not split characters. When specified with the -b option, each 240 element in list of the form low- high (hyphen-separated numbers) 241 shall be modified as follows: 242 * If the byte selected by low is not the first byte of a character, 243 low shall be decremented to select the first byte of the character 244 originally selected by low. If the byte selected by high is not 245 the last byte of a character, high shall be decremented to select 246 the last byte of the character prior to the character originally 247 selected by high, or zero if there is no prior character. If the 248 resulting range element has high equal to zero or low greater than 249 high, the list element shall be dropped from list for that input 250 line without causing an error. 251 Each element in list of the form low- shall be treated as above with 252 high set to the number of bytes in the current line, not including 253 the terminating . Each element in list of the form - high 254 shall be treated as above with low set to 1. Each element in list 255 of the form num (a single number) shall be treated as above with 256 low set to num and high set to num. 257 3.1.10 df 258 The LSB lists the following differences: 259 If the -k option is not specified, disk space is shown in unspecified 260 units. Applications should specify -k. 261 If an argument is the absolute file name of a disk device node containing 262 a mounted filesystem, df shows the space available on that filesystem 263 rather than on the filesystem containing the device node (which is always 264 the root filesystem). 265 3.1.11 du 266 The LSB lists the following differences: 267 If the -k option is not specified, disk space is shown in unspecified units. 268 Applications should specify -k. 269 3.1.12 echo 270 Unlike the behavior specified in ISO/IEC 9945, LSB states that support for 271 options is implementation defined, and that the behavior of echo if any 272 arguments contain backslashes is also implementation defined. Applications 273 are advised not to run echo with a first argument starting with a hyphen, 274 or with any arguments containing backslashes; they must use printf in 275 those cases. 276 The behavior specified here is similar to that specified by the Single UNIX 277 Specification version 3 without the XSI option. However, the LSB forbids all 278 options and the former forbids only -n. 279 3.1.13 file 280 The LSB lists the following differences: 281 The -M, -h, -d, and -i options need not be supported. 282 3.1.14 find 283 The LSB lists the following differences: 284 Certain aspects of internationalized filename globbing are optional. 285 3.1.15 fuser 286 The LSB lists the following differences: 287 -c has unspecified behavior. 288 -f has unspecified behavior. 289 3.1.16 grep 290 The LSB lists the following differences: 291 Certain aspects of internationalized regular expressions are optional. 292 3.1.17 ipcrm 293 The LSB has its own definition of ipcrm and does not 294 reference ISO/IEC 9945. 295 3.1.18 ipcs 296 The LSB has its own definition of ipcs and does not 297 reference ISO/IEC 9945. 298 3.1.19 ls 299 The LSB lists the following differences: 300 -p 301 in addition to the behavior of printing a slash for a directory, 302 ls -p may display other characters for other file types. 303 Since the ISO/IEC 9945 only defines the behavior for directories 304 this appears to be an upward compatible extension. 305 The LSB states that certain aspects of internationalized filename globbing 306 are optional. 307 3.1.20 m4 308 The LSB lists these as differences, 309 -P forces a m4_ prefix to all builtins. 310 -I directory 311 Add directory to the end of the search path for includes. 312 These appear to be upward compatible extensions. 313 3.1.21 more 314 The LSB lists these as differences, 315 The more command need not respect the LINES and COLUMNS environment 316 variables. 317 The more command need not support the following interactive commands: 318 g 319 G 320 u 321 control u 322 control f 323 newline 324 j 325 k 326 r 327 R 328 m 329 ' (return to mark) 330 /! 331 ? 332 N 333 :e 334 :t 335 control g 336 ZZ 337 -num 338 specifies an integer which is the screen size (in lines). 339 -e 340 has unspecified behavior. 341 -i 342 has unspecified behavior. 343 -n 344 has unspecified behavior. 345 -p 346 Either (1) clear the whole screen and then display the text (instead 347 of the usual scrolling behavior), or (2) provide the behavior 348 specified by ISO/IEC 9945. In the latter case, the syntax is 349 "-p command". 350 -t 351 has unspecified behavior. 352 3.1.22 newgrp 353 The LSB has its own definition of newgrp and does not 354 reference ISO/IEC 9945. 355 Its unclear if there are any semantic differences. 356 3.1.23 od 357 The LSB lists these as differences. 358 -w, --width[=BYTES] 359 outputs BYTES bytes per output line. 360 --traditional 361 accepts arguments in pre-POSIX form described below 362 Pre-POSIX Specifications 363 The LSB supports option intermixtures with the following pre-POSIX 364 specifications: 365 -a 366 is equivalent to -t a, selects named characters. 367 -f 368 is equivalent to -t fF, selects floats. 369 -h 370 is equivalent to -t x2, selects hexadecimal shorts. 371 -i 372 is equivalent to -t d2, selects decimal shorts. 373 -l 374 is equivalent to -t d4, selects decimal longs. 375 3.1.24 patch 376 The LSB lists the following differences: 377 --binary 378 reads and write all files in binary mode, except for standard output 379 and /dev/tty. This option has no effect on POSIX-compliant systems. 380 -u, --unified 381 interprets the patch file as a unified context diff. 382 3.1.25 renice 383 The LSB lists the following differences: 384 -n increment 385 has unspecified behavior. 386 3.1.26 sed 387 The LSB lists the following differences: 388 Certain aspects of internationalized regular expressions are optional 389 3.1.27 xargs 390 The LSB lists the following differences: 391 -E 392 has unspecified behavior. 393 -I 394 has unspecified behavior. 395 -L 396 has unspecified behavior. 397 3.2 Internationalization 398 The LSB makes certain internationalization aspects optional. 399 3.2.1 Regular Expressions 400 Utilities that process regular expressions shall support Basic Regular 401 Expressions and Extended Regular Expressions as specified in ISO/IEC 9945 402 with the following exceptions: 403 Range expression (such as [a-z]) can be based on code point order instead 404 of collating element order. 405 Equivalence class expression (such as [=a=]) and multi-character collating 406 element expression (such as [.ch.]) are optional. 407 Handling of a multi-character collating element is optional. 408 This affects at least the following utilities: grep (including 409 egrep), sed, and awk. 410 3.2.2 Filename Globbing 411 Utilities that perform filename globbing (also known as Pattern Matching 412 Notation) shall do it as specified in ISO/IEC 9945 with the following 413 exceptions: 414 Range expression (such as [a-z]) can be based on code point order instead 415 of collating element order. 416 Equivalence class expression (such as [=a=]) and multi-character collating 417 element expression (such as [.ch.]) are optional. 418 Handling of a multi-character collating element is optional. 419 APPENDIX A 420 This appendix contains background information on the POSIX 421 Standards and the Linux Standard Base specification. 422 A1. POSIX Standards 423 The POSIX standards, are the foundations of the UNIX system and Linux 424 API sets. The development body for the POSIX standards has been 425 the IEEE in association with ISO/JTC1/SC22/WG15. 426 This section provides an overview of the POSIX standards. 427 A1.1 The Portable Application Standards Committee (PASC) 428 The IEEE Computer Society's Portable Application Standards Committee 429 (PASC) is the group that has and continues to develop the POSIX family 430 of standards. Historically, the major work has been undertaken within 431 Project 1003 (POSIX) with the best known standard being IEEE Std 1003.1 432 (also known as POSIX 1003.1, colloquially termed "dot 1"). The goal of 433 the PASC standards has been to promote application portability at the 434 source code level. 435 More Information about the Portable Application Standards Committee 436 (PASC) is available from: 437 http://www.pasc.org 438 A1.2 IEEE POSIX 1003.1 System Application Interface (C API) 439 Historically, this has been the base standard upon which the POSIX 440 family of standards has been built. In keeping with its original focus 441 on the UNIX system, it is aimed at interactive timesharing computing 442 environments. The latest version of this standard was produced by the 443 Austin Group (see later). In general the Linux operating system 444 aims to comply with the POSIX 1003.1 standard. 445 The first edition of IEEE Std 1003.1 was published in 1988. Subsequent 446 editions were published in 1990, 1996 and 2001. The 1990 edition was a 447 revision to the 1988 edition and became the stable base standard onto 448 which further amendments were added. The 1990 edition was also approved 449 as an international standard, ISO/IEC 9945-1:1990. 450 The 1996 edition added the IEEE Std 1003.1b-1993, IEEE Std 1003.1c-1995, 451 and 1003.1i-1995 amendments to the base standard, keeping the stable core 452 text unchanged. The 1996 edition of IEEE Std 1003.1 was also approved 453 as an international standard, ISO/IEC 9945-1:1996. 454 In 1998 the first real-time profile standard, IEEE Std 1003.13-1998 was 455 published, enabling POSIX to address embedded real-time applications 456 and smaller footprint devices. 457 In 1999 the decision was taken to commence the first major revision to 458 the core base standard in ten years, including a merger with the 1003.2 459 standards for Shell and Utilities which had been a separate standard 460 up to this point . It was agreed that this work be undertaken by the 461 Austin Group (see later ). As part of this decision the PASC decided 462 to cease rolling amendments to the base standard after completion of 463 IEEE Stds 1003.1a, 1003.1d, 1003.1g, 1003.1j, 1003.1q, and 1003.2b. 464 These projects were rolled into the 2001 edition of IEEE Std 1003.1. 465 It was decided to convert other projects in progress to standalone 466 documents. 467 A1.3 IEEE POSIX 1003.2 Shell and Utilities 468 This standard defines a standard source level interface to the shell 469 and utility functionality required by application programs, including 470 shell scripts. This standard has been incorporated into the IEEE Std 471 1003.1-2001 produced by the Austin Group. The compliance level 472 of the Linux operating system is harder to determine for the 473 shell and utilities. 474 A1.4 IEEE POSIX Standards for Real-time 475 The PASC Real-time System Services Working Group (SSWG-RT) has developed 476 a series of standards that amend IEEE Std 1003.1-1990 and a profile 477 standard (IEEE Std 1003.13-1998). 478 The Real-time amendments to IEEE Std 1003.1-1990 are as follows: 479 IEEE Std 1003.1b-1993 Realtime Extension 480 IEEE Std 1003.1c-1995 Threads 481 IEEE Std 1003.1d-1999 Additional Realtime Extensions 482 IEEE Std 1003.1j-2000 Advanced Realtime Extensions 483 IEEE Std 1003.1q-2000 Tracing 484 These have all been folded in as options within the revision project 485 undertaken by the Austin Group (see below). 486 The Real-time profile is known as IEEE Std 1003.13-1998. At the time 487 of writing there is a revision to IEEE Std 1003.13-1998 in progress to 488 align it with IEEE Std 1003.1-2001, this project current known as IEEE 489 P1003.13-200x. 490 A1.5 The Austin Group 491 The Austin Group is the working group that manages the POSIX.1 492 specificaton. It is a joint working group of members of the IEEE Portable 493 Applications Standards Committee, members of The Open Group, and members 494 of ISO/IEC Joint Technical Committee 1. Participation is free and open 495 to all interested parties. 496 The Austin Group arose out of discussions amongst the parties which 497 started in early 1998, which led to an initial meeting and formation 498 of the group in September 1998. The purpose for this group has 499 been to revise, combine, and update the following standards: ISO/IEC 500 9945-1, ISO/IEC 9945-2, IEEE Std 1003.1, IEEE Std 1003.2, and the Base 501 Specifications of The Open Group Single UNIX Specification. 502 After two meetings, an agreement was signed in July 1999 between The 503 Open Group and the Institute of Electrical and Electronics Engineers 504 (IEEE), Inc., to formalize the project with the first draft of the 505 revised specifications ("the revision") being made available at the 506 same time. Under this agreement, The Open Group and IEEE agreed to share 507 joint copyright of the resulting work. 508 The base document for the revision was The Open Group's Base volumes 509 of its Single UNIX Specification, Version 2. These were selected since 510 they were a superset of the existing POSIX.1 and POSIX.2 specifications 511 and had some organizational aspects that would benefit the audience for 512 the new revision. 513 The approach to specification development has been one of "write once, 514 adopt everywhere", with the deliverables being a set of specifications 515 that carry the IEEE POSIX designation, The Open Group's Technical 516 Standard designation, and an ISO/IEC designation (see below). This set of 517 specifications also forms the core of the Single UNIX Specification, Version 3. 518 The Open Group and the IEEE approved the Austin Group specifications in 519 late 2001, as The Open Group Base Specifications, Issue 6, and IEEE Std 520 1003.1-2001 respectively. ISO/IEC approval followed about twelve 521 months later. 522 The Austin Group Specifications consist of the following : 523 * Base Definitions, Issue 6 (XBD) 524 * Shell and Utilities, Issue 6 (XCU) 525 * System Interfaces, Issue 6 (XSH) 526 * Rationale (Informative) 527 The revision has tried to minimize the number of changes that 528 implementations which conform to the earlier versions of the approved 529 standards would require to bring them into conformance with the current 530 standard. Specifically, the scope of the project excluded doing any 531 ``new'' work, but rather collecting into a single document what had 532 been spread across a number of documents, and presenting it in what 533 had been proven in practice to be a more effective way. Some changes 534 to prior conforming implementations were unavoidable, primarily as a 535 consequence of resolving conflicts found in prior revisions, or which 536 became apparent when bringing the various pieces together. Also, since 537 the revision now references the 1999 version of the ISO C standard, 538 there are a number of unavoidable changes that have been made which will 539 affect applications portability. 540 The 2004 edition of the 1003.1 standard was published on April 30th 541 2004, and updates the 2001 edition of the standard to include Technical 542 Corrigendum 1 (TC1) and Technical Corrigendum 2 (TC2). The 2004 Edition 543 is formally known as: 544 IEEE Std 1003.1, 2004 Edition 545 The Open Group Technical Standard Base Specifications, Issue 6 546 547 Includes IEEE Std 1003.1-2001, IEEE Std 1003.1-2001/Cor 1-2002 and 548 IEEE Std 1003.1-2001/Cor 2-2004 549 More information on the Austin Group, including how to join and 550 participate is available from its web site at 551 http://www.opengroup.org/austin/ 552 A html version of the specification is freely available from 553 The Open Group's Single UNIX Specification web site at 554 http://www.unix.org/version3/ 555 A1.5.1 Relationship to the ISO C Standard 556 The most recent revision to the ISO C standard occurred in 1999. 557 The ISO C standard is itself independent of any operating system in so 558 much as it may be implemented in many environments including 559 hosted environments. 560 The POSIX and Single UNIX Specification have a long history 561 of building on the ISO C standard and deferring to it where applicable. 562 Revisions of POSIX.1 prior to the Austin Group specification built upon 563 the ISO C standard by reference only, and also allowed support for traditional 564 C as an alternative. The Single UNIX Specification in contrast, 565 included manual pages for the ISO C interfaces. 566 The Austin Group took the latter approach. The standard 567 developers believed it essential for a programmer to have a single 568 complete reference place. They also recognized that deference to the formal 569 standard had to be addressed for the duplicate interface definitions 570 which occur in both the ISO C standard and their document. 571 It was agreed that where an interface has a version in the ISO C standard, 572 the DESCRIPTION section should describe the relationship to the ISO C 573 standard and markings added as appropriate within the manual page to 574 show where the ISO C standard has been extended. 575 A block of text was added to the start of each affected reference 576 page stating whether the page is aligned with the ISO C standard or 577 extended. Each page was parsed for additions beyond the ISO C standard 578 (that is, including both POSIX and UNIX extensions), and these extensions 579 are marked as CX extensions (for C Extensions). 580 A1.6 ISO/IEC 9945 581 In late 2002, the ISO/IEC Joint Technical Committee approved the joint 582 revision to POSIX and the Single UNIX Specification as an International 583 Standard. Designated as ISO/IEC 9945:2002, the joint revision forms 584 the core of The Open Group's Single UNIX Specification Version 3 (IEEE 585 1003.1-2001, POSIX.1). 586 The combining of the IEEE POSIX specifications and the Single UNIX 587 Specification into ISO/IEC 9945:2002 Parts 1 to 4 replaces the existing 588 ISO/IEC 9945-1:1996 (IEEE 1003.1, 1996 version), and ISO/IEC 9945-2:1993 589 (IEEE Std 1003.2, 1992 version). 590 ISO/IEC 9945 consists of the following parts, under the general title 591 Information technology Portable Operating System Interface (POSIX): 592 Part 1: Base Definitions 593 Part 2: System Interfaces 594 Part 3: Shell and Utilities 595 Part 4: Rationale 596 The 2003 Edition of the Austin Group specifications was published as 597 ISO/IEC 9945:2003 on August 15 2003. 598 The latest technical corrigendum is due to be published 599 shortly and is designated as ISO/IEC 9945:2003/Cor.1:2004. 600 A2.2 The Linux Standard Base Specification 601 The Linux Standard Base (LSB) Specification is an application binary 602 interface standard for shrink-wrapped applications. The purpose is to 603 allow commonality amongst the many Linux distributions. 604 The LSB draws on the source standards of IEEE POSIX 1003.1-1990 and The 605 Open Group Single UNIX Specification for many of its interfaces although 606 does not formally defer to them preferring to document any differences 607 where they exist, such as where certain aspects of Linux cannot currently 608 conform to the industry standards, one particular example being the area 609 of threads. Some interfaces are not included in the LSB, since they 610 are outside the remit of a binary runtime environment, typically these 611 are development interfaces or user level tools . The LSB also extends 612 the source standards in other areas (such as graphics), and includes the 613 necessary details such as the binary execution file formats to support 614 a high volume application platform. 615 Although in theory the LSB is not tied to the GNU/Linux operating system, 616 in practise the binary definitions are tightly coupled to the Linux operating 617 system and the GNU C compiler. 618 The LSB is available as a family of specifications supporting a 619 number of processor architectures including IA32, PPC32, PPC64, IA64, 620 S390 and S390X. There is a generic specification, common to all the 621 processor architectures known as the "generic LSB" (or gLSB), and for 622 each processor architecture an architecture-specific specification 623 ("archLSB") describing the details that vary by processor architecture. 624 To support the specification, the LSB includes a number of 625 development tools, including test suites, and a set of reference 626 conforming applications. Binary versions of the test suites and 627 reference applications are used for formal LSB certification of runtime 628 environments. All the major Linux vendors today have certified LSB 629 systems. 630 LSB 1.2, introduced in January 2002, was the first version of the 631 specification to have an equivalent LSB certification program. LSB 1.2 632 certification, which commenced in July 2002 is limited to the IA32 ABI. 633 LSB 1.3 certification includes additional support for the IA64, PPC32, 634 PPC64, S390 and S390X architectures. At the time of writing there are 635 twenty-two certified runtime environments from 9 vendors. 636 The specification is evolving quite rapidly. LSB 1.3, introduced in 637 January 2003, adds some internationalization, PAM, packaging, static C++ 638 linking, bug fixes, plus IA64, PPC32, and soon PPC64, S390, and S390X. 639 LSB 2.0 is planned for 2H2004. 640 Detailed information on the LSB is available from: 641 http://www.linuxbase.org 642 643 Detailed information on the LSB Certification Program is available 644 from the LSB Certification Authority at 645 http://www.opengroup.org/lsb/cert/ 646 The Guide to LSB Certification is available at: 647 http://www.opengroup.org/lsb/cert/docs/LSB_Certification_Guide.html 648 The LSB Certification Register can be viewed at: 649 http://www.opengroup.org/lsb/cert/register.html