1 Linux Standard Base Core Specification 2.0.1 2 3 Copyright ? 2004 Free Standards Group 4 5 Permission is granted to copy, distribute and/or modify this document under the 6 terms of the GNU Free Documentation License, Version 1.1; with no Invariant 7 Sections, with no Front-Cover Texts, and with no Back-Cover Texts. A copy of 8 the license is included in the section entitled "GNU Free Documentation 9 License". 10 11 Portions of the text are copyrighted by the following parties: 12 13 * The Regents of the University of California 14 15 * Free Software Foundation 16 17 * Ian F. Darwin 18 19 * Paul Vixie 20 21 * BSDI (now Wind River) 22 23 * Andrew G Morgan 24 25 * Jean-loup Gailly and Mark Adler 26 27 * Massachusetts Institute of Technology 28 29 These excerpts are being used in accordance with their respective licenses. 30 31 Linux is a trademark of Linus Torvalds. 32 33 UNIX a registered trademark of the Open Group in the United States and other 34 countries. 35 36 LSB is a trademark of the Free Standards Group in the USA and other countries. 37 38 AMD is a trademark of Advanced Micro Devices, Inc. 39 40 Intel and Itanium are registered trademarks and Intel386 is a trademarks of 41 Intel Corporation. 42 43 OpenGL is a registered trademark of Silicon Graphics, Inc. 44 45 Table of Contents 46 Specification Introduction 47 ELF Specification 48 Linux Standard Base Specification 49 Linux Packaging Specification 50 Free Documentation License 51 52 Specification Introduction 53 54 ------------------------------------------------------------------------------- 55 56 Table of Contents 57 Foreword 58 Introduction 59 I. Introductory Elements 60 61 1. Scope 62 63 General 64 Module Specific Scope 65 66 2. Normative References 67 3. Requirements 68 69 Relevant Libraries 70 LSB Implementation Conformance 71 LSB Application Conformance 72 73 4. Definitions 74 5. Terminology 75 6. Documentation Conventions 76 77 List of Tables 78 2-1. Normative References 79 3-1. Standard Library Names 80 3-2. Standard Library Names defined in the Architecture Specific Supplement 81 82 ------------------------------------------------------------------------------- 83 84 Foreword 85 86 This is version 2.0.1 of the Linux Standard Base Core Specification. An 87 implementation of this version of the specification may not claim to be an 88 implementation of the Linux Standard Base unless it has successfully completed 89 the compliance process as defined by the Free Standards Group. 90 91 ------------------------------------------------------------------------------- 92 93 Introduction 94 95 The LSB defines a binary interface for application programs that are compiled 96 and packaged for LSB-conforming implementations on many different hardware 97 architectures. Since a binary specification shall include information specific 98 to the computer processor architecture for which it is intended, it is not 99 possible for a single document to specify the interface for all possible 100 LSB-conforming implementations. Therefore, the LSB is a family of 101 specifications, rather than a single one. 102 103 This document should be used in conjunction with the documents it references. 104 This document enumerates the system components it includes, but descriptions of 105 those components may be included entirely or partly in this document, partly in 106 other documents, or entirely in other reference documents. For example, the 107 section that describes system service routines includes a list of the system 108 routines supported in this interface, formal declarations of the data 109 structures they use that are visible to applications, and a pointer to the 110 underlying referenced specification for information about the syntax and 111 semantics of each call. Only those routines not described in standards 112 referenced by this document, or extensions to those standards, are described in 113 the detail. Information referenced in this way is as much a part of this 114 document as is the information explicitly included here. 115 116 I. Introductory Elements 117 118 Table of Contents 119 1. Scope 120 2. Normative References 121 3. Requirements 122 4. Definitions 123 5. Terminology 124 6. Documentation Conventions 125 126 ------------------------------------------------------------------------------- 127 128 Chapter 1. Scope 129 130 General 131 132 The Linux Standard Base (LSB) defines a system interface for compiled 133 applications and a minimal environment for support of installation scripts. Its 134 purpose is to enable a uniform industry standard environment for high-volume 135 applications conforming to the LSB. 136 137 These specifications are composed of two basic parts: A common specification 138 ("LSB-generic") describing those parts of the interface that remain constant 139 across all implementations of the LSB, and an architecture-specific 140 specification ("LSB-arch") describing the parts of the interface that vary by 141 processor architecture. Together, the LSB-generic and the architecture-specific 142 supplement for a single hardware architecture provide a complete interface 143 specification for compiled application programs on systems that share a common 144 hardware architecture. 145 146 The LSB-generic document shall be used in conjunction with an 147 architecture-specific supplement. Whenever a section of the LSB-generic 148 specification shall be supplemented by architecture-specific information, the 149 LSB-generic document includes a reference to the architecture supplement. 150 Architecture supplements may also contain additional information that is not 151 referenced in the LSB-generic document. 152 153 The LSB contains both a set of Application Program Interfaces (APIs) and 154 Application Binary Interfaces (ABIs). APIs may appear in the source code of 155 portable applications, while the compiled binary of that application may use 156 the larger set of ABIs. A conforming implementation shall provide all of the 157 ABIs listed here. The compilation system may replace (e.g. by macro definition) 158 certain APIs with calls to one or more of the underlying binary interfaces, and 159 may insert calls to binary interfaces as needed. 160 161 The LSB is primarily a binary interface definition. Not all of the source level 162 APIs available to applications may be contained in this specification. 163 164 ------------------------------------------------------------------------------- 165 166 Module Specific Scope 167 168 This is the Core module of the Linux Standards Base (LSB). This module provides 169 the fundemental system interfaces, libraries, and runtime environment upon 170 which all conforming applications and libraries depend. 171 172 Interfaces described in this module are mandatory except where explicitly 173 listed otherwise. Core interfaces may be supplemented by other modules; all 174 modules are built upon the core. 175 176 ------------------------------------------------------------------------------- 177 178 Chapter 2. Normative References 179 180 The specifications listed below are referenced in whole or in part by the Linux 181 Standard Base. In this specification, where only a particular section of one of 182 these references is identified, then the normative reference is to that section 183 alone, and the rest of the referenced document is informative. 184 185 Table 2-1. Normative References 186 187 +-----------------------------------------------------------------------------+ 188 | Name | Title | URL | 189 |-----------------+-------------------------------------+---------------------| 190 |DWARF Debugging |DWARF Debugging Information Format, |http:// | 191 |Information |Revision 2.0.0 (July 27, 1993) |www.eagercon.com/ | 192 |Format | |dwarf/dwarf-2.0.0.pdf| 193 |-----------------+-------------------------------------+---------------------| 194 |Filesystem |Filesystem Hierarchy Standard (FHS) |http:// | 195 |Hierarchy |2.3 |www.pathname.com/fhs/| 196 |Standard | | | 197 |-----------------+-------------------------------------+---------------------| 198 |IEEE Std 754-1985|IEEE Standard 754 for Binary |http://www.ieee.org/ | 199 | |Floating-Point Arithmetic | | 200 |-----------------+-------------------------------------+---------------------| 201 |ISO C (1999) |ISO/IEC 9899: 1999, Programming | | 202 | |Languages --C | | 203 |-----------------+-------------------------------------+---------------------| 204 | |ISO/IEC 9945-1:2003 Information | | 205 | |technology -- Portable Operating | | 206 | |System Interface (POSIX) -- Part 1: | | 207 | |Base Definitions | | 208 | | | | 209 | |ISO/IEC 9945-2:2003 Information | | 210 | |technology -- Portable Operating | | 211 | |System Interface (POSIX) -- Part 2: | | 212 | |System Interfaces |http://www.unix.org/ | 213 |ISO POSIX (2003) | |version3/ | 214 | |ISO/IEC 9945-3:2003 Information | | 215 | |technology -- Portable Operating | | 216 | |System Interface (POSIX) -- Part 3: | | 217 | |Shell and Utilities | | 218 | | | | 219 | |ISO/IEC 9945-4:2003 Information | | 220 | |technology -- Portable Operating | | 221 | |System Interface (POSIX) -- Part 4: | | 222 | |Rationale | | 223 |-----------------+-------------------------------------+---------------------| 224 | | |http:// | 225 |Large File |Large File Support |www.UNIX-systems.org/| 226 |Support | |version2/whatsnew/ | 227 | | |lfs20mar.html | 228 |-----------------+-------------------------------------+---------------------| 229 |Li18nux |LI18NUX 2000 Globalization |http:// | 230 |Globalization |Specification, Version 1.0 with |www.li18nux.org/docs/| 231 |Specification |Amendment 4 |html/ | 232 | | |LI18NUX-2000-amd4.htm| 233 |-----------------+-------------------------------------+---------------------| 234 |Linux Allocated | |http://www.lanana.org| 235 |Device Registry |LINUX ALLOCATED DEVICES |/docs/device-list/ | 236 | | |devices.txt | 237 |-----------------+-------------------------------------+---------------------| 238 | |Open Software Foundation, Request For|http:// | 239 |PAM |Comments: 86.0 , October 1995, V. |www.opengroup.org/ | 240 | |Samar & R.Schemers (SunSoft) |tech/rfc/mirror-rfc/ | 241 | | |rfc86.0.txt | 242 |-----------------+-------------------------------------+---------------------| 243 |RFC 1321: The MD5|IETF RFC 1321: The MD5 Message-Digest|http://www.ietf.org/ | 244 |Message-Digest |Algorithm |rfc/rfc1321.txt | 245 |Algorithm | | | 246 |-----------------+-------------------------------------+---------------------| 247 |RFC 1833: Binding|IETF RFC 1833: Binding Protocols for |http://www.ietf.org/ | 248 |Protocols for ONC|ONC RPC Version 2 |rfc/rfc1833.txt | 249 |RPC Version 2 | | | 250 |-----------------+-------------------------------------+---------------------| 251 |RFC 1951: DEFLATE| | | 252 |Compressed Data |IETF RFC 1951: DEFLATE Compressed |http://www.ietf.org/ | 253 |Format |Data Format Specification version 1.3|rfc/rfc1951.txt | 254 |Specification | | | 255 |-----------------+-------------------------------------+---------------------| 256 |RFC 1952: GZIP |IETF RFC 1952: GZIP file format |http://www.ietf.org/ | 257 |File Format |specification version 4.3 |rfc/rfc1952.txt | 258 |Specification | | | 259 |-----------------+-------------------------------------+---------------------| 260 |RFC 2440: OpenPGP|IETF RFC 2440: OpenPGP Message Format|http://www.ietf.org/ | 261 |Message Format | |rfc/rfc2440.txt | 262 |-----------------+-------------------------------------+---------------------| 263 | |CAE Specification, January 1997, |http:// | 264 |SUSv2 |System Interfaces and Headers |www.opengroup.org/ | 265 | |(XSH),Issue 5 (ISBN: 1-85912-181-0, |publications/catalog/| 266 | |C606) |un.htm | 267 |-----------------+-------------------------------------+---------------------| 268 | |The Single UNIX Specification(SUS) |http:// | 269 |SUSv2 Command and|Version 2, Commands and Utilities |www.opengroup.org/ | 270 |Utilities |(XCU), Issue 5 (ISBN: 1-85912-191-8, |publications/catalog/| 271 | |C604) |un.htm | 272 |-----------------+-------------------------------------+---------------------| 273 | |American Telephone and Telegraph | | 274 |SVID Issue 3 |Company, System V Interface | | 275 | |Definition, Issue 3 ; Morristown, NJ,| | 276 | |UNIX Press, 1989.(ISBN 0201566524) | | 277 |-----------------+-------------------------------------+---------------------| 278 |SVID Issue 4 |System V Interface Definition,Fourth | | 279 | |Edition | | 280 |-----------------+-------------------------------------+---------------------| 281 | | |http:// | 282 |System V ABI |System V Application Binary |www.caldera.com/ | 283 | |Interface, Edition 4.1 |developers/devspecs/ | 284 | | |gabi41.pdf | 285 |-----------------+-------------------------------------+---------------------| 286 | | |http:// | 287 |System V ABI |System V Application Binary Interface|www.caldera.com/ | 288 |Update |- DRAFT - 17 December 2003 |developers/gabi/ | 289 | | |2003-12-17/ | 290 | | |contents.html | 291 |-----------------+-------------------------------------+---------------------| 292 |this | |http:// | 293 |specification |Linux Standard Base |www.linuxbase.org/ | 294 | | |spec/ | 295 |-----------------+-------------------------------------+---------------------| 296 | |CAE Specification, May 1996, X/Open |http:// | 297 |X/Open Curses |Curses, Issue 4, Version 2 (ISBN: |www.opengroup.org/ | 298 | |1-85912-171-3, C610), plus |publications/catalog/| 299 | |Corrigendum U018 |un.htm | 300 |-----------------+-------------------------------------+---------------------| 301 |zlib Manual |zlib 1.2 Manual |http://www.gzip.org/ | 302 | | |zlib/ | 303 +-----------------------------------------------------------------------------+ 304 ------------------------------------------------------------------------------- 305 306 Chapter 3. Requirements 307 308 Relevant Libraries 309 310 The libraries listed in Table 3-1 shall be available on a Linux Standard Base 311 system, with the specified runtime names. The libraries listed in Table 3-2 are 312 architecture specific, but shall be available on all LSB conforming systems. 313 This list may be supplemented or amended by the architecture-specific 314 specification. 315 316 Table 3-1. Standard Library Names 317 318 +---------------------------+ 319 | Library | Runtime Name | 320 |----------+----------------| 321 |libcrypt |libcrypt.so.1 | 322 |----------+----------------| 323 |libdl |libdl.so.2 | 324 |----------+----------------| 325 |libncurses|libncurses.so.5 | 326 |----------+----------------| 327 |libpthread|libpthread.so.0 | 328 |----------+----------------| 329 |libutil |libutil.so.1 | 330 |----------+----------------| 331 |libz |libz.so.1 | 332 |----------+----------------| 333 |libpam |libpam.so.0 | 334 |----------+----------------| 335 |libgcc_s |libgcc_s.so.1 | 336 +---------------------------+ 337 338 Table 3-2. Standard Library Names defined in the Architecture Specific 339 Supplement 340 341 +------------------------+ 342 | Library |Runtime Name | 343 |----------+-------------| 344 |libc |See archLSB | 345 |----------+-------------| 346 |libm |See archLSB | 347 |----------+-------------| 348 |proginterp|See archLSB | 349 +------------------------+ 350 351 These libraries will be in an implementation-defined directory which the 352 dynamic linker shall search by default. 353 354 ------------------------------------------------------------------------------- 355 356 LSB Implementation Conformance 357 358 A conforming implementation shall satisfy the following requirements: 359 360 * The implementation shall implement fully the architecture described in the 361 hardware manual for the target processor architecture. 362 363 * The implementation shall be capable of executing compiled applications 364 having the format and using the system interfaces described in this 365 document. 366 367 * The implementation shall provide libraries containing the interfaces 368 specified by this document, and shall provide a dynamic linking mechanism 369 that allows these interfaces to be attached to applications at runtime. All 370 the interfaces shall behave as specified in this document. 371 372 * The map of virtual memory provided by the implementation shall conform to 373 the requirements of this document. 374 375 * The implementation's low-level behavior with respect to function call 376 linkage, system traps, signals, and other such activities shall conform to 377 the formats described in this document. 378 379 * The implementation shall provide all of the mandatory interfaces in their 380 entirety. 381 382 * The implementation may provide one or more of the optional interfaces. Each 383 optional interface that is provided shall be provided in its entirety. The 384 product documentation shall state which optional interfaces are provided. 385 386 * The implementation shall provide all files and utilities specified as part 387 of this document in the format defined here and in other referenced 388 documents. All commands and utilities shall behave as required by this 389 document. The implementation shall also provide all mandatory components of 390 an application's runtime environment that are included or referenced in 391 this document. 392 393 * The implementation, when provided with standard data formats and values at 394 a named interface, shall provide the behavior defined for those values and 395 data formats at that interface. However, a conforming implementation may 396 consist of components which are separately packaged and/or sold. For 397 example, a vendor of a conforming implementation might sell the hardware, 398 operating system, and windowing system as separately packaged items. 399 400 * The implementation may provide additional interfaces with different names. 401 It may also provide additional behavior corresponding to data values 402 outside the standard ranges, for standard named interfaces. 403 404 405 406 ------------------------------------------------------------------------------- 407 408 LSB Application Conformance 409 410 A conforming application shall satisfy the following requirements: 411 412 413 414 * Its executable files are either shell scripts or object files in the format 415 defined for the Object File Format system interface. 416 417 * Its object files participate in dynamic linking as defined in the Program 418 Loading and Linking System interface. 419 420 * It employs only the instructions, traps, and other low-level facilities 421 defined in the Low-Level System interface as being for use by applications. 422 423 * If it requires any optional interface defined in this document in order to 424 be installed or to execute successfully, the requirement for that optional 425 interface is stated in the application's documentation. 426 427 * It does not use any interface or data format that is not required to be 428 provided by a conforming implementation, unless: 429 430 + If such an interface or data format is supplied by another application 431 through direct invocation of that application during execution, that 432 application is in turn an LSB conforming application. 433 434 + The use of that interface or data format, as well as its source, is 435 identified in the documentation of the application. 436 437 * It shall not use any values for a named interface that are reserved for 438 vendor extensions. 439 440 A strictly conforming application does not require or use any interface, 441 facility, or implementation-defined extension that is not defined in this 442 document in order to be installed or to execute successfully. 443 444 ------------------------------------------------------------------------------- 445 446 Chapter 4. Definitions 447 448 For the purposes of this document, the following definitions, as specified in 449 the ISO/IEC Directives, Part 2, 2001, 4th Edition, apply: 450 451 can 452 453 be able to; there is a possibility of; it is possible to 454 455 cannot 456 457 be unable to; there is no possibilty of; it is not possible to 458 459 may 460 461 is permitted; is allowed; is permissible 462 463 need not 464 465 it is not required that; no...is required 466 467 shall 468 469 is to; is required to; it is required that; has to; only...is permitted; it 470 is necessary 471 472 shall not 473 474 is not allowed [permitted] [acceptable] [permissible]; is required to be 475 not; is required that...be not; is not to be 476 477 should 478 479 it is recommended that; ought to 480 481 should not 482 483 it is not recommended that; ought not to 484 485 ------------------------------------------------------------------------------- 486 487 Chapter 5. Terminology 488 489 For the purposes of this document, the following terms apply: 490 491 archLSB 492 493 The architectural part of the LSB Specification which describes the 494 specific parts of the interface that are platform specific. The archLSB is 495 complementary to the gLSB. 496 497 Binary Standard 498 499 The total set of interfaces that are available to be used in the compiled 500 binary code of a conforming application. 501 502 gLSB 503 504 The common part of the LSB Specification that describes those parts of the 505 interface that remain constant across all hardware implementations of the 506 LSB. 507 508 implementation-defined 509 510 Describes a value or behavior that is not defined by this document but is 511 selected by an implementor. The value or behavior may vary among 512 implementations that conform to this document. An application should not 513 rely on the existence of the value or behavior. An application that relies 514 on such a value or behavior cannot be assured to be portable across 515 conforming implementations. The implementor shall document such a value or 516 behavior so that it can be used correctly by an application. 517 518 Shell Script 519 520 A file that is read by an interpreter (e.g., awk). The first line of the 521 shell script includes a reference to its interpreter binary. 522 523 Source Standard 524 525 The set of interfaces that are available to be used in the source code of a 526 conforming application. 527 528 undefined 529 530 Describes the nature of a value or behavior not defined by this document 531 which results from use of an invalid program construct or invalid data 532 input. The value or behavior may vary among implementations that conform to 533 this document. An application should not rely on the existence or validity 534 of the value or behavior. An application that relies on any particular 535 value or behavior cannot be assured to be portable across conforming 536 implementations. 537 538 unspecified 539 540 Describes the nature of a value or behavior not specified by this document 541 which results from use of a valid program construct or valid data input. 542 The value or behavior may vary among implementations that conform to this 543 document. An application should not rely on the existence or validity of 544 the value or behavior. An application that relies on any particular value 545 or behavior cannot be assured to be portable across conforming 546 implementations. 547 548 Other terms and definitions used in this document shall have the same meaning 549 as defined in Chapter 3 of the Base Definitions volume of ISO POSIX (2003). 550 551 ------------------------------------------------------------------------------- 552 553 Chapter 6. Documentation Conventions 554 555 Throughout this document, the following typographic conventions are used: 556 557 function() 558 559 the name of a function 560 561 command 562 563 the name of a command or utility 564 565 CONSTANT 566 567 a constant value 568 569 parameter 570 571 a parameter 572 573 variable 574 575 a variable 576 577 Throughout this specification, several tables of interfaces are presented. Each 578 entry in these tables has the following format: 579 580 name 581 582 the name of the interface 583 584 (symver) 585 586 An optional symbol version identifier, if required. 587 588 [refno] 589 590 A reference number indexing the table of referenced specifications that 591 follows this table. 592 593 For example, 594 595 +----------------------+ 596 |forkpty(GLIBC_2.0) [1]| 597 +----------------------+ 598 599 refers to the interface named forkpty with symbol version GLIBC_2.0 that is 600 defined in the first of the listed references below the table. 601 602 ELF Specification 603 604 ------------------------------------------------------------------------------- 605 606 Table of Contents 607 I. Low Level System Information 608 609 1. Operating System Interface 610 611 II. Object Format 612 613 2. Object Files 614 3. Sections 615 616 Sections Types 617 618 4. Special Sections 619 620 Special Sections 621 622 5. Symbol Mapping 623 624 Symbol Mapping 625 626 6. DWARF Extensions 627 7. EH Frame Header 628 629 DWARF Exception Header Encoding 630 631 8. Symbol Versioning 632 633 Symbol Version Table 634 Version Definitions 635 Version Requirements 636 Startup Sequence 637 Symbol Resolution 638 639 9. ABI note tag 640 641 III. Dynamic Linking 642 643 10. Program Loading and Dynamic Linking 644 11. Program Header 645 12. Dynamic Entries 646 647 Dynamic Entries 648 649 List of Tables 650 3-1. ELF Section Types 651 3-2. Additional Section Types 652 4-1. ELF Special Sections 653 4-2. Additional Special Sections 654 6-1. Additional DWARF Call Frame Instructions 655 7-1. .eh_frame_hdr Section Format 656 7-2. DWARF Exception Header value format 657 7-3. DWARF Exception Header application 658 11-1. Linux Segment Types 659 660 List of Figures 661 8-1. Version Definition Entries 662 8-2. Version Definition Auxiliary Entries 663 8-3. Version Needed Entries 664 8-4. Version Needed Auxiliary Entries 665 666 I. Low Level System Information 667 668 Table of Contents 669 1. Operating System Interface 670 671 ------------------------------------------------------------------------------- 672 673 Chapter 1. Operating System Interface 674 675 LSB-conforming applications shall assume that stack, heap and other allocated 676 memory regions will be non-executable. The application must take steps to make 677 them executable if needed. 678 679 II. Object Format 680 681 Table of Contents 682 2. Object Files 683 3. Sections 684 4. Special Sections 685 5. Symbol Mapping 686 6. DWARF Extensions 687 7. EH Frame Header 688 8. Symbol Versioning 689 9. ABI note tag 690 691 ------------------------------------------------------------------------------- 692 693 Chapter 2. Object Files 694 695 LSB-conforming implementations shall support the object file Executable and 696 Linking Format (ELF), which is defined by the following documents: 697 698 * System V ABI 699 700 * System V ABI Update 701 702 * this document 703 704 * an architecture-specific LSB specification 705 706 Conforming implementations may also support other unspecified object file 707 formats. 708 709 ------------------------------------------------------------------------------- 710 711 Chapter 3. Sections 712 713 As described in System V ABI, an ELF object file contains a number of sections. 714 715 ------------------------------------------------------------------------------- 716 717 Sections Types 718 719 The section header table is an array of Elf32_Shdr or Elf64_Shdr structures as 720 described in System V ABI. The sh_type member shall be either a value from 721 Table 3-1, drawn from the System V ABI, or one of the additional values 722 specified in Table 3-2. 723 724 A section header's sh_type member specifies the sections's semantics. 725 726 ------------------------------------------------------------------------------- 727 728 ELF Section Types 729 730 The following section types are defined in the System V ABI and the System V 731 ABI Update. 732 733 Table 3-1. ELF Section Types 734 735 +-----------------------------------------------------------------------------+ 736 | Name | Value | Description | 737 |-----------------+----------+------------------------------------------------| 738 | | |The section holds information for dynamic | 739 | | |linking. Currently, an object file shall have | 740 |SHT_DYNAMIC |0x6 |only one dynamic section, but this restriction | 741 | | |may be relaxed in the future. See `Dynamic | 742 | | |Section' in Chapter 5 for details. | 743 |-----------------+----------+------------------------------------------------| 744 | | |This section holds a minimal set of symbols | 745 | | |adequate for dynamic linking. See also | 746 |SHT_DYNSYM |0xb |SHT_SYMTAB. Currently, an object file may have | 747 | | |either a section of SHT_SYMTAB type or a section| 748 | | |of SHT_DYNSYM type, but not both. This | 749 | | |restriction may be relaxed in the future. | 750 |-----------------+----------+------------------------------------------------| 751 | | |This section contains an array of pointers to | 752 | | |termination functions, as described in | 753 |SHT_FINI_ARRAY |0xf |`Initialization and Termination Functions' in | 754 | | |Chapter 5. Each pointer in the array is taken as| 755 | | |a parameterless procedure with a void return. | 756 |-----------------+----------+------------------------------------------------| 757 | | |The section holds a symbol hash table. | 758 | | |Currently, an object file shall have only one | 759 |SHT_HASH |0x5 |hash table, but this restriction may be relaxed | 760 | | |in the future. See `Hash Table' in the Chapter 5| 761 | | |for details. | 762 |-----------------+----------+------------------------------------------------| 763 |SHT_HIPROC |0x7fffffff|Values in this inclusive range are reserved for | 764 | | |processor-specific semantics. | 765 |-----------------+----------+------------------------------------------------| 766 | | |This value specifies the upper bound of the | 767 | | |range of indexes reserved for application | 768 |SHT_HIUSER |0xffffffff|programs. Section types between SHT_LOUSER and | 769 | | |SHT_HIUSER can be used by the application, | 770 | | |without conflicting with current or future | 771 | | |system-defined section types. | 772 |-----------------+----------+------------------------------------------------| 773 | | |This section contains an array of pointers to | 774 | | |initialization functions, as described in | 775 |SHT_INIT_ARRAY |0xe |`Initialization and Termination Functions' in | 776 | | |Chapter 5. Each pointer in the array is taken as| 777 | | |a parameterless procedure with a void return. | 778 |-----------------+----------+------------------------------------------------| 779 |SHT_LOPROC |0x70000000|Values in this inclusive range are reserved for | 780 | | |processor-specific semantics. | 781 |-----------------+----------+------------------------------------------------| 782 | | |This value specifies the lower bound of the | 783 |SHT_LOUSER |0x80000000|range of indexes reserved for application | 784 | | |programs. | 785 |-----------------+----------+------------------------------------------------| 786 | | |A section of this type occupies no space in the | 787 | | |file but otherwise resembles SHT_PROGBITS. | 788 |SHT_NOBITS |0x8 |Although this section contains no bytes, the | 789 | | |sh_offset member contains the conceptual file | 790 | | |offset. | 791 |-----------------+----------+------------------------------------------------| 792 | | |The section holds information that marks the | 793 |SHT_NOTE |0x7 |file in some way. See `Note Section' in Chapter | 794 | | |5 for details. | 795 |-----------------+----------+------------------------------------------------| 796 | | |This value marks the section header as inactive;| 797 |SHT_NULL |0x0 |it does not have an associated section. Other | 798 | | |members of the section header have undefined | 799 | | |values. | 800 |-----------------+----------+------------------------------------------------| 801 | | |This section contains an array of pointers to | 802 | | |functions that are invoked before all other | 803 |SHT_PREINIT_ARRAY|0x10 |initialization functions, as described in | 804 | | |`Initialization and Termination Functions' in | 805 | | |Chapter 5. Each pointer in the array is taken as| 806 | | |a parameterless proceure with a void return. | 807 |-----------------+----------+------------------------------------------------| 808 | | |The section holds information defined by the | 809 |SHT_PROGBITS |0x1 |program, whose format and meaning are determined| 810 | | |solely by the program. | 811 |-----------------+----------+------------------------------------------------| 812 | | |The section holds relocation entries without | 813 | | |explicit addends, such as type Elf32_Rel for the| 814 |SHT_REL |0x9 |32-bit class of object files or type Elf64_Rel | 815 | | |for the 64-bit class of object files. An object | 816 | | |file may have multiple relocation sections. See | 817 | | |"Relocation" | 818 |-----------------+----------+------------------------------------------------| 819 | | |The section holds relocation entries with | 820 | | |explicit addends, such as type Elf32_Rela for | 821 |SHT_RELA |0x4 |the 32-bit class of object files or type | 822 | | |Elf64_Rela for the 64-bit class of object files.| 823 | | |An object file may have multiple relocation | 824 | | |sections. `Relocation' b | 825 |-----------------+----------+------------------------------------------------| 826 |SHT_SHLIB |0xa |This section type is reserved but has | 827 | | |unspecified semantics. | 828 |-----------------+----------+------------------------------------------------| 829 | | |The section holds a string table. An object file| 830 |SHT_STRTAB |0x3 |may have multiple string table sections. See | 831 | | |`String Table' below for details. | 832 |-----------------+----------+------------------------------------------------| 833 | | |This section holds a symbol table. Currently, an| 834 | | |object file may have either a section of | 835 | | |SHT_SYMTAB type or a section of SHT_DYNSYM type,| 836 | | |but not both. This restriction may be relaxed in| 837 |SHT_SYMTAB |0x2 |the future. Typically, SHT_SYMTAB provides | 838 | | |symbols for link editing, though it may also be | 839 | | |used for dynamic linking. As a complete symbol | 840 | | |table, it may contain many symbols unnecessary | 841 | | |for dynamic linking. | 842 +-----------------------------------------------------------------------------+ 843 844 845 ------------------------------------------------------------------------------- 846 847 Additional Section Types 848 849 The following additional section types are defined here. 850 851 Table 3-2. Additional Section Types 852 853 +-----------------------------------------------------------------------------+ 854 | Name | Value | Description | 855 |---------------+----------+--------------------------------------------------| 856 |SHT_GNU_verdef |0x6ffffffd|This section contains the symbol versions that are| 857 | | |provided. | 858 |---------------+----------+--------------------------------------------------| 859 |SHT_GNU_verneed|0x6ffffffe|This section contains the symbol versions that are| 860 | | |required. | 861 |---------------+----------+--------------------------------------------------| 862 |SHT_GNU_versym |0x6fffffff|This section contains the Symbol Version Table. | 863 +-----------------------------------------------------------------------------+ 864 865 866 ------------------------------------------------------------------------------- 867 868 Chapter 4. Special Sections 869 870 Special Sections 871 872 Various sections hold program and control information. Sections in the lists 873 below are used by the system and have the indicated types and attributes. 874 875 ------------------------------------------------------------------------------- 876 877 ELF Special Sections 878 879 The following sections are defined in the System V ABI and the System V ABI 880 Update. 881 882 Table 4-1. ELF Special Sections 883 884 +--------------------------------------------------------+ 885 | Name | Type | Attributes | 886 |--------------+-----------------+-----------------------| 887 |.bss |SHT_NOBITS |SHF_ALLOC+SHF_WRITE | 888 |--------------+-----------------+-----------------------| 889 |.comment |SHT_PROGBITS |0 | 890 |--------------+-----------------+-----------------------| 891 |.data |SHT_PROGBITS |SHF_ALLOC+SHF_WRITE | 892 |--------------+-----------------+-----------------------| 893 |.data1 |SHT_PROGBITS |SHF_ALLOC+SHF_WRITE | 894 |--------------+-----------------+-----------------------| 895 |.debug |SHT_PROGBITS |0 | 896 |--------------+-----------------+-----------------------| 897 |.dynamic |SHT_DYNAMIC |SHF_ALLOC+SHF_WRITE | 898 |--------------+-----------------+-----------------------| 899 |.dynstr |SHT_STRTAB |SHF_ALLOC | 900 |--------------+-----------------+-----------------------| 901 |.dynsym |SHT_DYNSYM |SHF_ALLOC | 902 |--------------+-----------------+-----------------------| 903 |.fini |SHT_PROGBITS |SHF_ALLOC+SHF_EXECINSTR| 904 |--------------+-----------------+-----------------------| 905 |.fini_array |SHT_FINI_ARRAY |SHF_ALLOC+SHF_WRITE | 906 |--------------+-----------------+-----------------------| 907 |.hash |SHT_HASH |SHF_ALLOC | 908 |--------------+-----------------+-----------------------| 909 |.init |SHT_PROGBITS |SHF_ALLOC+SHF_EXECINSTR| 910 |--------------+-----------------+-----------------------| 911 |.init_array |SHT_INIT_ARRAY |SHF_ALLOC+SHF_WRITE | 912 |--------------+-----------------+-----------------------| 913 |.interp |SHT_PROGBITS |SHF_ALLOC | 914 |--------------+-----------------+-----------------------| 915 |.line |SHT_PROGBITS |0 | 916 |--------------+-----------------+-----------------------| 917 |.note |SHT_NOTE |0 | 918 |--------------+-----------------+-----------------------| 919 |.preinit_array|SHT_PREINIT_ARRAY|SHF_ALLOC+SHF_WRITE | 920 |--------------+-----------------+-----------------------| 921 |.rodata |SHT_PROGBITS |SHF_ALLOC | 922 |--------------+-----------------+-----------------------| 923 |.rodata1 |SHT_PROGBITS |SHF_ALLOC | 924 |--------------+-----------------+-----------------------| 925 |.shstrtab |SHT_STRTAB |0 | 926 |--------------+-----------------+-----------------------| 927 |.strtab |SHT_STRTAB |SHF_ALLOC | 928 |--------------+-----------------+-----------------------| 929 |.symtab |SHT_SYMTAB |SHF_ALLOC | 930 |--------------+-----------------+-----------------------| 931 |.text |SHT_PROGBITS |SHF_ALLOC+SHF_EXECINSTR| 932 +--------------------------------------------------------+ 933 934 .bss 935 936 This section holds data that contributes to the program's memory image. The 937 program may treat this data as uninitialized. However, the system shall 938 initialize this data with zeroes when the program begins to run. The 939 section occupies no file space, as indicated by the section type, 940 SHT_NOBITS 941 942 .comment 943 944 This section holds version control information. 945 946 .data 947 948 This section holds initialized data that contribute to the program's memory 949 image. 950 951 .data1 952 953 This section holds initialized data that contribute to the program's memory 954 image. 955 956 .debug 957 958 This section holds information for symbolic debugging. The contents are 959 unspecified. All section names with the prefix .debug hold information for 960 symbolic debugging. The contents of these sections are unspecified. 961 962 .dynamic 963 964 This section holds dynamic linking information. The section's attributes 965 will include the SHF_ALLOC bit. Whether the SHF_WRITE bit is set is 966 processor specific. See Chapter 5 for more information. 967 968 .dynstr 969 970 This section holds strings needed for dynamic linking, most commonly the 971 strings that represent the names associated with symbol table entries. See 972 Chapter 5 for more information. 973 974 .dynsym 975 976 This section holds the dynamic linking symbol table, as described in 977 `Symbol Table'. See Chapter 5 for more information. 978 979 .fini 980 981 This section holds executable instructions that contribute to the process 982 termination code. That is, when a program exits normally, the system 983 arranges to execute the code in this section. 984 985 .fini_array 986 987 This section holds an array of function pointers that contributes to a 988 single termination array for the executable or shared object containing the 989 section. 990 991 .hash 992 993 This section holds a symbol hash table. See `Hash Table' in Chapter 5 for 994 more information. 995 996 .init 997 998 This section holds executable instructions that contribute to the process 999 initialization code. When a program starts to run, the system arranges to 1000 execute the code in this section before calling the main program entry 1001 point (called main for C programs) 1002 1003 .init_array 1004 1005 This section holds an array of function pointers that contributes to a 1006 single initialization array for the executable or shared object containing 1007 the section. 1008 1009 .interp 1010 1011 This section holds the path name of a program interpreter. If the file has 1012 a loadable segment that includes relocation, the sections' attributes will 1013 include the SHF_ALLOC bit; otherwise, that bit will be off. See Chapter 5 1014 for more information. 1015 1016 .line 1017 1018 This section holds line number information for symbolic debugging, which 1019 describes the correspondence between the source program and the machine 1020 code. The contents are unspecified. 1021 1022 .note 1023 1024 This section holds information in the format that `Note Section' in Chapter 1025 5 describes of the System V Application Binary Interface, Edition 4.1. 1026 1027 .preinit_array 1028 1029 This section holds an array of function pointers that contributes to a 1030 single pre-initialization array for the executable or shared object 1031 containing the section. 1032 1033 .rodata 1034 1035 This section holds read-only data that typically contribute to a 1036 non-writable segment in the process image. See `Program Header' in Chapter 1037 5 for more information. 1038 1039 .rodata1 1040 1041 This section hold sread-only data that typically contribute to a 1042 non-writable segment in the process image. See `Program Header' in Chapter 1043 5 for more information. 1044 1045 .shstrtab 1046 1047 This section holds section names. 1048 1049 .strtab 1050 1051 This section holds strings, most commonly the strings that represent the 1052 names associated with symbol table entries. If the file has a loadable 1053 segment that includes the symbol string table, the section's attributes 1054 will include the SHF_ALLOC bit; otherwi 1055 1056 .symtab 1057 1058 This section holds a symbol table, as `Symbol Table'. in this chapter 1059 describes. If the file has a loadable segment that includes the symbol 1060 table, the section's attributes will include the SHF_ALLOC bit; otherwise, 1061 that bit will be off. 1062 1063 .text 1064 1065 This section holds the `text,' or executable instructions, of a program. 1066 1067 1068 1069 ------------------------------------------------------------------------------- 1070 1071 Additional Special Sections 1072 1073 Object files in an LSB conforming application may also contain one or more of 1074 the additional special sections described below. 1075 1076 Table 4-2. Additional Special Sections 1077 1078 +--------------------------------------------------+ 1079 | Name | Type | Attributes | 1080 |--------------+---------------+-------------------| 1081 |.ctors |SHT_PROGBITS |SHF_ALLOC+SHF_WRITE| 1082 |--------------+---------------+-------------------| 1083 |.dtors |SHT_PROGBITS |SHF_ALLOC+SHF_WRITE| 1084 |--------------+---------------+-------------------| 1085 |.eh_frame |SHT_PROGBITS |SHF_ALLOC | 1086 |--------------+---------------+-------------------| 1087 |.eh_frame_hdr |SHT_PROGBITS |SHF_ALLOC | 1088 |--------------+---------------+-------------------| 1089 |.gnu.version |SHT_GNU_versym |SHF_ALLOC | 1090 |--------------+---------------+-------------------| 1091 |.gnu.version_d|SHT_GNU_verdef |SHF_ALLOC | 1092 |--------------+---------------+-------------------| 1093 |.gnu.version_r|SHT_GNU_verneed|SHF_ALLOC | 1094 |--------------+---------------+-------------------| 1095 |.jcr |SHT_PROGBITS |SHF_ALLOC+SHF_WRITE| 1096 |--------------+---------------+-------------------| 1097 |.note.ABI-tag |SHT_NOTE |SHF_ALLOC | 1098 |--------------+---------------+-------------------| 1099 |.stab |SHT_PROGBITS |0 | 1100 |--------------+---------------+-------------------| 1101 |.stabstr |SHT_STRTAB |0 | 1102 +--------------------------------------------------+ 1103 1104 .ctors 1105 1106 This section contains a list of global constructor function pointers. 1107 1108 .dtors 1109 1110 This section contains a list of global destructor function pointers. 1111 1112 .eh_frame 1113 1114 This section contains information necessary for frame unwinding during 1115 exception handling. 1116 1117 .eh_frame_hdr 1118 1119 This section contains a pointer to the .eh_frame section which is 1120 accessible to the runtime support code of a C++ application. This section 1121 may also contain a binary search table which may be used by the runtime 1122 support code to more efficiently access records in the .eh_frame section. 1123 1124 .gnu.version 1125 1126 This section contains the Symbol Version Table. 1127 1128 .gnu.version_d 1129 1130 This section contains the Version Definitions. 1131 1132 .gnu.version_r 1133 1134 This section contains the Version Requirments. 1135 1136 .jcr 1137 1138 This section contains information necessary for registering compiled Java 1139 classes. The contents are compiler-specific and used by compiler 1140 initialization functions. 1141 1142 .note.ABI-tag 1143 1144 Specify ABI details. 1145 1146 .stab 1147 1148 This section contains debugging information. The contents are not specified 1149 as part of the LSB. 1150 1151 .stabstr 1152 1153 This section contains strings associated with the debugging infomation 1154 contained in the .stab section. 1155 1156 1157 1158 ------------------------------------------------------------------------------- 1159 1160 Chapter 5. Symbol Mapping 1161 1162 This chapter defines how names are mapped from the source symbol to the object 1163 symbol. 1164 1165 ------------------------------------------------------------------------------- 1166 1167 Symbol Mapping 1168 1169 Symbols in a source program are translated by the compilation system into 1170 symbols that exist in the object file. The rules for this translation are 1171 defined here. 1172 1173 ------------------------------------------------------------------------------- 1174 1175 C Language 1176 1177 External C symbols have the same names in C and object files' symbol tables. 1178 1179 ------------------------------------------------------------------------------- 1180 1181 Chapter 6. DWARF Extensions 1182 1183 In addition to the Call Frame Instructions defined in section 6.4.2 of DWARF 1184 Debugging Information Format, the following Call Frame Instructions may also be 1185 used. 1186 1187 Table 6-1. Additional DWARF Call Frame Instructions 1188 1189 +-----------------------------------------------------------------------------+ 1190 | Name |Value| Meaning | 1191 |-----------------------------------+-----+-----------------------------------| 1192 | | |The DW_CFA_expression instruction | 1193 | | |takes two operands: an unsigned | 1194 | | |LEB128 value representing a | 1195 | | |register number, and a | 1196 | | |DW_FORM_block value representing a | 1197 | | |DWARF expression. The required | 1198 | | |action is to establish the DWARF | 1199 | | |expression as the means by which | 1200 | | |the address in which the given | 1201 |DW_CFA_expression |0x10 |register contents are found may be | 1202 | | |computed. The value of the CFA is | 1203 | | |pushed on the DWARF evaluation | 1204 | | |stack prior to execution of the | 1205 | | |DWARF expression. The DW_OP_call2, | 1206 | | |DW_OP_call4, DW_OP_call_ref and | 1207 | | |DW_OP_push_object_address DWARF | 1208 | | |operators (see Section 2.4.1 of | 1209 | | |DWARF Debugging Information Format)| 1210 | | |cannot be used in such a DWARF | 1211 | | |expression. | 1212 |-----------------------------------+-----+-----------------------------------| 1213 | | |The DW_CFA_offset_extended_sf | 1214 | | |instruction takes two operands: an | 1215 | | |unsigned LEB128 value representing | 1216 |DW_CFA_offset_extended_sf |0x11 |a register number and a signed | 1217 | | |LEB128 factored offset. This | 1218 | | |instruction is identical to | 1219 | | |DW_CFA_offset_extended except that | 1220 | | |the second operand is signed. | 1221 |-----------------------------------+-----+-----------------------------------| 1222 | | |The DW_CFA_def_cfa_sf instruction | 1223 | | |takes two operands: an unsigned | 1224 | | |LEB128 value representing a | 1225 |DW_CFA_def_cfa_sf |0x12 |register number and a signed LEB128| 1226 | | |factored offset. This instruction | 1227 | | |is identical to DW_CFA_def_cfa | 1228 | | |except that the second operand is | 1229 | | |signed and factored. | 1230 |-----------------------------------+-----+-----------------------------------| 1231 | | |The DW_CFA_def_cfa_offset_sf | 1232 | | |instruction takes a signed LEB128 | 1233 | | |operand representing a factored | 1234 |DW_CFA_def_cfa_offset_sf |0x13 |offset. This instruction is | 1235 | | |identical to DW_CFA_def_cfa_offset | 1236 | | |except that the operand is signed | 1237 | | |and factored. | 1238 |-----------------------------------+-----+-----------------------------------| 1239 | | |The DW_CFA_def_cfa_offset_sf | 1240 |DW_CFA_GNU_args_size |0x2e |instruction takes an unsigned | 1241 | | |LEB128 operand representing an | 1242 | | |argument size. | 1243 |-----------------------------------+-----+-----------------------------------| 1244 | | |The DW_CFA_def_cfa_sf instruction | 1245 | | |takes two operands: an unsigned | 1246 | | |LEB128 value representing a | 1247 | | |register number and an unsigned | 1248 | | |LEB128 which represents the | 1249 |DW_CFA_GNU_negative_offset_extended|0x2f |magnitude of the offset. This | 1250 | | |instruction is identical to | 1251 | | |DW_CFA_offset_extended_sf except | 1252 | | |that the operand is subtracted to | 1253 | | |produce the offset. This | 1254 | | |instructions is obsoleted by | 1255 | | |DW_CFA_offset_extended_sf. | 1256 +-----------------------------------------------------------------------------+ 1257 ------------------------------------------------------------------------------- 1258 1259 Chapter 7. EH Frame Header 1260 1261 The .eh_frame_hdr section contains additional information about the .eh_frame 1262 section. A pointer to the start of the .eh_frame data, and optionally, a binary 1263 search table of pointers to the .eh_frame records are found in this section. 1264 1265 Data in this section is encoded according to the DWARF Exception Header 1266 Encoding described below. 1267 1268 Table 7-1. .eh_frame_hdr Section Format 1269 1270 +---------------------------------+ 1271 | Encoding | Field | 1272 |-------------+-------------------| 1273 |unsigned byte|version | 1274 |-------------+-------------------| 1275 |unsigned byte|eh_frame_ptr_enc | 1276 |-------------+-------------------| 1277 |unsigned byte|fde_count_enc | 1278 |-------------+-------------------| 1279 |unsigned byte|table_enc | 1280 |-------------+-------------------| 1281 |encoded |eh_frame_ptr | 1282 |-------------+-------------------| 1283 |encoded |fde_count | 1284 |-------------+-------------------| 1285 | |binary search table| 1286 +---------------------------------+ 1287 1288 version 1289 1290 Version of the .eh_frame_hdr format. This value shall be 1. 1291 1292 eh_frame_ptr_enc 1293 1294 The encoding format of the eh_frame_ptr field. 1295 1296 fde_count_enc 1297 1298 The encoding format of the fde_count field. A value of DW_EH_PE_omit 1299 indicates the binary search table is not present. 1300 1301 table_enc 1302 1303 The encoding format of the entries in the binary search table. A value of 1304 DW_EH_PE_omit indicates the binary search table is not present. 1305 1306 eh_frame_ptr 1307 1308 The encoded value of the pointer to the start of the .eh_frame section. 1309 1310 fde_count 1311 1312 The encoded value of the count of entries in the binary search table. 1313 1314 binary search table 1315 1316 A binary search table containing fde_count entries. Each entry of the table 1317 consist of two encoded values, the initial location, and the address. The 1318 entries are sorted in an increasing order by the initial location value. 1319 1320 ------------------------------------------------------------------------------- 1321 1322 DWARF Exception Header Encoding 1323 1324 The DWARF Exception Header Encoding is used to describe the type of data used 1325 in the .eh_frame_hdr section. The upper 4 bits indicate how the value is to be 1326 applied. The lower 4 bits indicate the format of the data. 1327 1328 Table 7-2. DWARF Exception Header value format 1329 1330 +-----------------------------------------------------------------------------+ 1331 | Name |Value| Meaning | 1332 |----------------+-----+------------------------------------------------------| 1333 |DW_EH_PE_omit |0xff |No value is present. | 1334 |----------------+-----+------------------------------------------------------| 1335 | | |Unsigned value is encoded using the Little Endian Base| 1336 |DW_EH_PE_uleb128|0x01 |128 (LEB128) as defined by DWARF Debugging Information| 1337 | | |Format. | 1338 |----------------+-----+------------------------------------------------------| 1339 |DW_EH_PE_udata2 |0x02 |A 2 bytes unsigned value. | 1340 |----------------+-----+------------------------------------------------------| 1341 |DW_EH_PE_udata4 |0x03 |A 4 bytes unsigned value. | 1342 |----------------+-----+------------------------------------------------------| 1343 |DW_EH_PE_udata8 |0x04 |An 8 bytes unsigned value. | 1344 |----------------+-----+------------------------------------------------------| 1345 | | |Signed value is encoded using the Little Endian Base | 1346 |DW_EH_PE_sleb128|0x09 |128 (LEB128) as defined by DWARF Debugging Information| 1347 | | |Format. | 1348 |----------------+-----+------------------------------------------------------| 1349 |DW_EH_PE_sdata2 |0x0A |A 2 bytes signed value. | 1350 |----------------+-----+------------------------------------------------------| 1351 |DW_EH_PE_sdata4 |0x0B |A 4 bytes signed value. | 1352 |----------------+-----+------------------------------------------------------| 1353 |DW_EH_PE_sdata8 |0x0C |An 8 bytes signed value. | 1354 +-----------------------------------------------------------------------------+ 1355 1356 Table 7-3. DWARF Exception Header application 1357 1358 +-----------------------------------------------------------------------------+ 1359 | Name |Value| Meaning | 1360 |----------------+-----+------------------------------------------------------| 1361 |DW_EH_PE_absptr |0x00 |Value is used with no modification. | 1362 |----------------+-----+------------------------------------------------------| 1363 |DW_EH_PE_pcrel |0x10 |Value is reletive to the current program counter. | 1364 |----------------+-----+------------------------------------------------------| 1365 |DW_EH_PE_datarel|0x30 |Value is reletive to the beginning of the | 1366 | | |.eh_frame_hdr section. | 1367 |----------------+-----+------------------------------------------------------| 1368 |DW_EH_PE_omit |0xff |No value is present. | 1369 +-----------------------------------------------------------------------------+ 1370 ------------------------------------------------------------------------------- 1371 1372 Chapter 8. Symbol Versioning 1373 1374 This chapter describes the Symbol Versioning mechanism. All ELF objects may 1375 provide or depend on versioned symbols. Symbol Versioning is implemented by 3 1376 section types: SHT_GNU_versym, SHT_GNU_verdef, and SHT_GNU_verneed. 1377 1378 The prefix Elfxx in the following descriptions and code fragments stands for 1379 either "Elf32" or "Elf64", depending on the architecture. 1380 1381 Versions are described by strings. The structures that are used for symbol 1382 versions also contain a member that holds the ELF hashing values of the 1383 strings. This allows for more efficient processing. 1384 1385 ------------------------------------------------------------------------------- 1386 1387 Symbol Version Table 1388 1389 The Symbol Version Table is contained in the special section .gnu.version which 1390 has a section type of SHT_GNU_versym. This section has the same number of 1391 entries as the Dynamic Symbol Table. 1392 1393 This section contains an array of elements of type Elfxx_Half. Each entry 1394 specifies the version defined for or required by the corresponding symbol in 1395 the Dynamic Symbol Table. 1396 1397 The values in the Symbol Version Table are unique to the object in which they 1398 are located. These values are identifiers that are provided by the the 1399 vna_other member of the Elfxx_Vernaux structure or the vd_ndx member of the 1400 Elfxx_Verdef structure. 1401 1402 The values 0 and 1 are reserved. 1403 1404 0 1405 1406 The symbol is local, not available outside the object. 1407 1408 1 1409 1410 The symbol is defined in this object and is globally available. 1411 1412 All other values are used to identify version strings located in one of the 1413 other Symbol Version sections. The value itself is not the version associated 1414 with the symbol. The string identified by the value defines the version of the 1415 symbol. 1416 1417 ------------------------------------------------------------------------------- 1418 1419 Version Definitions 1420 1421 Symbol definitions are contained in the special section .gnu.version_d which 1422 has a section type of SHT_GNU_verdef. The number of entries in this section is 1423 contained in the DT_VERDEFNUM entry of the Dynamic Section. The sh_link member 1424 of the section header points to the section that contains the strings 1425 referenced by this section. 1426 1427 Figure 8-1. Version Definition Entries 1428 1429 typedef struct { 1430 Elfxx_Half vd_version; 1431 Elfxx_Half vd_flags; 1432 Elfxx_Half vd_ndx; 1433 Elfxx_Half vd_cnt; 1434 Elfxx_Word vd_hash; 1435 Elfxx_Word vd_aux; 1436 Elfxx_Word vd_next; 1437 } Elfxx_Verdef; 1438 1439 vd_version 1440 1441 Version revision. This value is currently set to 1, and will be reset if 1442 the versioning implementation is incompatibly altered. 1443 1444 vd_flags 1445 1446 Version information flag bitmask. 1447 1448 vd_ndx 1449 1450 Version index numeric value referencing the SHT_GNU_versym section. 1451 1452 vd_cnt 1453 1454 Number of associated verdaux array entries. 1455 1456 vd_hash 1457 1458 Version name hash value (ELF hash function). 1459 1460 vd_aux 1461 1462 Offset to a corresponding entry in the verdaux array, in bytes. 1463 1464 vd_next 1465 1466 Offset to the next verdef entry, in bytes. 1467 1468 Figure 8-2. Version Definition Auxiliary Entries 1469 1470 typedef struct { 1471 Elfxx_Word vda_name; 1472 Elfxx_Word vda_next; 1473 } Elfxx_Verdaux; 1474 1475 vda_name 1476 1477 Offset to the version or dependency name string in the section header, in 1478 bytes. 1479 1480 vda_next 1481 1482 Offset to the next verdaux entry, in bytes. 1483 1484 ------------------------------------------------------------------------------- 1485 1486 Version Requirements 1487 1488 Symbol definitions are contained in the special section .gnu.version_r which 1489 has a section type of SHT_GNU_verneed. The number of entries in this section is 1490 contained in the DT_VERNEEDNUM entry of the Dynamic Section. The sh_link member 1491 of the section header points to the section that contains the strings 1492 referenced by this section. 1493 1494 Figure 8-3. Version Needed Entries 1495 1496 typedef struct { 1497 Elfxx_Half vn_version; 1498 Elfxx_Half vn_cnt; 1499 Elfxx_Word vn_file; 1500 Elfxx_Word vn_aux; 1501 Elfxx_Word vn_next; 1502 } Elfxx_Verneed; 1503 1504 vn_version 1505 1506 Version of structure. This value is currently set to 1, and will be reset 1507 if the versioning implementation is incompatibly altered. 1508 1509 vn_cnt 1510 1511 Number of associated verneed array entries. 1512 1513 vn_file 1514 1515 Offset to the file name string in the section header, in bytes. 1516 1517 vn_aux 1518 1519 Offset to a corresponding entry in the vernaux array, in bytes. 1520 1521 vn_next 1522 1523 Offset to the next verneed entry, in bytes. 1524 1525 Figure 8-4. Version Needed Auxiliary Entries 1526 1527 typedef struct { 1528 Elfxx_Word vna_hash; 1529 Elfxx_Half vna_flags; 1530 Elfxx_Half vna_other; 1531 Elfxx_Word vna_name; 1532 Elfxx_Word vna_next; 1533 } Elfxx_Vernaux; 1534 1535 vna_hash 1536 1537 Dependency name hash value (ELF hash function). 1538 1539 vna_flags 1540 1541 Dependency information flag bitmask. 1542 1543 vna_other 1544 1545 Object file version identifier used in the .gnu.version symbol version 1546 array. Bit number 15 controls whether or not the object is hidden; if this 1547 bit is set, the object cannot be used and the static linker will ignore the 1548 symbol's presence in the object. 1549 1550 vna_name 1551 1552 Offset to the dependency name string in the section header, in bytes. 1553 1554 vna_next 1555 1556 Offset to the next vernaux entry, in bytes. 1557 1558 ------------------------------------------------------------------------------- 1559 1560 Startup Sequence 1561 1562 When loading a sharable object, version definition data from the loaded object 1563 is analyzed to assure that it meets the version requirements of the calling 1564 object. The dynamic loader retrieves the entries in the caller's Elfxx_Verneed 1565 array and attempts to find matching definition information in the loaded 1566 Elfxx_Verdef table. 1567 1568 Each object and dependency is tested in turn. If a symbol definition is 1569 missing, the loader returns an error. A warning is issued instead of a hard 1570 error when the vna_flags bit for VER_FLG_WEAK is set in the Elfxx_Vernaux 1571 entry. 1572 1573 When the versions referenced by undefined symbols in the loaded object are 1574 found, version availability is certified. The test completes without error and 1575 the object is made available. 1576 1577 ------------------------------------------------------------------------------- 1578 1579 Symbol Resolution 1580 1581 When symbol versioning is used in an object, relocations extend the performance 1582 of definition testing beyond the simple match of symbol name strings: the 1583 version of the reference shall also equal the name of the definition. The same 1584 index that is used in the symbol table can be referenced in the SHT_GNU_versym 1585 section, and the value of this index is then used to acquire name data. The 1586 corresponding requirement string is retrieved from the Elfxx_Verneed array, and 1587 likewise, the corresponding definition string from the Elfxx_Verdef table. 1588 1589 Bit number 15 of the version symbol controls whether or not the object is 1590 hidden; if this bit is set, the object cannot be used and the static linker 1591 will ignore the symbol's presence in the object. 1592 1593 Results differ in the interaction of objects that variously use symbol 1594 versioning. 1595 1596 * The object with the reference and the object with the definitions may both 1597 use versioning. All described matching is processed in this case. A fatal 1598 error is triggered when no matching definition can be found in the object 1599 whose name is the one referenced by the vn_name element in the 1600 Elfxx_Verneed entry. 1601 1602 * The object with the reference may not use versioning, while the object with 1603 the definitions does. In this instance, only the definition with index 1604 numbers 1 and 2 will be used in the reference match, the same identified by 1605 the static linker as the base definition. In infrequent cases where the 1606 static linker was not used, as in calls to dlopen(), a version that does 1607 not have the base definition index is acceptable as long as it is the only 1608 version for which the symbol is defined. 1609 1610 * The object with the reference may use versioning, but the object with the 1611 definitions specifies none. A matching symbol is accepted in this case. A 1612 fatal error is triggered in the unlikely event that a corruption in the 1613 required symbols list obscured an outdated object file and caused a match 1614 on the object filename in the Elfxx_Verneed entry. 1615 1616 * Finally, both the object with the reference and the object with the 1617 definitions may not use versioning. The behavior in this instance defaults 1618 to pre-existing symbol rules. 1619 1620 ------------------------------------------------------------------------------- 1621 1622 Chapter 9. ABI note tag 1623 1624 Every executable shall contain a section named .note.ABI-tag of type SHT_NOTE. 1625 This section is structured as a note section as documented in the ELF spec. The 1626 section shall contain at least the following entry. The name field (namesz/ 1627 name) contains the string "GNU". The type field shall be 1. The descsz field 1628 shall be at least 16, and the first 16 bytes of the desc field shall be as 1629 follows. 1630 1631 The first 32-bit word of the desc field shall be 0 (this signifies a Linux 1632 executable). The second, third, and fourth 32-bit words of the desc field 1633 contain the earliest compatible kernel version. For example, if the 3 words are 1634 2, 2, and 5, this signifies a 2.2.5 kernel. 1635 1636 III. Dynamic Linking 1637 1638 Table of Contents 1639 10. Program Loading and Dynamic Linking 1640 11. Program Header 1641 12. Dynamic Entries 1642 1643 ------------------------------------------------------------------------------- 1644 1645 Chapter 10. Program Loading and Dynamic Linking 1646 1647 LSB-conforming implementations shall support the object file information and 1648 system actions that create running programs as specified in the System V ABI 1649 and System V ABI Update and as supplemented by this document and an 1650 architecture-specific LSB specification. 1651 1652 Any shared object that is loaded shall contain sufficient DT_NEEDED records to 1653 satisfy the symbols on the shared library. 1654 1655 ------------------------------------------------------------------------------- 1656 1657 Chapter 11. Program Header 1658 1659 In addition to the Segment Types defined in the System V ABI and System V ABI 1660 Update the following Segment Types shall also be supported. 1661 1662 Table 11-1. Linux Segment Types 1663 1664 +---------------------------+ 1665 | Name | Value | 1666 |----------------+----------| 1667 |PT_GNU_EH_FRAME |0x6474e550| 1668 |----------------+----------| 1669 |PT_GNU_STACK |0x6474e551| 1670 +---------------------------+ 1671 1672 PT_GNU_EH_FRAME 1673 1674 The array element specifies the location and size of the exception handling 1675 information as defined by the .eh_frame_hdr section. 1676 1677 PT_GNU_STACK 1678 1679 The p_flags member specifies the permissions on the segment containing the 1680 stack and is used to indicate wether the stack should be executable. The 1681 absense of this header indicates indicates that the stack will be 1682 executable. 1683 1684 ------------------------------------------------------------------------------- 1685 1686 Chapter 12. Dynamic Entries 1687 1688 A dynamic entry's d_tag member controls the interpretation of d_un. 1689 1690 ------------------------------------------------------------------------------- 1691 1692 Dynamic Entries 1693 1694 ------------------------------------------------------------------------------- 1695 1696 ELF Dynamic Entries 1697 1698 The following dynamic entries are defined in the System V ABI and System V ABI 1699 Update. 1700 1701 DT_BIND_NOW 1702 1703 Process relocations of object 1704 1705 DT_DEBUG 1706 1707 For debugging; unspecified 1708 1709 DT_FINI 1710 1711 Address of termination function 1712 1713 DT_HASH 1714 1715 Address of symbol hash table 1716 1717 DT_HIPROC 1718 1719 End of processor-specific 1720 1721 DT_INIT 1722 1723 Address of init function 1724 1725 DT_JMPREL 1726 1727 Address of PLT relocs 1728 1729 DT_LOPROC 1730 1731 Start of processor-specific 1732 1733 DT_NEEDED 1734 1735 Name of needed library 1736 1737 DT_NULL 1738 1739 Marks end of dynamic section 1740 1741 DT_PLTREL 1742 1743 Type of reloc in PLT 1744 1745 DT_PLTRELSZ 1746 1747 Size in bytes of PLT relocs 1748 1749 DT_REL 1750 1751 Address of Rel relocs 1752 1753 DT_RELA 1754 1755 Address of Rela relocs 1756 1757 DT_RELAENT 1758 1759 Size of one Rela reloc 1760 1761 DT_RELASZ 1762 1763 Total size of Rela relocs 1764 1765 DT_RELENT 1766 1767 Size of one Rel reloc 1768 1769 DT_RELSZ 1770 1771 Total size of Rel relocs 1772 1773 DT_RPATH 1774 1775 Library search path 1776 1777 DT_SONAME 1778 1779 Name of shared object 1780 1781 DT_STRSZ 1782 1783 Size of string table 1784 1785 DT_STRTAB 1786 1787 Address of string table 1788 1789 DT_SYMBOLIC 1790 1791 Start symbol search here 1792 1793 DT_SYMENT 1794 1795 Size of one symbol table entry 1796 1797 DT_SYMTAB 1798 1799 Address of symbol table 1800 1801 DT_TEXTREL 1802 1803 Reloc might modify .text 1804 1805 1806 1807 ------------------------------------------------------------------------------- 1808 1809 Additional Dynamic Entries 1810 1811 The following dynamic entries are defined here. 1812 1813 DT_ADDRRNGHI 1814 1815 Values from DT_ADDRRNGLO through DT_ADDRRNGHI are reserved for definition 1816 by an archLSB. 1817 1818 DT_ADDRRNGLO 1819 1820 Values from DT_ADDRRNGLO through DT_ADDRRNGHI are reserved for definition 1821 by an archLSB. 1822 1823 DT_AUXILIARY 1824 1825 Shared object to load before self 1826 1827 DT_FILTER 1828 1829 Shared object to get values from 1830 1831 DT_FINI_ARRAY 1832 1833 The address of an array of pointers to termination functions. 1834 1835 DT_FINI_ARRAYSZ 1836 1837 Size in bytes of DT_FINI_ARRAY 1838 1839 DT_HIOS 1840 1841 Values from DT_LOOS through DT_HIOS are reserved for definition by specific 1842 operating systems. 1843 1844 DT_INIT_ARRAY 1845 1846 The address of an array of pointers to initialization functions. 1847 1848 DT_INIT_ARRAYSZ 1849 1850 Size in bytes of DT_INIT_ARRAY 1851 1852 DT_LOOS 1853 1854 Values from DT_LOOS through DT_HIOS are reserved for definition by specific 1855 operating systems. 1856 1857 DT_NUM 1858 1859 Number of dynamic entry tags defined (excepting reserved ranges). 1860 1861 DT_POSFLAG_1 1862 1863 Flags for DT_* entries, effecting the following DT_* entry 1864 1865 DT_RELCOUNT 1866 1867 All Elf32_Rel R_*_RELATIVE relocations have been placed into a single block 1868 and this entry specifies the number of entries in that block. This permits 1869 ld.so.1 to streamline the processing of RELATIVE relocations. 1870 1871 DT_SYMINENT 1872 1873 Entry size of syminfo 1874 1875 DT_SYMINFO 1876 1877 Address of the Syminfo table. 1878 1879 DT_SYMINSZ 1880 1881 Size of syminfo table (in bytes) 1882 1883 DT_VALRNGHI 1884 1885 Entries which fall between DT_VALRNGHI & DT_VALRNGLO use the Dyn.d_un.d_val 1886 field of the Elf*_Dyn structure. 1887 1888 DT_VALRNGLO 1889 1890 Entries which fall between DT_VALRNGHI & DT_VALRNGLO use the Dyn.d_un.d_val 1891 field of the Elf*_Dyn structure. 1892 1893 DT_VERDEF 1894 1895 Address of version definition table 1896 1897 DT_VERDEFNUM 1898 1899 Number of version definitions 1900 1901 DT_VERNEED 1902 1903 Address of table with needed versions 1904 1905 DT_VERNEEDNUM 1906 1907 Number of needed versions 1908 1909 DT_VERSYM 1910 1911 Address of the table provided by the .gnu.version section. 1912 1913 1914 1915 Linux Standard Base Specification 1916 1917 ------------------------------------------------------------------------------- 1918 1919 Table of Contents 1920 I. Base Libraries 1921 1922 1. Libraries 1923 1924 Program Interpreter 1925 Interfaces for libc 1926 Data Definitions for libc 1927 Interface Definitions for libc 1928 Interfaces for libm 1929 Data Definitions for libm 1930 Interfaces for libpthread 1931 Data Definitions for libpthread 1932 Interface Definitions for libpthread 1933 Interfaces for libgcc_s 1934 Data Definitions for libgcc_s 1935 Interfaces for libdl 1936 Data Definitions for libdl 1937 Interface Definitions for libdl 1938 Interfaces for libcrypt 1939 Interfaces for libpam 1940 Data Definitions for libpam 1941 Interface Definitions for libpam 1942 1943 II. Utility Libraries 1944 1945 2. utility Libraries 1946 1947 Interfaces for libz 1948 Data Definitions for libz 1949 Interfaces for libncurses 1950 Data Definitions for libncurses 1951 Interfaces for libutil 1952 Interface Definitions for libutil 1953 1954 III. Commands and Utilities 1955 1956 3. Commands and Utilities 1957 1958 Commands and Utilities 1959 Command Behavior 1960 1961 IV. Execution Environment 1962 1963 4. File System Hierarchy 1964 1965 /dev 1966 1967 5. Additional Recommendations 1968 1969 Minimal granted Directory and File permissions 1970 Recommendations for applications on ownership and permissions 1971 1972 6. Additional Behaviors 1973 1974 Mandatory Optional Behaviors 1975 1976 7. Localization 1977 1978 Regular Expressions 1979 Pattern Matching Notation 1980 1981 V. System Initialization 1982 1983 8. System Initialization 1984 1985 Cron Jobs 1986 Init Script Actions 1987 Comment Conventions for Init Scripts 1988 Installation and Removal of init.d Files 1989 Run Levels 1990 Facility Names 1991 Script Names 1992 Init Script Functions 1993 1994 VI. Users & Groups 1995 1996 9. Users & Groups 1997 1998 User and Group Database 1999 User & Group Names 2000 UID Ranges 2001 Rationale 2002 2003 A. Alphabetical Listing of Interfaces 2004 2005 libc 2006 libcrypt 2007 libdl 2008 libm 2009 libncurses 2010 libpam 2011 libpthread 2012 libutil 2013 libz 2014 2015 List of Tables 2016 1-1. libc Definition 2017 1-2. libc - RPC Function Interfaces 2018 1-3. libc - System Calls Function Interfaces 2019 1-4. libc - Standard I/O Function Interfaces 2020 1-5. libc - Standard I/O Data Interfaces 2021 1-6. libc - Signal Handling Function Interfaces 2022 1-7. libc - Signal Handling Data Interfaces 2023 1-8. libc - Localization Functions Function Interfaces 2024 1-9. libc - Localization Functions Data Interfaces 2025 1-10. libc - Socket Interface Function Interfaces 2026 1-11. libc - Socket Interface Deprecated Function Interfaces 2027 1-12. libc - Wide Characters Function Interfaces 2028 1-13. libc - String Functions Function Interfaces 2029 1-14. libc - IPC Functions Function Interfaces 2030 1-15. libc - Regular Expressions Function Interfaces 2031 1-16. libc - Regular Expressions Deprecated Function Interfaces 2032 1-17. libc - Regular Expressions Deprecated Data Interfaces 2033 1-18. libc - Character Type Functions Function Interfaces 2034 1-19. libc - Time Manipulation Function Interfaces 2035 1-20. libc - Time Manipulation Deprecated Function Interfaces 2036 1-21. libc - Time Manipulation Data Interfaces 2037 1-22. libc - Terminal Interface Functions Function Interfaces 2038 1-23. libc - System Database Interface Function Interfaces 2039 1-24. libc - Language Support Function Interfaces 2040 1-25. libc - Large File Support Function Interfaces 2041 1-26. libc - Standard Library Function Interfaces 2042 1-27. libc - Standard Library Data Interfaces 2043 1-1. Examples 2044 1-29. libm Definition 2045 1-30. libm - Math Function Interfaces 2046 1-31. libm - Math Data Interfaces 2047 1-32. libpthread Definition 2048 1-33. libpthread - Posix Threads Function Interfaces 2049 1-34. libgcc_s Definition 2050 1-35. libdl Definition 2051 1-36. libdl - Dynamic Loader Function Interfaces 2052 1-37. libcrypt Definition 2053 1-38. libcrypt - Encryption Function Interfaces 2054 1-39. libpam Definition 2055 1-40. libpam - Pluggable Authentication API Function Interfaces 2056 2-1. libz Definition 2057 2-2. libz - Compression Library Function Interfaces 2058 2-3. libncurses Definition 2059 2-4. libncurses - Curses Function Interfaces 2060 2-5. libncurses - Curses Data Interfaces 2061 2-6. libutil Definition 2062 2-7. libutil - Utility Functions Function Interfaces 2063 3-1. Commands and Utilities 2064 3-1. Escape Sequences 2065 9-1. Required User & Group Names 2066 9-2. Optional User & Group Names 2067 A-1. libc Function Interfaces 2068 A-2. libc Data Interfaces 2069 A-3. libcrypt Function Interfaces 2070 A-4. libdl Function Interfaces 2071 A-5. libm Function Interfaces 2072 A-6. libm Data Interfaces 2073 A-7. libncurses Function Interfaces 2074 A-8. libncurses Data Interfaces 2075 A-9. libpam Function Interfaces 2076 A-10. libpthread Function Interfaces 2077 A-11. libutil Function Interfaces 2078 A-12. libz Function Interfaces 2079 2080 I. Base Libraries 2081 2082 Table of Contents 2083 1. Libraries 2084 2085 ------------------------------------------------------------------------------- 2086 2087 Chapter 1. Libraries 2088 2089 An LSB-conforming implementation shall support some base libraries which 2090 provide interfaces for accessing the operating system, processor and other 2091 hardware in the system. 2092 2093 ------------------------------------------------------------------------------- 2094 2095 Program Interpreter 2096 2097 The Program Interpreter is specified in the appropriate architecture-specific 2098 LSB specification. 2099 2100 ------------------------------------------------------------------------------- 2101 2102 Interfaces for libc 2103 2104 Table 1-1 defines the library name and shared object name for the libc library 2105 2106 Table 1-1. libc Definition 2107 2108 +----------------------+ 2109 |Library:|libc | 2110 |--------+-------------| 2111 |SONAME: |See archLSB. | 2112 +----------------------+ 2113 2114 The behavior of the interfaces in this library is specified by the following 2115 specifications: 2116 2117 Large File Support 2118 this specification 2119 SUSv2 2120 ISO POSIX (2003) 2121 SVID Issue 3 2122 SVID Issue 4 2123 2124 ------------------------------------------------------------------------------- 2125 2126 RPC 2127 2128 ------------------------------------------------------------------------------- 2129 2130 Interfaces for RPC 2131 2132 An LSB conforming implementation shall provide the generic functions for RPC 2133 specified in Table 1-2, with the full functionality as described in the 2134 referenced underlying specification. 2135 2136 Table 1-2. libc - RPC Function Interfaces 2137 2138 +----------------------------------------------------------------------------------------+ 2139 |authnone_create |pmap_unset [2] |svcerr_weakauth |xdr_float [3] |xdr_u_char [3]| 2140 |[1] | |[3] | | | 2141 |------------------+----------------+------------------+------------------+--------------| 2142 |clnt_create [1] |setdomainname |svctcp_create [2] |xdr_free [3] |xdr_u_int [2] | 2143 | |[2] | | | | 2144 |------------------+----------------+------------------+------------------+--------------| 2145 |clnt_pcreateerror |svc_getreqset |svcudp_create [2] |xdr_int [3] |xdr_u_long [3]| 2146 |[1] |[3] | | | | 2147 |------------------+----------------+------------------+------------------+--------------| 2148 |clnt_perrno [1] |svc_register [2]|xdr_accepted_reply|xdr_long [3] |xdr_u_short | 2149 | | |[3] | |[3] | 2150 |------------------+----------------+------------------+------------------+--------------| 2151 |clnt_perror [1] |svc_run [2] |xdr_array [3] |xdr_opaque [3] |xdr_union [3] | 2152 |------------------+----------------+------------------+------------------+--------------| 2153 |clnt_spcreateerror|svc_sendreply |xdr_bool [3] |xdr_opaque_auth |xdr_vector [3]| 2154 |[1] |[2] | |[3] | | 2155 |------------------+----------------+------------------+------------------+--------------| 2156 |clnt_sperrno [1] |svcerr_auth [3] |xdr_bytes [3] |xdr_pointer [3] |xdr_void [3] | 2157 |------------------+----------------+------------------+------------------+--------------| 2158 |clnt_sperror [1] |svcerr_decode |xdr_callhdr [3] |xdr_reference [3] |xdr_wrapstring| 2159 | |[3] | | |[3] | 2160 |------------------+----------------+------------------+------------------+--------------| 2161 |getdomainname [2] |svcerr_noproc |xdr_callmsg [3] |xdr_rejected_reply|xdrmem_create | 2162 | |[3] | |[3] |[3] | 2163 |------------------+----------------+------------------+------------------+--------------| 2164 |key_decryptsession|svcerr_noprog |xdr_char [3] |xdr_replymsg [3] |xdrrec_create | 2165 |[3] |[3] | | |[3] | 2166 |------------------+----------------+------------------+------------------+--------------| 2167 |pmap_getport [2] |svcerr_progvers |xdr_double [3] |xdr_short [3] |xdrrec_eof [3]| 2168 | |[3] | | | | 2169 |------------------+----------------+------------------+------------------+--------------| 2170 |pmap_set [2] |svcerr_systemerr|xdr_enum [3] |xdr_string [3] | | 2171 | |[3] | | | | 2172 +----------------------------------------------------------------------------------------+ 2173 2174 Referenced Specification(s) 2175 2176 [1]. SVID Issue 4 2177 2178 [2]. this specification 2179 2180 [3]. SVID Issue 3 2181 2182 ------------------------------------------------------------------------------- 2183 2184 System Calls 2185 2186 ------------------------------------------------------------------------------- 2187 2188 Interfaces for System Calls 2189 2190 An LSB conforming implementation shall provide the generic functions for System 2191 Calls specified in Table 1-3, with the full functionality as described in the 2192 referenced underlying specification. 2193 2194 Table 1-3. libc - System Calls Function Interfaces 2195 2196 +-----------------------------------------------------------------------------+ 2197 |__fxstat [1]|fchmod [2] |getwd [2] |read [2] |setrlimit [2]| 2198 |------------+-------------+------------+-----------------------+-------------| 2199 |__getpgid |fchown [2] |initgroups |readdir [2] |setrlimit64 | 2200 |[1] | |[1] | |[3] | 2201 |------------+-------------+------------+-----------------------+-------------| 2202 |__lxstat [1]|fcntl [1] |ioctl [1] |readdir_r [2] |setsid [2] | 2203 |------------+-------------+------------+-----------------------+-------------| 2204 |__xmknod [1]|fdatasync [2]|kill [1] |readlink [2] |setuid [2] | 2205 |------------+-------------+------------+-----------------------+-------------| 2206 |__xstat [1] |flock [1] |killpg [2] |readv [2] |sleep [2] | 2207 |------------+-------------+------------+-----------------------+-------------| 2208 |access [2] |fork [2] |lchown [2] |rename [2] |statvfs [2] | 2209 |------------+-------------+------------+-----------------------+-------------| 2210 |acct [1] |fstatvfs [2] |link [2] |rmdir [2] |stime [1] | 2211 |------------+-------------+------------+-----------------------+-------------| 2212 |alarm [2] |fsync [2] |lockf [2] |sbrk [4] |symlink [2] | 2213 |------------+-------------+------------+-----------------------+-------------| 2214 |brk [4] |ftime [2] |lseek [2] |sched_get_priority_max |sync [2] | 2215 | | | |[2] | | 2216 |------------+-------------+------------+-----------------------+-------------| 2217 |chdir [2] |ftruncate [2]|mkdir [2] |sched_get_priority_min |sysconf [2] | 2218 | | | |[2] | | 2219 |------------+-------------+------------+-----------------------+-------------| 2220 |chmod [2] |getcontext |mkfifo [2] |sched_getparam [2] |time [2] | 2221 | |[2] | | | | 2222 |------------+-------------+------------+-----------------------+-------------| 2223 |chown [2] |getegid [2] |mlock [2] |sched_getscheduler [2] |times [2] | 2224 |------------+-------------+------------+-----------------------+-------------| 2225 |chroot [4] |geteuid [2] |mlockall [2]|sched_rr_get_interval |truncate [2] | 2226 | | | |[2] | | 2227 |------------+-------------+------------+-----------------------+-------------| 2228 |clock [2] |getgid [2] |mmap [2] |sched_setparam [2] |ulimit [2] | 2229 |------------+-------------+------------+-----------------------+-------------| 2230 |close [2] |getgroups [2]|mprotect [2]|sched_setscheduler [2] |umask [2] | 2231 |------------+-------------+------------+-----------------------+-------------| 2232 |closedir [2]|getitimer [2]|msync [2] |sched_yield [2] |uname [2] | 2233 |------------+-------------+------------+-----------------------+-------------| 2234 |creat [1] |getloadavg |munlock [2] |select [2] |unlink [1] | 2235 | |[1] | | | | 2236 |------------+-------------+------------+-----------------------+-------------| 2237 |dup [2] |getpagesize |munlockall |setcontext [2] |utime [2] | 2238 | |[4] |[2] | | | 2239 |------------+-------------+------------+-----------------------+-------------| 2240 |dup2 [2] |getpgid [2] |munmap [2] |setegid [2] |utimes [2] | 2241 |------------+-------------+------------+-----------------------+-------------| 2242 |execl [2] |getpgrp [2] |nanosleep |seteuid [2] |vfork [2] | 2243 | | |[2] | | | 2244 |------------+-------------+------------+-----------------------+-------------| 2245 |execle [2] |getpid [2] |nice [2] |setgid [2] |wait [2] | 2246 |------------+-------------+------------+-----------------------+-------------| 2247 |execlp [2] |getppid [2] |open [1] |setitimer [2] |wait3 [1] | 2248 |------------+-------------+------------+-----------------------+-------------| 2249 |execv [2] |getpriority |opendir [2] |setpgid [2] |wait4 [1] | 2250 | |[2] | | | | 2251 |------------+-------------+------------+-----------------------+-------------| 2252 |execve [2] |getrlimit [2]|pathconf [2]|setpgrp [2] |waitpid [1] | 2253 |------------+-------------+------------+-----------------------+-------------| 2254 |execvp [2] |getrusage [2]|pause [2] |setpriority [2] |write [2] | 2255 |------------+-------------+------------+-----------------------+-------------| 2256 |exit [2] |getsid [2] |pipe [2] |setregid [2] |writev [2] | 2257 |------------+-------------+------------+-----------------------+-------------| 2258 |fchdir [2] |getuid [2] |poll [2] |setreuid [2] | | 2259 +-----------------------------------------------------------------------------+ 2260 2261 Referenced Specification(s) 2262 2263 [1]. this specification 2264 2265 [2]. ISO POSIX (2003) 2266 2267 [3]. Large File Support 2268 2269 [4]. SUSv2 2270 2271 ------------------------------------------------------------------------------- 2272 2273 Standard I/O 2274 2275 ------------------------------------------------------------------------------- 2276 2277 Interfaces for Standard I/O 2278 2279 An LSB conforming implementation shall provide the generic functions for 2280 Standard I/O specified in Table 1-4, with the full functionality as described 2281 in the referenced underlying specification. 2282 2283 Table 1-4. libc - Standard I/O Function Interfaces 2284 2285 +-----------------------------------------------------------------------------+ 2286 |_IO_feof [1] |fgetpos [2] |fsetpos [2] |putchar [2] |sscanf [2] | 2287 |---------------+---------------+----------------+----------------+-----------| 2288 |_IO_getc [1] |fgets [2] |ftell [2] |putchar_unlocked|telldir [2]| 2289 | | | |[2] | | 2290 |---------------+---------------+----------------+----------------+-----------| 2291 |_IO_putc [1] |fgetwc_unlocked|ftello [2] |puts [2] |tempnam [2]| 2292 | |[1] | | | | 2293 |---------------+---------------+----------------+----------------+-----------| 2294 |_IO_puts [1] |fileno [2] |fwrite [2] |putw [3] |ungetc [2] | 2295 |---------------+---------------+----------------+----------------+-----------| 2296 |asprintf [1] |flockfile [2] |getc [2] |remove [2] |vasprintf | 2297 | | | | |[1] | 2298 |---------------+---------------+----------------+----------------+-----------| 2299 |clearerr [2] |fopen [1] |getc_unlocked |rewind [2] |vdprintf | 2300 | | |[2] | |[1] | 2301 |---------------+---------------+----------------+----------------+-----------| 2302 |ctermid [2] |fprintf [2] |getchar [2] |rewinddir [2] |vfprintf | 2303 | | | | |[2] | 2304 |---------------+---------------+----------------+----------------+-----------| 2305 |fclose [2] |fputc [2] |getchar_unlocked|scanf [2] |vprintf [2]| 2306 | | |[2] | | | 2307 |---------------+---------------+----------------+----------------+-----------| 2308 |fdopen [2] |fputs [2] |getw [3] |seekdir [2] |vsnprintf | 2309 | | | | |[2] | 2310 |---------------+---------------+----------------+----------------+-----------| 2311 |feof [2] |fread [2] |pclose [2] |setbuf [2] |vsprintf | 2312 | | | | |[2] | 2313 |---------------+---------------+----------------+----------------+-----------| 2314 |ferror [2] |freopen [1] |popen [2] |setbuffer [1] | | 2315 |---------------+---------------+----------------+----------------+-----------| 2316 |fflush [2] |fscanf [2] |printf [2] |setvbuf [2] | | 2317 |---------------+---------------+----------------+----------------+-----------| 2318 |fflush_unlocked|fseek [2] |putc [2] |snprintf [2] | | 2319 |[1] | | | | | 2320 |---------------+---------------+----------------+----------------+-----------| 2321 |fgetc [2] |fseeko [2] |putc_unlocked |sprintf [2] | | 2322 | | |[2] | | | 2323 +-----------------------------------------------------------------------------+ 2324 2325 Referenced Specification(s) 2326 2327 [1]. this specification 2328 2329 [2]. ISO POSIX (2003) 2330 2331 [3]. SUSv2 2332 2333 An LSB conforming implementation shall provide the generic data interfaces for 2334 Standard I/O specified in Table 1-5, with the full functionality as described 2335 in the referenced underlying specification. 2336 2337 Table 1-5. libc - Standard I/O Data Interfaces 2338 2339 +-----------------------------------+ 2340 |stderr [1]|stdin [1]|stdout [1]| | | 2341 +-----------------------------------+ 2342 2343 Referenced Specification(s) 2344 2345 [1]. ISO POSIX (2003) 2346 2347 ------------------------------------------------------------------------------- 2348 2349 Signal Handling 2350 2351 ------------------------------------------------------------------------------- 2352 2353 Interfaces for Signal Handling 2354 2355 An LSB conforming implementation shall provide the generic functions for Signal 2356 Handling specified in Table 1-6, with the full functionality as described in 2357 the referenced underlying specification. 2358 2359 Table 1-6. libc - Signal Handling Function Interfaces 2360 2361 +-----------------------------------------------------------------------------+ 2362 |__libc_current_sigrtmax|sigaddset |sighold [2] |sigpause [2]|sigsuspend | 2363 |[1] |[2] | | |[2] | 2364 |-----------------------+------------+-------------+------------+-------------| 2365 |__libc_current_sigrtmin|sigaltstack |sigignore [2]|sigpending |sigtimedwait | 2366 |[1] |[2] | |[2] |[2] | 2367 |-----------------------+------------+-------------+------------+-------------| 2368 |__sigsetjmp [1] |sigandset |siginterrupt |sigprocmask |sigwait [2] | 2369 | |[1] |[2] |[2] | | 2370 |-----------------------+------------+-------------+------------+-------------| 2371 |__sysv_signal [1] |sigblock [1]|sigisemptyset|sigqueue [2]|sigwaitinfo | 2372 | | |[1] | |[2] | 2373 |-----------------------+------------+-------------+------------+-------------| 2374 |bsd_signal [2] |sigdelset |sigismember |sigrelse [2]| | 2375 | |[2] |[2] | | | 2376 |-----------------------+------------+-------------+------------+-------------| 2377 |psignal [1] |sigemptyset |siglongjmp |sigreturn | | 2378 | |[2] |[2] |[1] | | 2379 |-----------------------+------------+-------------+------------+-------------| 2380 |raise [2] |sigfillset |signal [2] |sigset [2] | | 2381 | |[2] | | | | 2382 |-----------------------+------------+-------------+------------+-------------| 2383 |sigaction [2] |siggetmask |sigorset [1] |sigstack [3]| | 2384 | |[1] | | | | 2385 +-----------------------------------------------------------------------------+ 2386 2387 Referenced Specification(s) 2388 2389 [1]. this specification 2390 2391 [2]. ISO POSIX (2003) 2392 2393 [3]. SUSv2 2394 2395 An LSB conforming implementation shall provide the generic data interfaces for 2396 Signal Handling specified in Table 1-7, with the full functionality as 2397 described in the referenced underlying specification. 2398 2399 Table 1-7. libc - Signal Handling Data Interfaces 2400 2401 +-------------------------+ 2402 |_sys_siglist [1] | | | | | 2403 +-------------------------+ 2404 2405 Referenced Specification(s) 2406 2407 [1]. this specification 2408 2409 ------------------------------------------------------------------------------- 2410 2411 Localization Functions 2412 2413 ------------------------------------------------------------------------------- 2414 2415 Interfaces for Localization Functions 2416 2417 An LSB conforming implementation shall provide the generic functions for 2418 Localization Functions specified in Table 1-8, with the full functionality as 2419 described in the referenced underlying specification. 2420 2421 Table 1-8. libc - Localization Functions Function Interfaces 2422 2423 +-----------------------------------------------------------------------------+ 2424 |bind_textdomain_codeset|catopen [2] |dngettext [1]|iconv_open |setlocale | 2425 |[1] | | |[2] |[2] | 2426 |-----------------------+------------+-------------+-------------+------------| 2427 |bindtextdomain [1] |dcgettext |gettext [1] |localeconv |textdomain | 2428 | |[1] | |[2] |[1] | 2429 |-----------------------+------------+-------------+-------------+------------| 2430 |catclose [2] |dcngettext |iconv [2] |ngettext [1] | | 2431 | |[1] | | | | 2432 |-----------------------+------------+-------------+-------------+------------| 2433 |catgets [2] |dgettext [1]|iconv_close |nl_langinfo | | 2434 | | |[2] |[2] | | 2435 +-----------------------------------------------------------------------------+ 2436 2437 Referenced Specification(s) 2438 2439 [1]. this specification 2440 2441 [2]. ISO POSIX (2003) 2442 2443 An LSB conforming implementation shall provide the generic data interfaces for 2444 Localization Functions specified in Table 1-9, with the full functionality as 2445 described in the referenced underlying specification. 2446 2447 Table 1-9. libc - Localization Functions Data Interfaces 2448 2449 +-----------------------------+ 2450 |_nl_msg_cat_cntr [1] | | | | | 2451 +-----------------------------+ 2452 2453 Referenced Specification(s) 2454 2455 [1]. this specification 2456 2457 ------------------------------------------------------------------------------- 2458 2459 Socket Interface 2460 2461 ------------------------------------------------------------------------------- 2462 2463 Interfaces for Socket Interface 2464 2465 An LSB conforming implementation shall provide the generic functions for Socket 2466 Interface specified in Table 1-10, with the full functionality as described in 2467 the referenced underlying specification. 2468 2469 Table 1-10. libc - Socket Interface Function Interfaces 2470 2471 +-----------------------------------------------------------------------------+ 2472 |__h_errno_location |gethostid [2] |listen [2] |sendmsg [2] |socketpair | 2473 |[1] | | | |[2] | 2474 |---------------------+--------------+------------+-------------+-------------| 2475 |accept [2] |gethostname |recv [2] |sendto [2] | | 2476 | |[2] | | | | 2477 |---------------------+--------------+------------+-------------+-------------| 2478 |bind [2] |getpeername |recvfrom [2]|setsockopt | | 2479 | |[2] | |[1] | | 2480 |---------------------+--------------+------------+-------------+-------------| 2481 |bindresvport [1] |getsockname |recvmsg [2] |shutdown [2] | | 2482 | |[2] | | | | 2483 |---------------------+--------------+------------+-------------+-------------| 2484 |connect [2] |getsockopt [2]|send [2] |socket [2] | | 2485 +-----------------------------------------------------------------------------+ 2486 2487 Referenced Specification(s) 2488 2489 [1]. this specification 2490 2491 [2]. ISO POSIX (2003) 2492 2493 An LSB conforming implementation shall provide the generic deprecated functions 2494 for Socket Interface specified in Table 1-11, with the full functionality as 2495 described in the referenced underlying specification. 2496 2497 Note: These interfaces are deprecated, and applications should avoid using 2498 them. These interfaces may be withdrawn in future releases of this 2499 specification. 2500 2501 Table 1-11. libc - Socket Interface Deprecated Function Interfaces 2502 2503 +----------------------------+ 2504 |gethostbyname_r [1] | | | | | 2505 +----------------------------+ 2506 2507 Referenced Specification(s) 2508 2509 [1]. this specification 2510 2511 ------------------------------------------------------------------------------- 2512 2513 Wide Characters 2514 2515 ------------------------------------------------------------------------------- 2516 2517 Interfaces for Wide Characters 2518 2519 An LSB conforming implementation shall provide the generic functions for Wide 2520 Characters specified in Table 1-12, with the full functionality as described in 2521 the referenced underlying specification. 2522 2523 Table 1-12. libc - Wide Characters Function Interfaces 2524 2525 +-----------------------------------------------------------------------------+ 2526 |__wcstod_internal [1]|mbsinit [2] |vwscanf [2] |wcsnlen [1] |wcstoumax | 2527 | | | | |[2] | 2528 |---------------------+-------------+--------------+-------------+------------| 2529 |__wcstof_internal [1]|mbsnrtowcs |wcpcpy [1] |wcsnrtombs |wcstouq [1] | 2530 | |[1] | |[1] | | 2531 |---------------------+-------------+--------------+-------------+------------| 2532 |__wcstol_internal [1]|mbsrtowcs [2]|wcpncpy [1] |wcspbrk [2] |wcswcs [2] | 2533 |---------------------+-------------+--------------+-------------+------------| 2534 |__wcstold_internal |mbstowcs [2] |wcrtomb [2] |wcsrchr [2] |wcswidth [2]| 2535 |[1] | | | | | 2536 |---------------------+-------------+--------------+-------------+------------| 2537 |__wcstoul_internal |mbtowc [2] |wcscasecmp [1]|wcsrtombs [2]|wcsxfrm [2] | 2538 |[1] | | | | | 2539 |---------------------+-------------+--------------+-------------+------------| 2540 |btowc [2] |putwc [2] |wcscat [2] |wcsspn [2] |wctob [2] | 2541 |---------------------+-------------+--------------+-------------+------------| 2542 |fgetwc [2] |putwchar [2] |wcschr [2] |wcsstr [2] |wctomb [2] | 2543 |---------------------+-------------+--------------+-------------+------------| 2544 |fgetws [2] |swprintf [2] |wcscmp [2] |wcstod [2] |wctrans [2] | 2545 |---------------------+-------------+--------------+-------------+------------| 2546 |fputwc [2] |swscanf [2] |wcscoll [2] |wcstof [2] |wctype [2] | 2547 |---------------------+-------------+--------------+-------------+------------| 2548 |fputws [2] |towctrans [2]|wcscpy [2] |wcstoimax [2]|wcwidth [2] | 2549 |---------------------+-------------+--------------+-------------+------------| 2550 |fwide [2] |towlower [2] |wcscspn [2] |wcstok [2] |wmemchr [2] | 2551 |---------------------+-------------+--------------+-------------+------------| 2552 |fwprintf [2] |towupper [2] |wcsdup [1] |wcstol [2] |wmemcmp [2] | 2553 |---------------------+-------------+--------------+-------------+------------| 2554 |fwscanf [2] |ungetwc [2] |wcsftime [2] |wcstold [2] |wmemcpy [2] | 2555 |---------------------+-------------+--------------+-------------+------------| 2556 |getwc [2] |vfwprintf [2]|wcslen [2] |wcstoll [2] |wmemmove [2]| 2557 |---------------------+-------------+--------------+-------------+------------| 2558 |getwchar [2] |vfwscanf [2] |wcsncasecmp |wcstombs [2] |wmemset [2] | 2559 | | |[1] | | | 2560 |---------------------+-------------+--------------+-------------+------------| 2561 |mblen [2] |vswprintf [2]|wcsncat [2] |wcstoq [1] |wprintf [2] | 2562 |---------------------+-------------+--------------+-------------+------------| 2563 |mbrlen [2] |vswscanf [2] |wcsncmp [2] |wcstoul [2] |wscanf [2] | 2564 |---------------------+-------------+--------------+-------------+------------| 2565 |mbrtowc [2] |vwprintf [2] |wcsncpy [2] |wcstoull [2] | | 2566 +-----------------------------------------------------------------------------+ 2567 2568 Referenced Specification(s) 2569 2570 [1]. this specification 2571 2572 [2]. ISO POSIX (2003) 2573 2574 ------------------------------------------------------------------------------- 2575 2576 String Functions 2577 2578 ------------------------------------------------------------------------------- 2579 2580 Interfaces for String Functions 2581 2582 An LSB conforming implementation shall provide the generic functions for String 2583 Functions specified in Table 1-13, with the full functionality as described in 2584 the referenced underlying specification. 2585 2586 Table 1-13. libc - String Functions Function Interfaces 2587 2588 +-----------------------------------------------------------------------------+ 2589 |__mempcpy [1] |bzero [2] |strcasestr |strncasecmp |strtoimax [2]| 2590 | | |[1] |[2] | | 2591 |---------------------+-------------+-------------+-------------+-------------| 2592 |__rawmemchr [1] |ffs [2] |strcat [2] |strncat [2] |strtok [2] | 2593 |---------------------+-------------+-------------+-------------+-------------| 2594 |__stpcpy [1] |index [2] |strchr [2] |strncmp [2] |strtok_r [2] | 2595 |---------------------+-------------+-------------+-------------+-------------| 2596 |__strdup [1] |memccpy [2] |strcmp [2] |strncpy [2] |strtold [2] | 2597 |---------------------+-------------+-------------+-------------+-------------| 2598 |__strtod_internal [1]|memchr [2] |strcoll [2] |strndup [1] |strtoll [2] | 2599 |---------------------+-------------+-------------+-------------+-------------| 2600 |__strtof_internal [1]|memcmp [2] |strcpy [2] |strnlen [1] |strtoq [1] | 2601 |---------------------+-------------+-------------+-------------+-------------| 2602 |__strtok_r [1] |memcpy [2] |strcspn [2] |strpbrk [2] |strtoull [2] | 2603 |---------------------+-------------+-------------+-------------+-------------| 2604 |__strtol_internal [1]|memmove [2] |strdup [2] |strptime [1] |strtoumax [2]| 2605 |---------------------+-------------+-------------+-------------+-------------| 2606 |__strtold_internal |memrchr [1] |strerror [2] |strrchr [2] |strtouq [1] | 2607 |[1] | | | | | 2608 |---------------------+-------------+-------------+-------------+-------------| 2609 |__strtoll_internal |memset [2] |strerror_r |strsep [1] |strverscmp | 2610 |[1] | |[1] | |[1] | 2611 |---------------------+-------------+-------------+-------------+-------------| 2612 |__strtoul_internal |rindex [2] |strfmon [2] |strsignal [1]|strxfrm [2] | 2613 |[1] | | | | | 2614 |---------------------+-------------+-------------+-------------+-------------| 2615 |__strtoull_internal |stpcpy [1] |strfry [1] |strspn [2] |swab [2] | 2616 |[1] | | | | | 2617 |---------------------+-------------+-------------+-------------+-------------| 2618 |bcmp [2] |stpncpy [1] |strftime [2] |strstr [2] | | 2619 |---------------------+-------------+-------------+-------------+-------------| 2620 |bcopy [2] |strcasecmp |strlen [2] |strtof [2] | | 2621 | |[2] | | | | 2622 +-----------------------------------------------------------------------------+ 2623 2624 Referenced Specification(s) 2625 2626 [1]. this specification 2627 2628 [2]. ISO POSIX (2003) 2629 2630 ------------------------------------------------------------------------------- 2631 2632 IPC Functions 2633 2634 ------------------------------------------------------------------------------- 2635 2636 Interfaces for IPC Functions 2637 2638 An LSB conforming implementation shall provide the generic functions for IPC 2639 Functions specified in Table 1-14, with the full functionality as described in 2640 the referenced underlying specification. 2641 2642 Table 1-14. libc - IPC Functions Function Interfaces 2643 2644 +---------------------------------------------+ 2645 |ftok [1] |msgrcv [1]|semget [1]|shmctl [1]| | 2646 |----------+----------+----------+----------+-| 2647 |msgctl [1]|msgsnd [1]|semop [1] |shmdt [1] | | 2648 |----------+----------+----------+----------+-| 2649 |msgget [1]|semctl [1]|shmat [1] |shmget [1]| | 2650 +---------------------------------------------+ 2651 2652 Referenced Specification(s) 2653 2654 [1]. ISO POSIX (2003) 2655 2656 ------------------------------------------------------------------------------- 2657 2658 Regular Expressions 2659 2660 ------------------------------------------------------------------------------- 2661 2662 Interfaces for Regular Expressions 2663 2664 An LSB conforming implementation shall provide the generic functions for 2665 Regular Expressions specified in Table 1-15, with the full functionality as 2666 described in the referenced underlying specification. 2667 2668 Table 1-15. libc - Regular Expressions Function Interfaces 2669 2670 +--------------------------------------------------+ 2671 |regcomp [1]|regerror [1]|regexec [1]|regfree [1]| | 2672 +--------------------------------------------------+ 2673 2674 Referenced Specification(s) 2675 2676 [1]. ISO POSIX (2003) 2677 2678 An LSB conforming implementation shall provide the generic deprecated functions 2679 for Regular Expressions specified in Table 1-16, with the full functionality as 2680 described in the referenced underlying specification. 2681 2682 Note: These interfaces are deprecated, and applications should avoid using 2683 them. These interfaces may be withdrawn in future releases of this 2684 specification. 2685 2686 Table 1-16. libc - Regular Expressions Deprecated Function Interfaces 2687 2688 +----------------------------------------------+ 2689 |advance [1]|re_comp [1]|re_exec [1]|step [1]| | 2690 +----------------------------------------------+ 2691 2692 Referenced Specification(s) 2693 2694 [1]. SUSv2 2695 2696 An LSB conforming implementation shall provide the generic deprecated data 2697 interfaces for Regular Expressions specified in Table 1-17, with the full 2698 functionality as described in the referenced underlying specification. 2699 2700 Note: These interfaces are deprecated, and applications should avoid using 2701 them. These interfaces may be withdrawn in future releases of this 2702 specification. 2703 2704 Table 1-17. libc - Regular Expressions Deprecated Data Interfaces 2705 2706 +------------------------------+ 2707 |loc1 [1]|loc2 [1]|locs [1]| | | 2708 +------------------------------+ 2709 2710 Referenced Specification(s) 2711 2712 [1]. SUSv2 2713 2714 ------------------------------------------------------------------------------- 2715 2716 Character Type Functions 2717 2718 ------------------------------------------------------------------------------- 2719 2720 Interfaces for Character Type Functions 2721 2722 An LSB conforming implementation shall provide the generic functions for 2723 Character Type Functions specified in Table 1-18, with the full functionality 2724 as described in the referenced underlying specification. 2725 2726 Table 1-18. libc - Character Type Functions Function Interfaces 2727 2728 +-----------------------------------------------------------------------------+ 2729 |__ctype_b_loc(GLIBC_2.3) [1] |isalpha |ispunct [2]|iswctype |iswupper | 2730 | |[2] | |[2] |[2] | 2731 |------------------------------+----------+-----------+-----------+-----------| 2732 |__ctype_get_mb_cur_max [1] |isascii |isspace [2]|iswdigit |iswxdigit | 2733 | |[2] | |[2] |[2] | 2734 |------------------------------+----------+-----------+-----------+-----------| 2735 |__ctype_tolower_loc(GLIBC_2.3)|iscntrl |isupper [2]|iswgraph |isxdigit | 2736 |[1] |[2] | |[2] |[2] | 2737 |------------------------------+----------+-----------+-----------+-----------| 2738 |__ctype_toupper_loc(GLIBC_2.3)|isdigit |iswalnum |iswlower |toascii [2]| 2739 |[1] |[2] |[2] |[2] | | 2740 |------------------------------+----------+-----------+-----------+-----------| 2741 |_tolower [2] |isgraph |iswalpha |iswprint |tolower [2]| 2742 | |[2] |[2] |[2] | | 2743 |------------------------------+----------+-----------+-----------+-----------| 2744 |_toupper [2] |islower |iswblank |iswpunct |toupper [2]| 2745 | |[2] |[2] |[2] | | 2746 |------------------------------+----------+-----------+-----------+-----------| 2747 |isalnum [2] |isprint |iswcntrl |iswspace | | 2748 | |[2] |[2] |[2] | | 2749 +-----------------------------------------------------------------------------+ 2750 2751 Referenced Specification(s) 2752 2753 [1]. this specification 2754 2755 [2]. ISO POSIX (2003) 2756 2757 ------------------------------------------------------------------------------- 2758 2759 Time Manipulation 2760 2761 ------------------------------------------------------------------------------- 2762 2763 Interfaces for Time Manipulation 2764 2765 An LSB conforming implementation shall provide the generic functions for Time 2766 Manipulation specified in Table 1-19, with the full functionality as described 2767 in the referenced underlying specification. 2768 2769 Table 1-19. libc - Time Manipulation Function Interfaces 2770 2771 +-------------------------------------------------------------------+ 2772 |adjtime [1] |ctime [2] |gmtime [2] |localtime_r [2]|ualarm [2]| 2773 |-------------+------------+-------------+---------------+----------| 2774 |asctime [2] |ctime_r [2] |gmtime_r [2] |mktime [2] | | 2775 |-------------+------------+-------------+---------------+----------| 2776 |asctime_r [2]|difftime [2]|localtime [2]|tzset [2] | | 2777 +-------------------------------------------------------------------+ 2778 2779 Referenced Specification(s) 2780 2781 [1]. this specification 2782 2783 [2]. ISO POSIX (2003) 2784 2785 An LSB conforming implementation shall provide the generic deprecated functions 2786 for Time Manipulation specified in Table 1-20, with the full functionality as 2787 described in the referenced underlying specification. 2788 2789 Note: These interfaces are deprecated, and applications should avoid using 2790 them. These interfaces may be withdrawn in future releases of this 2791 specification. 2792 2793 Table 1-20. libc - Time Manipulation Deprecated Function Interfaces 2794 2795 +---------------------+ 2796 |adjtimex [1] | | | | | 2797 +---------------------+ 2798 2799 Referenced Specification(s) 2800 2801 [1]. this specification 2802 2803 An LSB conforming implementation shall provide the generic data interfaces for 2804 Time Manipulation specified in Table 1-21, with the full functionality as 2805 described in the referenced underlying specification. 2806 2807 Table 1-21. libc - Time Manipulation Data Interfaces 2808 2809 +--------------------------------------------+ 2810 |__daylight [1]|__tzname [1]|timezone [2]| | | 2811 |--------------+------------+------------+-+-| 2812 |__timezone [1]|daylight [2]|tzname [2] | | | 2813 +--------------------------------------------+ 2814 2815 Referenced Specification(s) 2816 2817 [1]. this specification 2818 2819 [2]. ISO POSIX (2003) 2820 2821 ------------------------------------------------------------------------------- 2822 2823 Terminal Interface Functions 2824 2825 ------------------------------------------------------------------------------- 2826 2827 Interfaces for Terminal Interface Functions 2828 2829 An LSB conforming implementation shall provide the generic functions for 2830 Terminal Interface Functions specified in Table 1-22, with the full 2831 functionality as described in the referenced underlying specification. 2832 2833 Table 1-22. libc - Terminal Interface Functions Function Interfaces 2834 2835 +-------------------------------------------------------------------------+ 2836 |cfgetispeed [1]|cfsetispeed [1]|tcdrain [1]|tcgetattr [1]|tcsendbreak [1]| 2837 |---------------+---------------+-----------+-------------+---------------| 2838 |cfgetospeed [1]|cfsetospeed [1]|tcflow [1] |tcgetpgrp [1]|tcsetattr [1] | 2839 |---------------+---------------+-----------+-------------+---------------| 2840 |cfmakeraw [2] |cfsetspeed [2] |tcflush [1]|tcgetsid [1] |tcsetpgrp [1] | 2841 +-------------------------------------------------------------------------+ 2842 2843 Referenced Specification(s) 2844 2845 [1]. ISO POSIX (2003) 2846 2847 [2]. this specification 2848 2849 ------------------------------------------------------------------------------- 2850 2851 System Database Interface 2852 2853 ------------------------------------------------------------------------------- 2854 2855 Interfaces for System Database Interface 2856 2857 An LSB conforming implementation shall provide the generic functions for System 2858 Database Interface specified in Table 1-23, with the full functionality as 2859 described in the referenced underlying specification. 2860 2861 Table 1-23. libc - System Database Interface Function Interfaces 2862 2863 +-----------------------------------------------------------------------------+ 2864 |endgrent [1] |getgrgid [1] |getprotobynumber |getservbyport |setgrent [1] | 2865 | | |[1] |[1] | | 2866 |-------------+---------------+-----------------+---------------+-------------| 2867 |endnetent [1]|getgrgid_r [1] |getprotoent [1] |getservent [1] |setgroups [2]| 2868 |-------------+---------------+-----------------+---------------+-------------| 2869 |endprotoent |getgrnam [1] |getpwent [1] |getutent [2] |setnetent [1]| 2870 |[1] | | | | | 2871 |-------------+---------------+-----------------+---------------+-------------| 2872 |endpwent [1] |getgrnam_r [1] |getpwnam [1] |getutent_r [2] |setprotoent | 2873 | | | | |[1] | 2874 |-------------+---------------+-----------------+---------------+-------------| 2875 |endservent |gethostbyaddr |getpwnam_r [1] |getutxent [1] |setpwent [1] | 2876 |[1] |[1] | | | | 2877 |-------------+---------------+-----------------+---------------+-------------| 2878 |endutent [3] |gethostbyname |getpwuid [1] |getutxid [1] |setservent | 2879 | |[1] | | |[1] | 2880 |-------------+---------------+-----------------+---------------+-------------| 2881 |endutxent [1]|getnetbyaddr |getpwuid_r [1] |getutxline [1] |setutent [2] | 2882 | |[1] | | | | 2883 |-------------+---------------+-----------------+---------------+-------------| 2884 |getgrent [1] |getprotobyname |getservbyname [1]|pututxline [1] |setutxent [1]| 2885 | |[1] | | | | 2886 +-----------------------------------------------------------------------------+ 2887 2888 Referenced Specification(s) 2889 2890 [1]. ISO POSIX (2003) 2891 2892 [2]. this specification 2893 2894 [3]. SUSv2 2895 2896 ------------------------------------------------------------------------------- 2897 2898 Language Support 2899 2900 ------------------------------------------------------------------------------- 2901 2902 Interfaces for Language Support 2903 2904 An LSB conforming implementation shall provide the generic functions for 2905 Language Support specified in Table 1-24, with the full functionality as 2906 described in the referenced underlying specification. 2907 2908 Table 1-24. libc - Language Support Function Interfaces 2909 2910 +---------------------------------------------------------------------------------+ 2911 |__libc_start_main|__register_atfork|_obstack_begin|_obstack_newchunk|obstack_free| 2912 |[1] |(GLIBC_2.3.2) [1]|[1] |[1] |[1] | 2913 +---------------------------------------------------------------------------------+ 2914 2915 Referenced Specification(s) 2916 2917 [1]. this specification 2918 2919 ------------------------------------------------------------------------------- 2920 2921 Large File Support 2922 2923 ------------------------------------------------------------------------------- 2924 2925 Interfaces for Large File Support 2926 2927 An LSB conforming implementation shall provide the generic functions for Large 2928 File Support specified in Table 1-25, with the full functionality as described 2929 in the referenced underlying specification. 2930 2931 Table 1-25. libc - Large File Support Function Interfaces 2932 2933 +--------------------------------------------------------------------------+ 2934 |__fxstat64 [1]|fopen64 [2] |ftello64 [2] |lseek64 [2] |readdir64 [2] | 2935 |--------------+--------------+---------------+-------------+--------------| 2936 |__lxstat64 [1]|freopen64 [2] |ftruncate64 [2]|mkstemp64 [2]|statvfs64 [2] | 2937 |--------------+--------------+---------------+-------------+--------------| 2938 |__xstat64 [1] |fseeko64 [2] |ftw64 [2] |mmap64 [2] |tmpfile64 [2] | 2939 |--------------+--------------+---------------+-------------+--------------| 2940 |creat64 [2] |fsetpos64 [2] |getrlimit64 [2]|nftw64 [2] |truncate64 [2]| 2941 |--------------+--------------+---------------+-------------+--------------| 2942 |fgetpos64 [2] |fstatvfs64 [2]|lockf64 [2] |open64 [2] | | 2943 +--------------------------------------------------------------------------+ 2944 2945 Referenced Specification(s) 2946 2947 [1]. this specification 2948 2949 [2]. Large File Support 2950 2951 ------------------------------------------------------------------------------- 2952 2953 Standard Library 2954 2955 ------------------------------------------------------------------------------- 2956 2957 Interfaces for Standard Library 2958 2959 An LSB conforming implementation shall provide the generic functions for 2960 Standard Library specified in Table 1-26, with the full functionality as 2961 described in the referenced underlying specification. 2962 2963 Table 1-26. libc - Standard Library Function Interfaces 2964 2965 +-----------------------------------------------------------------------------+ 2966 |_Exit [1] |dirname [1] |glob [1] |lsearch [1] |srand [1] | 2967 |-----------------+-----------------+------------+---------------+------------| 2968 |__assert_fail [2]|div [1] |glob64 [2] |makecontext [1]|srand48 [1] | 2969 |-----------------+-----------------+------------+---------------+------------| 2970 |__cxa_atexit [2] |drand48 [1] |globfree [1]|malloc [1] |srandom [1] | 2971 |-----------------+-----------------+------------+---------------+------------| 2972 |__errno_location |ecvt [1] |globfree64 |memmem [2] |strtod [1] | 2973 |[2] | |[2] | | | 2974 |-----------------+-----------------+------------+---------------+------------| 2975 |__fpending [2] |erand48 [1] |grantpt [1] |mkstemp [1] |strtol [1] | 2976 |-----------------+-----------------+------------+---------------+------------| 2977 |__getpagesize [2]|err [2] |hcreate [1] |mktemp [1] |strtoul [1] | 2978 |-----------------+-----------------+------------+---------------+------------| 2979 |__isinf [2] |error [2] |hdestroy [1]|mrand48 [1] |swapcontext | 2980 | | | | |[1] | 2981 |-----------------+-----------------+------------+---------------+------------| 2982 |__isinff [2] |errx [2] |hsearch [1] |nftw [1] |syslog [1] | 2983 |-----------------+-----------------+------------+---------------+------------| 2984 |__isinfl [2] |fcvt [1] |htonl [1] |nrand48 [1] |system [2] | 2985 |-----------------+-----------------+------------+---------------+------------| 2986 |__isnan [2] |fmtmsg [1] |htons [1] |ntohl [1] |tdelete [1] | 2987 |-----------------+-----------------+------------+---------------+------------| 2988 |__isnanf [2] |fnmatch [1] |imaxabs [1] |ntohs [1] |tfind [1] | 2989 |-----------------+-----------------+------------+---------------+------------| 2990 |__isnanl [2] |fpathconf [1] |imaxdiv [1] |openlog [1] |tmpfile [1] | 2991 |-----------------+-----------------+------------+---------------+------------| 2992 |__sysconf [2] |free [1] |inet_addr |perror [1] |tmpnam [1] | 2993 | | |[1] | | | 2994 |-----------------+-----------------+------------+---------------+------------| 2995 |_exit [1] |freeaddrinfo [1] |inet_ntoa |posix_memalign |tsearch [1] | 2996 | | |[1] |[1] | | 2997 |-----------------+-----------------+------------+---------------+------------| 2998 |_longjmp [1] |ftrylockfile [1] |inet_ntop |ptsname [1] |ttyname [1] | 2999 | | |[1] | | | 3000 |-----------------+-----------------+------------+---------------+------------| 3001 |_setjmp [1] |ftw [1] |inet_pton |putenv [1] |ttyname_r | 3002 | | |[1] | |[1] | 3003 |-----------------+-----------------+------------+---------------+------------| 3004 |a64l [1] |funlockfile [1] |initstate |qsort [1] |twalk [1] | 3005 | | |[1] | | | 3006 |-----------------+-----------------+------------+---------------+------------| 3007 |abort [1] |gai_strerror [1] |insque [1] |rand [1] |unlockpt [1]| 3008 |-----------------+-----------------+------------+---------------+------------| 3009 |abs [1] |gcvt [1] |isatty [1] |rand_r [1] |unsetenv [1]| 3010 |-----------------+-----------------+------------+---------------+------------| 3011 |atof [1] |getaddrinfo [1] |isblank [1] |random [1] |usleep [1] | 3012 |-----------------+-----------------+------------+---------------+------------| 3013 |atoi [1] |getcwd [1] |jrand48 [1] |random_r [2] |verrx [2] | 3014 |-----------------+-----------------+------------+---------------+------------| 3015 |atol [1] |getdate [1] |l64a [1] |realloc [1] |vfscanf [1] | 3016 |-----------------+-----------------+------------+---------------+------------| 3017 |atoll [1] |getenv [1] |labs [1] |realpath [1] |vscanf [1] | 3018 |-----------------+-----------------+------------+---------------+------------| 3019 |basename [1] |getlogin [1] |lcong48 [1] |remque [1] |vsscanf [1] | 3020 |-----------------+-----------------+------------+---------------+------------| 3021 |bsearch [1] |getnameinfo [1] |ldiv [1] |seed48 [1] |vsyslog [2] | 3022 |-----------------+-----------------+------------+---------------+------------| 3023 |calloc [1] |getopt [2] |lfind [1] |setenv [1] |warn [2] | 3024 |-----------------+-----------------+------------+---------------+------------| 3025 |closelog [1] |getopt_long [2] |llabs [1] |sethostid [2] |warnx [2] | 3026 |-----------------+-----------------+------------+---------------+------------| 3027 |confstr [1] |getopt_long_only |lldiv [1] |sethostname [2]|wordexp [1] | 3028 | |[2] | | | | 3029 |-----------------+-----------------+------------+---------------+------------| 3030 |cuserid [3] |getsubopt [1] |longjmp [1] |setlogmask [1] |wordfree [1]| 3031 |-----------------+-----------------+------------+---------------+------------| 3032 |daemon [2] |gettimeofday [1] |lrand48 [1] |setstate [1] | | 3033 +-----------------------------------------------------------------------------+ 3034 3035 Referenced Specification(s) 3036 3037 [1]. ISO POSIX (2003) 3038 3039 [2]. this specification 3040 3041 [3]. SUSv2 3042 3043 An LSB conforming implementation shall provide the generic data interfaces for 3044 Standard Library specified in Table 1-27, with the full functionality as 3045 described in the referenced underlying specification. 3046 3047 Table 1-27. libc - Standard Library Data Interfaces 3048 3049 +--------------------------------------------------------------------+ 3050 |__environ [1]|_sys_errlist [1]|getdate_err [2]|opterr [1]|optopt [1]| 3051 |-------------+----------------+---------------+----------+----------| 3052 |_environ [1] |environ [2] |optarg [2] |optind [1]| | 3053 +--------------------------------------------------------------------+ 3054 3055 Referenced Specification(s) 3056 3057 [1]. this specification 3058 3059 [2]. ISO POSIX (2003) 3060 3061 ------------------------------------------------------------------------------- 3062 3063 Data Definitions for libc 3064 3065 This section defines global identifiers and their values that are associated 3066 with interfaces contained in libc. These definitions are organized into groups 3067 that correspond to system headers. This convention is used as a convenience for 3068 the reader, and does not imply the existence of these headers, or their 3069 content. 3070 3071 These definitions are intended to supplement those provided in the referenced 3072 underlying specifications. 3073 3074 This specification uses ISO/IEC 9899 C Language as the reference programming 3075 language, and data definitions are specified in ISO C format. The C language is 3076 used here as a convenient notation. Using a C language description of these 3077 data objects does not preclude their use by other programming languages. 3078 3079 ------------------------------------------------------------------------------- 3080 3081 assert.h 3082 3083 The assert.h header shall define the assert macro. It refers to the macro 3084 NDEBUG, which is not defined in this header. If NDEBUG is defined before the 3085 inclusion of this header, the assert macro shall be defined as described below, 3086 otherwise the macro shall behave as described in assert in ISO/IEC 9945 POSIX. 3087 3088 #define assert(expr) ((void)0) 3089 3090 ------------------------------------------------------------------------------- 3091 3092 ctype.h 3093 3094 enum 3095 { 3096 _ISupper, _ISlower, _ISalpha, _ISdigit, _ISxdigit, _ISspace, _ISprint, 3097 _ISgraph, _ISblank, _IScntrl, _ISpunct, _ISalnum 3098 } 3099 ; 3100 3101 ------------------------------------------------------------------------------- 3102 3103 dirent.h 3104 3105 typedef struct __dirstream DIR; 3106 3107 struct dirent 3108 { 3109 long d_ino; 3110 off_t d_off; 3111 unsigned short d_reclen; 3112 unsigned char d_type; 3113 char d_name[256]; 3114 } 3115 ; 3116 struct dirent64 3117 { 3118 uint64_t d_ino; 3119 int64_t d_off; 3120 unsigned short d_reclen; 3121 unsigned char d_type; 3122 char d_name[256]; 3123 } 3124 ; 3125 3126 ------------------------------------------------------------------------------- 3127 3128 errno.h 3129 3130 #define errno (*__errno_location()) 3131 3132 #define EPERM 1 3133 #define ECHILD 10 3134 #define ENETDOWN 100 3135 #define ENETUNREACH 101 3136 #define ENETRESET 102 3137 #define ECONNABORTED 103 3138 #define ECONNRESET 104 3139 #define ENOBUFS 105 3140 #define EISCONN 106 3141 #define ENOTCONN 107 3142 #define ESHUTDOWN 108 3143 #define ETOOMANYREFS 109 3144 #define EAGAIN 11 3145 #define ETIMEDOUT 110 3146 #define ECONNREFUSED 111 3147 #define EHOSTDOWN 112 3148 #define EHOSTUNREACH 113 3149 #define EALREADY 114 3150 #define EINPROGRESS 115 3151 #define ESTALE 116 3152 #define EUCLEAN 117 3153 #define ENOTNAM 118 3154 #define ENAVAIL 119 3155 #define ENOMEM 12 3156 #define EISNAM 120 3157 #define EREMOTEIO 121 3158 #define EDQUOT 122 3159 #define ENOMEDIUM 123 3160 #define EMEDIUMTYPE 124 3161 #define ECANCELED 125 3162 #define EACCES 13 3163 #define EFAULT 14 3164 #define ENOTBLK 15 3165 #define EBUSY 16 3166 #define EEXIST 17 3167 #define EXDEV 18 3168 #define ENODEV 19 3169 #define ENOENT 2 3170 #define ENOTDIR 20 3171 #define EISDIR 21 3172 #define EINVAL 22 3173 #define ENFILE 23 3174 #define EMFILE 24 3175 #define ENOTTY 25 3176 #define ETXTBSY 26 3177 #define EFBIG 27 3178 #define ENOSPC 28 3179 #define ESPIPE 29 3180 #define ESRCH 3 3181 #define EROFS 30 3182 #define EMLINK 31 3183 #define EPIPE 32 3184 #define EDOM 33 3185 #define ERANGE 34 3186 #define EDEADLK 35 3187 #define ENAMETOOLONG 36 3188 #define ENOLCK 37 3189 #define ENOSYS 38 3190 #define ENOTEMPTY 39 3191 #define EINTR 4 3192 #define ELOOP 40 3193 #define ENOMSG 42 3194 #define EIDRM 43 3195 #define ECHRNG 44 3196 #define EL2NSYNC 45 3197 #define EL3HLT 46 3198 #define EL3RST 47 3199 #define ELNRNG 48 3200 #define EUNATCH 49 3201 #define EIO 5 3202 #define ENOANO 55 3203 #define EBADRQC 56 3204 #define EBADSLT 57 3205 #define EBFONT 59 3206 #define ENXIO 6 3207 #define ENOSTR 60 3208 #define ENODATA 61 3209 #define ETIME 62 3210 #define ENOSR 63 3211 #define ENONET 64 3212 #define ENOPKG 65 3213 #define EREMOTE 66 3214 #define ENOLINK 67 3215 #define EADV 68 3216 #define ESRMNT 69 3217 #define E2BIG 7 3218 #define ECOMM 70 3219 #define EPROTO 71 3220 #define EMULTIHOP 72 3221 #define EDOTDOT 73 3222 #define EBADMSG 74 3223 #define EOVERFLOW 75 3224 #define ENOTUNIQ 76 3225 #define EBADFD 77 3226 #define EREMCHG 78 3227 #define ELIBACC 79 3228 #define ENOEXEC 8 3229 #define ELIBBAD 80 3230 #define ELIBSCN 81 3231 #define ELIBMAX 82 3232 #define ELIBEXEC 83 3233 #define EILSEQ 84 3234 #define ERESTART 85 3235 #define ESTRPIPE 86 3236 #define EUSERS 87 3237 #define ENOTSOCK 88 3238 #define EDESTADDRREQ 89 3239 #define EBADF 9 3240 #define EMSGSIZE 90 3241 #define EPROTOTYPE 91 3242 #define ENOPROTOOPT 92 3243 #define EPROTONOSUPPORT 93 3244 #define ESOCKTNOSUPPORT 94 3245 #define EOPNOTSUPP 95 3246 #define EPFNOSUPPORT 96 3247 #define EAFNOSUPPORT 97 3248 #define EADDRINUSE 98 3249 #define EADDRNOTAVAIL 99 3250 #define EWOULDBLOCK EAGAIN 3251 #define ENOTSUP EOPNOTSUPP 3252 3253 ------------------------------------------------------------------------------- 3254 3255 fcntl.h 3256 3257 #define O_RDONLY 00 3258 #define O_ACCMODE 0003 3259 #define O_WRONLY 01 3260 #define O_CREAT 0100 3261 #define O_TRUNC 01000 3262 #define O_SYNC 010000 3263 #define O_RDWR 02 3264 #define O_EXCL 0200 3265 #define O_APPEND 02000 3266 #define O_ASYNC 020000 3267 #define O_NOCTTY 0400 3268 #define O_NDELAY 04000 3269 #define O_NONBLOCK 04000 3270 #define FD_CLOEXEC 1 3271 3272 struct flock 3273 { 3274 short l_type; 3275 short l_whence; 3276 off_t l_start; 3277 off_t l_len; 3278 pid_t l_pid; 3279 } 3280 ; 3281 struct flock64 3282 { 3283 short l_type; 3284 short l_whence; 3285 loff_t l_start; 3286 loff_t l_len; 3287 pid_t l_pid; 3288 } 3289 ; 3290 3291 #define F_DUPFD 0 3292 #define F_RDLCK 0 3293 #define F_GETFD 1 3294 #define F_WRLCK 1 3295 #define F_SETFD 2 3296 #define F_UNLCK 2 3297 #define F_GETFL 3 3298 #define F_SETFL 4 3299 #define F_GETLK 5 3300 #define F_SETLK 6 3301 #define F_SETLKW 7 3302 #define F_SETOWN 8 3303 #define F_GETOWN 9 3304 3305 ------------------------------------------------------------------------------- 3306 3307 fmtmsg.h 3308 3309 #define MM_HARD 1 3310 #define MM_NRECOV 128 3311 #define MM_UTIL 16 3312 #define MM_SOFT 2 3313 #define MM_OPSYS 32 3314 #define MM_FIRM 4 3315 #define MM_RECOVER 64 3316 #define MM_APPL 8 3317 3318 #define MM_NOSEV 0 3319 #define MM_HALT 1 3320 #define MM_ERROR 2 3321 3322 #define MM_NULLLBL ((char *) 0) 3323 3324 ------------------------------------------------------------------------------- 3325 3326 fnmatch.h 3327 3328 #define FNM_PATHNAME (1<<0) 3329 #define FNM_NOESCAPE (1<<1) 3330 #define FNM_PERIOD (1<<2) 3331 #define FNM_NOMATCH 1 3332 3333 ------------------------------------------------------------------------------- 3334 3335 ftw.h 3336 3337 #define FTW_D FTW_D 3338 #define FTW_DNR FTW_DNR 3339 #define FTW_DP FTW_DP 3340 #define FTW_F FTW_F 3341 #define FTW_NS FTW_NS 3342 #define FTW_SL FTW_SL 3343 #define FTW_SLN FTW_SLN 3344 3345 enum 3346 { 3347 FTW_F, FTW_D, FTW_DNR, FTW_NS, FTW_SL, FTW_DP, FTW_SLN 3348 } 3349 ; 3350 3351 enum 3352 { 3353 FTW_PHYS, FTW_MOUNT, FTW_CHDIR, FTW_DEPTH 3354 } 3355 ; 3356 3357 struct FTW 3358 { 3359 int base; 3360 int level; 3361 } 3362 ; 3363 3364 typedef int (*__ftw_func_t) (char *__filename, struct stat * __status, 3365 int __flag); 3366 typedef int (*__ftw64_func_t) (char *__filename, struct stat64 * __status, 3367 int __flag); 3368 typedef int (*__nftw_func_t) (char *__filename, struct stat * __status, 3369 int __flag, struct FTW * __info); 3370 typedef int (*__nftw64_func_t) (char *__filename, struct stat64 * __status, 3371 int __flag, struct FTW * __info); 3372 3373 ------------------------------------------------------------------------------- 3374 3375 getopt.h 3376 3377 #define no_argument 0 3378 #define required_argument 1 3379 #define optional_argument 2 3380 3381 struct option 3382 { 3383 char *name; 3384 int has_arg; 3385 int *flag; 3386 int val; 3387 } 3388 ; 3389 3390 ------------------------------------------------------------------------------- 3391 3392 glob.h 3393 3394 #define GLOB_ERR (1<<0) 3395 #define GLOB_MARK (1<<1) 3396 #define GLOB_BRACE (1<<10) 3397 #define GLOB_NOMAGIC (1<<11) 3398 #define GLOB_TILDE (1<<12) 3399 #define GLOB_ONLYDIR (1<<13) 3400 #define GLOB_TILDE_CHECK (1<<14) 3401 #define GLOB_NOSORT (1<<2) 3402 #define GLOB_DOOFFS (1<<3) 3403 #define GLOB_NOCHECK (1<<4) 3404 #define GLOB_APPEND (1<<5) 3405 #define GLOB_NOESCAPE (1<<6) 3406 #define GLOB_PERIOD (1<<7) 3407 #define GLOB_MAGCHAR (1<<8) 3408 #define GLOB_ALTDIRFUNC (1<<9) 3409 3410 #define GLOB_NOSPACE 1 3411 #define GLOB_ABORTED 2 3412 #define GLOB_NOMATCH 3 3413 #define GLOB_NOSYS 4 3414 3415 typedef struct 3416 { 3417 size_t gl_pathc; 3418 char **gl_pathv; 3419 size_t gl_offs; 3420 int gl_flags; 3421 void (*gl_closedir) (void *); 3422 struct dirent *(*gl_readdir) (void *); 3423 void *(*gl_opendir) (const char *); 3424 int (*gl_lstat) (const char *, struct stat *); 3425 int (*gl_stat) (const char *, struct stat *); 3426 } 3427 glob_t; 3428 3429 typedef struct 3430 { 3431 size_t gl_pathc; 3432 char **gl_pathv; 3433 size_t gl_offs; 3434 int gl_flags; 3435 void (*gl_closedir) (void *); 3436 struct dirent64 *(*gl_readdir64) (void *); 3437 void *(*gl_opendir) (const char *); 3438 int (*gl_lstat) (const char *, struct stat *); 3439 int (*gl_stat) (const char *, struct stat *); 3440 } 3441 glob64_t; 3442 3443 ------------------------------------------------------------------------------- 3444 3445 grp.h 3446 3447 struct group 3448 { 3449 char *gr_name; 3450 char *gr_passwd; 3451 gid_t gr_gid; 3452 char **gr_mem; 3453 } 3454 ; 3455 3456 ------------------------------------------------------------------------------- 3457 3458 iconv.h 3459 3460 typedef void *iconv_t; 3461 3462 ------------------------------------------------------------------------------- 3463 3464 inttypes.h 3465 3466 typedef lldiv_t imaxdiv_t; 3467 typedef unsigned char uint8_t; 3468 typedef unsigned short uint16_t; 3469 typedef unsigned int uint32_t; 3470 3471 ------------------------------------------------------------------------------- 3472 3473 langinfo.h 3474 3475 #define ABDAY_1 0x20000 3476 #define ABDAY_2 0x20001 3477 #define ABDAY_3 0x20002 3478 #define ABDAY_4 0x20003 3479 #define ABDAY_5 0x20004 3480 #define ABDAY_6 0x20005 3481 #define ABDAY_7 0x20006 3482 3483 #define DAY_1 0x20007 3484 #define DAY_2 0x20008 3485 #define DAY_3 0x20009 3486 #define DAY_4 0x2000A 3487 #define DAY_5 0x2000B 3488 #define DAY_6 0x2000C 3489 #define DAY_7 0x2000D 3490 3491 #define ABMON_1 0x2000E 3492 #define ABMON_2 0x2000F 3493 #define ABMON_3 0x20010 3494 #define ABMON_4 0x20011 3495 #define ABMON_5 0x20012 3496 #define ABMON_6 0x20013 3497 #define ABMON_7 0x20014 3498 #define ABMON_8 0x20015 3499 #define ABMON_9 0x20016 3500 #define ABMON_10 0x20017 3501 #define ABMON_11 0x20018 3502 #define ABMON_12 0x20019 3503 3504 #define MON_1 0x2001A 3505 #define MON_2 0x2001B 3506 #define MON_3 0x2001C 3507 #define MON_4 0x2001D 3508 #define MON_5 0x2001E 3509 #define MON_6 0x2001F 3510 #define MON_7 0x20020 3511 #define MON_8 0x20021 3512 #define MON_9 0x20022 3513 #define MON_10 0x20023 3514 #define MON_11 0x20024 3515 #define MON_12 0x20025 3516 3517 #define AM_STR 0x20026 3518 #define PM_STR 0x20027 3519 3520 #define D_T_FMT 0x20028 3521 #define D_FMT 0x20029 3522 #define T_FMT 0x2002A 3523 #define T_FMT_AMPM 0x2002B 3524 3525 #define ERA 0x2002C 3526 #define ERA_D_FMT 0x2002E 3527 #define ALT_DIGITS 0x2002F 3528 #define ERA_D_T_FMT 0x20030 3529 #define ERA_T_FMT 0x20031 3530 3531 #define CODESET 14 3532 3533 #define CRNCYSTR 0x4000F 3534 3535 #define RADIXCHAR 0x10000 3536 #define THOUSEP 0x10001 3537 #define YESEXPR 0x50000 3538 #define NOEXPR 0x50001 3539 #define YESSTR 0x50002 3540 #define NOSTR 0x50003 3541 3542 ------------------------------------------------------------------------------- 3543 3544 limits.h 3545 3546 #define LLONG_MIN (-LLONG_MAX-1LL) 3547 #define ULLONG_MAX 18446744073709551615ULL 3548 #define OPEN_MAX 256 3549 #define PATH_MAX 4096 3550 #define LLONG_MAX 9223372036854775807LL 3551 #define SSIZE_MAX LONG_MAX 3552 3553 #define MB_LEN_MAX 16 3554 3555 #define SCHAR_MIN (-128) 3556 #define SCHAR_MAX 127 3557 #define UCHAR_MAX 255 3558 #define CHAR_BIT 8 3559 3560 #define SHRT_MIN (-32768) 3561 #define SHRT_MAX 32767 3562 #define USHRT_MAX 65535 3563 3564 #define INT_MIN (-INT_MAX-1) 3565 #define INT_MAX 2147483647 3566 #define __INT_MAX__ 2147483647 3567 #define UINT_MAX 4294967295U 3568 3569 #define LONG_MIN (-LONG_MAX-1L) 3570 3571 ------------------------------------------------------------------------------- 3572 3573 locale.h 3574 3575 #define LC_CTYPE 0 3576 #define LC_NUMERIC 1 3577 #define LC_TELEPHONE 10 3578 #define LC_MEASUREMENT 11 3579 #define LC_IDENTIFICATION 12 3580 #define LC_TIME 2 3581 #define LC_COLLATE 3 3582 #define LC_MONETARY 4 3583 #define LC_MESSAGES 5 3584 #define LC_ALL 6 3585 #define LC_PAPER 7 3586 #define LC_NAME 8 3587 #define LC_ADDRESS 9 3588 3589 struct lconv 3590 { 3591 char *decimal_point; 3592 char *thousands_sep; 3593 char *grouping; 3594 char *int_curr_symbol; 3595 char *currency_symbol; 3596 char *mon_decimal_point; 3597 char *mon_thousands_sep; 3598 char *mon_grouping; 3599 char *positive_sign; 3600 char *negative_sign; 3601 char int_frac_digits; 3602 char frac_digits; 3603 char p_cs_precedes; 3604 char p_sep_by_space; 3605 char n_cs_precedes; 3606 char n_sep_by_space; 3607 char p_sign_posn; 3608 char n_sign_posn; 3609 char int_p_cs_precedes; 3610 char int_p_sep_by_space; 3611 char int_n_cs_precedes; 3612 char int_n_sep_by_space; 3613 char int_p_sign_posn; 3614 char int_n_sign_posn; 3615 } 3616 ; 3617 3618 typedef struct __locale_struct 3619 { 3620 struct locale_data *__locales[13]; 3621 const unsigned short *__ctype_b; 3622 const int *__ctype_tolower; 3623 const int *__ctype_toupper; 3624 const char *__names[13]; 3625 } 3626 *__locale_t; 3627 3628 ------------------------------------------------------------------------------- 3629 3630 net/if.h 3631 3632 #define IF_NAMESIZE 16 3633 3634 #define IFF_UP 0x01 3635 #define IFF_BROADCAST 0x02 3636 #define IFF_DEBUG 0x04 3637 #define IFF_LOOPBACK 0x08 3638 #define IFF_POINTOPOINT 0x10 3639 #define IFF_PROMISC 0x100 3640 #define IFF_MULTICAST 0x1000 3641 #define IFF_NOTRAILERS 0x20 3642 #define IFF_RUNNING 0x40 3643 #define IFF_NOARP 0x80 3644 3645 struct ifaddr 3646 { 3647 struct sockaddr ifa_addr; 3648 union 3649 { 3650 struct sockaddr ifu_broadaddr; 3651 struct sockaddr ifu_dstaddr; 3652 } 3653 ifa_ifu; 3654 void *ifa_ifp; 3655 void *ifa_next; 3656 } 3657 ; 3658 #define IFNAMSIZ IF_NAMESIZE 3659 3660 struct ifreq 3661 { 3662 union 3663 { 3664 char ifrn_name[IFNAMSIZ]; 3665 } 3666 ifr_ifrn; 3667 union 3668 { 3669 struct sockaddr ifru_addr; 3670 struct sockaddr ifru_dstaddr; 3671 struct sockaddr ifru_broadaddr; 3672 struct sockaddr ifru_netmask; 3673 struct sockaddr ifru_hwaddr; 3674 short ifru_flags; 3675 int ifru_ivalue; 3676 int ifru_mtu; 3677 char ifru_slave[IFNAMSIZ]; 3678 char ifru_newname[IFNAMSIZ]; 3679 caddr_t ifru_data; 3680 struct ifmap ifru_map; 3681 } 3682 ifr_ifru; 3683 } 3684 ; 3685 3686 struct ifconf 3687 { 3688 int ifc_len; 3689 union 3690 { 3691 caddr_t ifcu_buf; 3692 struct ifreq *ifcu_req; 3693 } 3694 ifc_ifcu; 3695 } 3696 ; 3697 3698 ------------------------------------------------------------------------------- 3699 3700 netdb.h 3701 3702 #define h_errno (*__h_errno_location ()) 3703 #define NETDB_INTERNAL -1 3704 #define NETDB_SUCCESS 0 3705 #define HOST_NOT_FOUND 1 3706 #define IPPORT_RESERVED 1024 3707 #define NI_MAXHOST 1025 3708 #define TRY_AGAIN 2 3709 #define NO_RECOVERY 3 3710 #define NI_MAXSERV 32 3711 #define NO_DATA 4 3712 #define h_addr h_addr_list[0] 3713 #define NO_ADDRESS NO_DATA 3714 3715 struct servent 3716 { 3717 char *s_name; 3718 char **s_aliases; 3719 int s_port; 3720 char *s_proto; 3721 } 3722 ; 3723 struct hostent 3724 { 3725 char *h_name; 3726 char **h_aliases; 3727 int h_addrtype; 3728 int h_length; 3729 char **h_addr_list; 3730 } 3731 ; 3732 struct protoent 3733 { 3734 char *p_name; 3735 char **p_aliases; 3736 int p_proto; 3737 } 3738 ; 3739 struct netent 3740 { 3741 char *n_name; 3742 char **n_aliases; 3743 int n_addrtype; 3744 unsigned int n_net; 3745 } 3746 ; 3747 #define AI_PASSIVE 0x0001 3748 #define AI_CANONNAME 0x0002 3749 #define AI_NUMERICHOST 0x0004 3750 3751 struct addrinfo 3752 { 3753 int ai_flags; 3754 int ai_family; 3755 int ai_socktype; 3756 int ai_protocol; 3757 socklen_t ai_addrlen; 3758 struct sockaddr *ai_addr; 3759 char *ai_canonname; 3760 struct addrinfo *ai_next; 3761 } 3762 ; 3763 #define NI_NUMERICHOST 1 3764 #define NI_DGRAM 16 3765 #define NI_NUMERICSERV 2 3766 #define NI_NOFQDN 4 3767 #define NI_NAMEREQD 8 3768 3769 #define EAI_BADFLAGS -1 3770 #define EAI_MEMORY -10 3771 #define EAI_SYSTEM -11 3772 #define EAI_NONAME -2 3773 #define EAI_AGAIN -3 3774 #define EAI_FAIL -4 3775 #define EAI_NODATA -5 3776 #define EAI_FAMILY -6 3777 #define EAI_SOCKTYPE -7 3778 #define EAI_SERVICE -8 3779 #define EAI_ADDRFAMILY -9 3780 3781 ------------------------------------------------------------------------------- 3782 3783 netinet/in.h 3784 3785 #define IPPROTO_IP 0 3786 #define IPPROTO_ICMP 1 3787 #define IPPROTO_UDP 17 3788 #define IPPROTO_IGMP 2 3789 #define IPPROTO_RAW 255 3790 #define IPPROTO_IPV6 41 3791 #define IPPROTO_ICMPV6 58 3792 #define IPPROTO_TCP 6 3793 3794 typedef uint16_t in_port_t; 3795 3796 struct in_addr 3797 { 3798 uint32_t s_addr; 3799 } 3800 ; 3801 typedef uint32_t in_addr_t; 3802 #define INADDR_NONE ((in_addr_t) 0xffffffff) 3803 #define INADDR_BROADCAST (0xffffffff) 3804 #define INADDR_ANY 0 3805 3806 struct in6_addr 3807 { 3808 union 3809 { 3810 uint8_t u6_addr8[16]; 3811 uint16_t u6_addr16[8]; 3812 uint32_t u6_addr32[4]; 3813 } 3814 in6_u; 3815 } 3816 ; 3817 #define IN6ADDR_ANY_INIT { { { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 } } } 3818 #define IN6ADDR_LOOPBACK_INIT { { { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 } } } 3819 3820 #define INET_ADDRSTRLEN 16 3821 3822 struct sockaddr_in 3823 { 3824 sa_family_t sin_family; 3825 unsigned short sin_port; 3826 struct in_addr sin_addr; 3827 unsigned char sin_zero[8]; 3828 } 3829 ; 3830 #define INET6_ADDRSTRLEN 46 3831 3832 struct sockaddr_in6 3833 { 3834 unsigned short sin6_family; 3835 uint16_t sin6_port; 3836 uint32_t sin6_flowinfo; 3837 struct in6_addr sin6_addr; 3838 uint32_t sin6_scope_id; 3839 } 3840 ; 3841 #define SOL_IP 0 3842 #define IP_TOS 1 3843 #define IPV6_UNICAST_HOPS 16 3844 #define IPV6_MULTICAST_IF 17 3845 #define IPV6_MULTICAST_HOPS 18 3846 #define IPV6_MULTICAST_LOOP 19 3847 #define IPV6_JOIN_GROUP 20 3848 #define IPV6_LEAVE_GROUP 21 3849 #define IPV6_V6ONLY 26 3850 #define IP_MULTICAST_IF 32 3851 #define IP_MULTICAST_TTL 33 3852 #define IP_MULTICAST_LOOP 34 3853 #define IP_ADD_MEMBERSHIP 35 3854 #define IP_DROP_MEMBERSHIP 36 3855 3856 struct ipv6_mreq 3857 { 3858 struct in6_addr ipv6mr_multiaddr; 3859 int ipv6mr_interface; 3860 } 3861 ; 3862 struct ip_mreq 3863 { 3864 struct in_addr imr_multiaddr; 3865 struct in_addr imr_interface; 3866 } 3867 ; 3868 3869 ------------------------------------------------------------------------------- 3870 3871 netinet/tcp.h 3872 3873 #define TCP_NODELAY 1 3874 #define SOL_TCP 6 3875 3876 ------------------------------------------------------------------------------- 3877 3878 netinet/udp.h 3879 3880 #define SOL_UDP 17 3881 3882 ------------------------------------------------------------------------------- 3883 3884 nl_types.h 3885 3886 #define NL_CAT_LOCALE 1 3887 #define NL_SETD 1 3888 3889 typedef void *nl_catd; 3890 3891 typedef int nl_item; 3892 3893 ------------------------------------------------------------------------------- 3894 3895 pty.h 3896 3897 struct winsize 3898 { 3899 unsigned short ws_row; 3900 unsigned short ws_col; 3901 unsigned short ws_xpixel; 3902 unsigned short ws_ypixel; 3903 } 3904 ; 3905 3906 ------------------------------------------------------------------------------- 3907 3908 pwd.h 3909 3910 struct passwd 3911 { 3912 char *pw_name; 3913 char *pw_passwd; 3914 uid_t pw_uid; 3915 gid_t pw_gid; 3916 char *pw_gecos; 3917 char *pw_dir; 3918 char *pw_shell; 3919 } 3920 ; 3921 3922 ------------------------------------------------------------------------------- 3923 3924 regex.h 3925 3926 #define RE_BACKSLASH_ESCAPE_IN_LISTS ((unsigned long int)1) 3927 #define RE_BK_PLUS_QM (RE_BACKSLASH_ESCAPE_IN_LISTS<<1) 3928 #define RE_SYNTAX_AWK (RE_BACKSLASH_ESCAPE_IN_LISTS|RE_DOT_NOT_NULL|RE_NO_BK_PARENS| RE_NO_BK_REFS| RE_NO_BK_VBAR| RE_NO_EMPTY_RANGES| RE_DOT_NEWLINE| RE_CONTEXT_INDEP_ANCHORS| RE_UNMATCHED_RIGHT_PAREN_ORD | RE_NO_GNU_OPS) 3929 #define RE_CHAR_CLASSES (RE_BK_PLUS_QM<<1) 3930 #define RE_SYNTAX_GREP (RE_BK_PLUS_QM|RE_CHAR_CLASSES|RE_HAT_LISTS_NOT_NEWLINE|RE_INTERVALS|RE_NEWLINE_ALT) 3931 #define RE_CONTEXT_INDEP_ANCHORS (RE_CHAR_CLASSES<<1) 3932 #define RE_SYNTAX_EGREP (RE_CHAR_CLASSES|RE_CONTEXT_INDEP_ANCHORS| RE_CONTEXT_INDEP_OPS|RE_HAT_LISTS_NOT_NEWLINE|RE_NEWLINE_ALT|RE_NO_BK_PARENS|RE_NO_BK_VBAR) 3933 #define _RE_SYNTAX_POSIX_COMMON (RE_CHAR_CLASSES|RE_DOT_NEWLINE|RE_DOT_NOT_NULL|RE_INTERVALS|RE_NO_EMPTY_RANGES) 3934 #define RE_CONTEXT_INDEP_OPS (RE_CONTEXT_INDEP_ANCHORS<<1) 3935 #define RE_CONTEXT_INVALID_OPS (RE_CONTEXT_INDEP_OPS<<1) 3936 #define RE_DOT_NEWLINE (RE_CONTEXT_INVALID_OPS<<1) 3937 #define RE_INVALID_INTERVAL_ORD (RE_DEBUG<<1) 3938 #define RE_DOT_NOT_NULL (RE_DOT_NEWLINE<<1) 3939 #define RE_HAT_LISTS_NOT_NEWLINE (RE_DOT_NOT_NULL<<1) 3940 #define RE_INTERVALS (RE_HAT_LISTS_NOT_NEWLINE<<1) 3941 #define RE_LIMITED_OPS (RE_INTERVALS<<1) 3942 #define RE_NEWLINE_ALT (RE_LIMITED_OPS<<1) 3943 #define RE_NO_BK_BRACES (RE_NEWLINE_ALT<<1) 3944 #define RE_NO_BK_PARENS (RE_NO_BK_BRACES<<1) 3945 #define RE_NO_BK_REFS (RE_NO_BK_PARENS<<1) 3946 #define RE_NO_BK_VBAR (RE_NO_BK_REFS<<1) 3947 #define RE_NO_EMPTY_RANGES (RE_NO_BK_VBAR<<1) 3948 #define RE_UNMATCHED_RIGHT_PAREN_ORD (RE_NO_EMPTY_RANGES<<1) 3949 #define RE_DEBUG (RE_NO_GNU_OPS<<1) 3950 #define RE_NO_GNU_OPS (RE_NO_POSIX_BACKTRACKING<<1) 3951 #define RE_SYNTAX_POSIX_EGREP (RE_SYNTAX_EGREP|RE_INTERVALS|RE_NO_BK_BRACES|RE_INVALID_INTERVAL_ORD) 3952 #define RE_SYNTAX_POSIX_AWK (RE_SYNTAX_POSIX_EXTENDED|RE_BACKSLASH_ESCAPE_IN_LISTS|RE_INTERVALS|RE_NO_GNU_OPS) 3953 #define RE_NO_POSIX_BACKTRACKING (RE_UNMATCHED_RIGHT_PAREN_ORD<<1) 3954 #define RE_SYNTAX_POSIX_BASIC (_RE_SYNTAX_POSIX_COMMON|RE_BK_PLUS_QM) 3955 #define RE_SYNTAX_POSIX_EXTENDED (_RE_SYNTAX_POSIX_COMMON|RE_CONTEXT_INDEP_ANCHORS|RE_CONTEXT_INDEP_OPS|RE_NO_BK_BRACES|RE_NO_BK_PARENS|RE_NO_BK_VBAR|RE_CONTEXT_INVALID_OPS|RE_UNMATCHED_RIGHT_PAREN_ORD) 3956 #define RE_SYNTAX_POSIX_MINIMAL_EXTENDED (_RE_SYNTAX_POSIX_COMMON|RE_CONTEXT_INDEP_ANCHORS|RE_CONTEXT_INVALID_OPS|RE_NO_BK_BRACES|RE_NO_BK_PARENS|RE_NO_BK_REFS|RE_NO_BK_VBAR|RE_UNMATCHED_RIGHT_PAREN_ORD) 3957 #define RE_SYNTAX_POSIX_MINIMAL_BASIC (_RE_SYNTAX_POSIX_COMMON|RE_LIMITED_OPS) 3958 #define RE_SYNTAX_ED RE_SYNTAX_POSIX_BASIC 3959 #define RE_SYNTAX_SED RE_SYNTAX_POSIX_BASIC 3960 3961 typedef unsigned long reg_syntax_t; 3962 3963 typedef struct re_pattern_buffer 3964 { 3965 unsigned char *buffer; 3966 unsigned long allocated; 3967 unsigned long used; 3968 reg_syntax_t syntax; 3969 char *fastmap; 3970 char *translate; 3971 size_t re_nsub; 3972 unsigned int can_be_null:1; 3973 unsigned int regs_allocated:2; 3974 unsigned int fastmap_accurate:1; 3975 unsigned int no_sub:1; 3976 unsigned int not_bol:1; 3977 unsigned int not_eol:1; 3978 unsigned int newline_anchor:1; 3979 } 3980 regex_t; 3981 typedef int regoff_t; 3982 typedef struct 3983 { 3984 regoff_t rm_so; 3985 regoff_t rm_eo; 3986 } 3987 regmatch_t; 3988 #define REG_NOTEOL (1<<1) 3989 #define REG_ICASE (REG_EXTENDED<<1) 3990 #define REG_NEWLINE (REG_ICASE<<1) 3991 #define REG_NOSUB (REG_NEWLINE<<1) 3992 #define REG_NOMATCH -1 3993 #define REG_EXTENDED 1 3994 #define REG_NOTBOL 1 3995 3996 ------------------------------------------------------------------------------- 3997 3998 rpc/auth.h 3999 4000 enum auth_stat 4001 { 4002 AUTH_OK, AUTH_BADCRED = 1, AUTH_REJECTEDCRED = 2, AUTH_BADVERF = 4003 3, AUTH_REJECTEDVERF = 4, AUTH_TOOWEAK = 5, AUTH_INVALIDRESP = 4004 6, AUTH_FAILED = 7 4005 } 4006 ; 4007 4008 union des_block 4009 { 4010 struct 4011 { 4012 u_int32_t high; 4013 u_int32_t low; 4014 } 4015 key; 4016 char c[8]; 4017 } 4018 ; 4019 4020 struct opaque_auth 4021 { 4022 enum_t oa_flavor; 4023 caddr_t oa_base; 4024 u_int oa_length; 4025 } 4026 ; 4027 4028 typedef struct AUTH 4029 { 4030 struct opaque_auth ah_cred; 4031 struct opaque_auth ah_verf; 4032 union des_block ah_key; 4033 struct auth_ops *ah_ops; 4034 caddr_t ah_private; 4035 } 4036 AUTH; 4037 4038 struct auth_ops 4039 { 4040 void (*ah_nextverf) (struct AUTH *); 4041 int (*ah_marshal) (struct AUTH *, XDR *); 4042 int (*ah_validate) (struct AUTH *, struct opaque_auth *); 4043 int (*ah_refresh) (struct AUTH *); 4044 void (*ah_destroy) (struct AUTH *); 4045 } 4046 ; 4047 4048 ------------------------------------------------------------------------------- 4049 4050 rpc/clnt.h 4051 4052 #define clnt_control(cl,rq,in) ((*(cl)->cl_ops->cl_control)(cl,rq,in)) 4053 #define clnt_abort(rh) ((*(rh)->cl_ops->cl_abort)(rh)) 4054 #define clnt_call(rh, proc, xargs, argsp, xres, resp, secs) ((*(rh)->cl_ops->cl_call)(rh, proc, xargs, argsp, xres, resp, secs)) 4055 #define clnt_destroy(rh) ((*(rh)->cl_ops->cl_destroy)(rh)) 4056 #define clnt_freeres(rh,xres,resp) ((*(rh)->cl_ops->cl_freeres)(rh,xres,resp)) 4057 #define clnt_geterr(rh,errp) ((*(rh)->cl_ops->cl_geterr)(rh, errp)) 4058 #define NULLPROC ((u_long)0) 4059 #define CLSET_TIMEOUT 1 4060 #define CLGET_XID 10 4061 #define CLSET_XID 11 4062 #define CLGET_VERS 12 4063 #define CLSET_VERS 13 4064 #define CLGET_PROG 14 4065 #define CLSET_PROG 15 4066 #define CLGET_TIMEOUT 2 4067 #define CLGET_SERVER_ADDR 3 4068 #define CLSET_RETRY_TIMEOUT 4 4069 #define CLGET_RETRY_TIMEOUT 5 4070 #define CLGET_FD 6 4071 #define CLGET_SVC_ADDR 7 4072 #define CLSET_FD_CLOSE 8 4073 #define CLSET_FD_NCLOSE 9 4074 4075 enum clnt_stat 4076 { 4077 RPC_SUCCESS, RPC_CANTENCODEARGS = 1, RPC_CANTDECODERES = 2, RPC_CANTSEND = 4078 3, RPC_CANTRECV = 4, RPC_TIMEDOUT = 5, RPC_VERSMISMATCH = 4079 6, RPC_AUTHERROR = 7, RPC_PROGUNAVAIL = 8, RPC_PROGVERSMISMATCH = 4080 9, RPC_PROCUNAVAIL = 10, RPC_CANTDECODEARGS = 11, RPC_SYSTEMERROR = 4081 12, RPC_NOBROADCAST = 21, RPC_UNKNOWNHOST = 13, RPC_UNKNOWNPROTO = 4082 17, RPC_UNKNOWNADDR = 19, RPC_RPCBFAILURE = 14, RPC_PROGNOTREGISTERED = 4083 15, RPC_N2AXLATEFAILURE = 22, RPC_FAILED = 16, RPC_INTR = 4084 18, RPC_TLIERROR = 20, RPC_UDERROR = 23, RPC_INPROGRESS = 4085 24, RPC_STALERACHANDLE = 25 4086 } 4087 ; 4088 struct rpc_err 4089 { 4090 enum clnt_stat re_status; 4091 union 4092 { 4093 int RE_errno; 4094 enum auth_stat RE_why; 4095 struct 4096 { 4097 u_long low; 4098 u_long high; 4099 } 4100 RE_vers; 4101 struct 4102 { 4103 long s1; 4104 long s2; 4105 } 4106 RE_lb; 4107 } 4108 ru; 4109 } 4110 ; 4111 4112 typedef struct CLIENT 4113 { 4114 struct AUTH *cl_auth; 4115 struct clnt_ops *cl_ops; 4116 caddr_t cl_private; 4117 } 4118 CLIENT; 4119 4120 struct clnt_ops 4121 { 4122 enum clnt_stat (*cl_call) (struct CLIENT *, u_long, xdrproc_t, caddr_t, 4123 xdrproc_t, caddr_t, struct timeval); 4124 void (*cl_abort) (void); 4125 void (*cl_geterr) (struct CLIENT *, struct rpc_err *); 4126 bool_t (*cl_freeres) (struct CLIENT *, xdrproc_t, caddr_t); 4127 void (*cl_destroy) (struct CLIENT *); 4128 bool_t (*cl_control) (struct CLIENT *, int, char *); 4129 } 4130 ; 4131 4132 ------------------------------------------------------------------------------- 4133 4134 rpc/rpc_msg.h 4135 4136 enum msg_type 4137 { 4138 CALL, REPLY = 1 4139 } 4140 ; 4141 enum reply_stat 4142 { 4143 MSG_ACCEPTED, MSG_DENIED = 1 4144 } 4145 ; 4146 enum accept_stat 4147 { 4148 SUCCESS, PROG_UNAVAIL = 1, PROG_MISMATCH = 2, PROC_UNAVAIL = 4149 3, GARBAGE_ARGS = 4, SYSTEM_ERR = 5 4150 } 4151 ; 4152 enum reject_stat 4153 { 4154 RPC_MISMATCH, AUTH_ERROR = 1 4155 } 4156 ; 4157 4158 struct accepted_reply 4159 { 4160 struct opaque_auth ar_verf; 4161 enum accept_stat ar_stat; 4162 union 4163 { 4164 struct 4165 { 4166 unsigned long low; 4167 unsigned long high; 4168 } 4169 AR_versions; 4170 struct 4171 { 4172 caddr_t where; 4173 xdrproc_t proc; 4174 } 4175 AR_results; 4176 } 4177 ru; 4178 } 4179 ; 4180 4181 struct rejected_reply 4182 { 4183 enum reject_stat rj_stat; 4184 union 4185 { 4186 struct 4187 { 4188 unsigned long low; 4189 unsigned long high; 4190 } 4191 RJ_versions; 4192 enum auth_stat RJ_why; 4193 } 4194 ru; 4195 } 4196 ; 4197 4198 struct reply_body 4199 { 4200 enum reply_stat rp_stat; 4201 union 4202 { 4203 struct accepted_reply RP_ar; 4204 struct rejected_reply RP_dr; 4205 } 4206 ru; 4207 } 4208 ; 4209 4210 struct call_body 4211 { 4212 unsigned long cb_rpcvers; 4213 unsigned long cb_prog; 4214 unsigned long cb_vers; 4215 unsigned long cb_proc; 4216 struct opaque_auth cb_cred; 4217 struct opaque_auth cb_verf; 4218 } 4219 ; 4220 4221 struct rpc_msg 4222 { 4223 unsigned long rm_xid; 4224 enum msg_type rm_direction; 4225 union 4226 { 4227 struct call_body RM_cmb; 4228 struct reply_body RM_rmb; 4229 } 4230 ru; 4231 } 4232 ; 4233 4234 ------------------------------------------------------------------------------- 4235 4236 rpc/svc.h 4237 4238 #define svc_freeargs(xprt,xargs, argsp) (*(xprt)->xp_ops->xp_freeargs)((xprt), (xargs), (argsp)) 4239 #define svc_getargs(xprt,xargs, argsp) (*(xprt)->xp_ops->xp_getargs)((xprt), (xargs), (argsp)) 4240 #define RPC_ANYSOCK -1 4241 4242 typedef struct SVCXPRT 4243 { 4244 int xp_sock; 4245 u_short xp_port; 4246 struct xp_ops *xp_ops; 4247 int xp_addrlen; 4248 struct sockaddr_in xp_raddr; 4249 struct opaque_auth xp_verf; 4250 caddr_t xp_p1; 4251 caddr_t xp_p2; 4252 char xp_pad[256]; 4253 } 4254 SVCXPRT; 4255 4256 struct svc_req 4257 { 4258 rpcprog_t rq_prog; 4259 rpcvers_t rq_vers; 4260 rpcproc_t rq_proc; 4261 struct opaque_auth rq_cred; 4262 caddr_t rq_clntcred; 4263 SVCXPRT *rq_xprt; 4264 } 4265 ; 4266 4267 typedef void (*__dispatch_fn_t) (struct svc_req *, SVCXPRT *); 4268 4269 struct xp_ops 4270 { 4271 bool_t (*xp_recv) (SVCXPRT * __xprt, struct rpc_msg * __msg); 4272 enum xprt_stat (*xp_stat) (SVCXPRT * __xprt); 4273 bool_t (*xp_getargs) (SVCXPRT * __xprt, xdrproc_t __xdr_args, 4274 caddr_t args_ptr); 4275 bool_t (*xp_reply) (SVCXPRT * __xprt, struct rpc_msg * __msg); 4276 bool_t (*xp_freeargs) (SVCXPRT * __xprt, xdrproc_t __xdr_args, 4277 caddr_t args_ptr); 4278 void (*xp_destroy) (SVCXPRT * __xprt); 4279 } 4280 ; 4281 4282 ------------------------------------------------------------------------------- 4283 4284 rpc/types.h 4285 4286 typedef int bool_t; 4287 typedef int enum_t; 4288 typedef unsigned long rpcprog_t; 4289 typedef unsigned long rpcvers_t; 4290 typedef unsigned long rpcproc_t; 4291 typedef unsigned long rpcprot_t; 4292 4293 ------------------------------------------------------------------------------- 4294 4295 rpc/xdr.h 4296 4297 enum xdr_op 4298 { 4299 XDR_ENCODE, XDR_DECODE, XDR_FREE 4300 } 4301 ; 4302 typedef struct XDR 4303 { 4304 enum xdr_op x_op; 4305 struct xdr_ops *x_ops; 4306 caddr_t x_public; 4307 caddr_t x_private; 4308 caddr_t x_base; 4309 int x_handy; 4310 } 4311 XDR; 4312 4313 struct xdr_ops 4314 { 4315 bool_t (*x_getlong) (XDR * __xdrs, long *__lp); 4316 bool_t (*x_putlong) (XDR * __xdrs, long *__lp); 4317 bool_t (*x_getbytes) (XDR * __xdrs, caddr_t __addr, u_int __len); 4318 bool_t (*x_putbytes) (XDR * __xdrs, char *__addr, u_int __len); 4319 u_int (*x_getpostn) (XDR * __xdrs); 4320 bool_t (*x_setpostn) (XDR * __xdrs, u_int __pos); 4321 int32_t *(*x_inline) (XDR * __xdrs, int __len); 4322 void (*x_destroy) (XDR * __xdrs); 4323 bool_t (*x_getint32) (XDR * __xdrs, int32_t * __ip); 4324 bool_t (*x_putint32) (XDR * __xdrs, int32_t * __ip); 4325 } 4326 ; 4327 4328 typedef bool_t (*xdrproc_t) (XDR *, void *, ...); 4329 4330 struct xdr_discrim 4331 { 4332 int value; 4333 xdrproc_t proc; 4334 } 4335 ; 4336 4337 ------------------------------------------------------------------------------- 4338 4339 sched.h 4340 4341 #define SCHED_OTHER 0 4342 #define SCHED_FIFO 1 4343 #define SCHED_RR 2 4344 4345 struct sched_param 4346 { 4347 int sched_priority; 4348 } 4349 ; 4350 4351 ------------------------------------------------------------------------------- 4352 4353 search.h 4354 4355 typedef struct entry 4356 { 4357 char *key; 4358 void *data; 4359 } 4360 ENTRY; 4361 typedef enum 4362 { 4363 FIND, ENTER 4364 } 4365 ACTION; 4366 typedef enum 4367 { 4368 preorder, postorder, endorder, leaf 4369 } 4370 VISIT; 4371 4372 typedef void (*__action_fn_t) (void *__nodep, VISIT __value, int __level); 4373 4374 ------------------------------------------------------------------------------- 4375 4376 setjmp.h 4377 4378 #define setjmp(env) _setjmp(env) 4379 #define sigsetjmp(a,b) __sigsetjmp(a,b) 4380 4381 struct __jmp_buf_tag 4382 { 4383 __jmp_buf __jmpbuf; 4384 int __mask_was_saved; 4385 sigset_t __saved_mask; 4386 } 4387 ; 4388 4389 typedef struct __jmp_buf_tag jmp_buf[1]; 4390 typedef jmp_buf sigjmp_buf; 4391 4392 ------------------------------------------------------------------------------- 4393 4394 signal.h 4395 4396 #define SIGRTMAX (__libc_current_sigrtmax ()) 4397 #define SIGRTMIN (__libc_current_sigrtmin ()) 4398 #define SIG_BLOCK 0 4399 #define SIG_UNBLOCK 1 4400 #define SIG_SETMASK 2 4401 #define NSIG 65 4402 4403 typedef int sig_atomic_t; 4404 struct sigstack 4405 { 4406 void *ss_sp; 4407 int ss_onstack; 4408 } 4409 ; 4410 4411 typedef void (*sighandler_t) (int); 4412 #define SIG_HOLD ((sighandler_t) 2) 4413 #define SIG_ERR ((sighandler_t)-1) 4414 #define SIG_DFL ((sighandler_t)0) 4415 #define SIG_IGN ((sighandler_t)1) 4416 4417 #define SIGHUP 1 4418 #define SIGUSR1 10 4419 #define SIGSEGV 11 4420 #define SIGUSR2 12 4421 #define SIGPIPE 13 4422 #define SIGALRM 14 4423 #define SIGTERM 15 4424 #define SIGSTKFLT 16 4425 #define SIGCHLD 17 4426 #define SIGCONT 18 4427 #define SIGSTOP 19 4428 #define SIGINT 2 4429 #define SIGTSTP 20 4430 #define SIGTTIN 21 4431 #define SIGTTOU 22 4432 #define SIGURG 23 4433 #define SIGXCPU 24 4434 #define SIGXFSZ 25 4435 #define SIGVTALRM 26 4436 #define SIGPROF 27 4437 #define SIGWINCH 28 4438 #define SIGIO 29 4439 #define SIGQUIT 3 4440 #define SIGPWR 30 4441 #define SIGSYS 31 4442 #define SIGUNUSED 31 4443 #define SIGILL 4 4444 #define SIGTRAP 5 4445 #define SIGABRT 6 4446 #define SIGIOT 6 4447 #define SIGBUS 7 4448 #define SIGFPE 8 4449 #define SIGKILL 9 4450 #define SIGCLD SIGCHLD 4451 #define SIGPOLL SIGIO 4452 4453 #define SV_ONSTACK (1<<0) 4454 #define SV_INTERRUPT (1<<1) 4455 #define SV_RESETHAND (1<<2) 4456 4457 typedef union sigval 4458 { 4459 int sival_int; 4460 void *sival_ptr; 4461 } 4462 sigval_t; 4463 #define SIGEV_SIGNAL 0 4464 #define SIGEV_NONE 1 4465 #define SIGEV_THREAD 2 4466 4467 typedef struct sigevent 4468 { 4469 sigval_t sigev_value; 4470 int sigev_signo; 4471 int sigev_notify; 4472 union 4473 { 4474 int _pad[SIGEV_PAD_SIZE]; 4475 struct 4476 { 4477 void (*sigev_thread_func) (sigval_t); 4478 void *_attribute; 4479 } 4480 _sigev_thread; 4481 } 4482 _sigev_un; 4483 } 4484 sigevent_t; 4485 #define si_pid _sifields._kill._pid 4486 #define si_uid _sifields._kill._uid 4487 #define si_value _sifields._rt._sigval 4488 #define si_int _sifields._rt._sigval.sival_int 4489 #define si_ptr _sifields._rt._sigval.sival_ptr 4490 #define si_status _sifields._sigchld._status 4491 #define si_stime _sifields._sigchld._stime 4492 #define si_utime _sifields._sigchld._utime 4493 #define si_addr _sifields._sigfault._addr 4494 #define si_band _sifields._sigpoll._band 4495 #define si_fd _sifields._sigpoll._fd 4496 #define si_timer1 _sifields._timer._timer1 4497 #define si_timer2 _sifields._timer._timer2 4498 4499 typedef struct siginfo 4500 { 4501 int si_signo; 4502 int si_errno; 4503 int si_code; 4504 union 4505 { 4506 int _pad[SI_PAD_SIZE]; 4507 struct 4508 { 4509 pid_t _pid; 4510 uid_t _uid; 4511 } 4512 _kill; 4513 struct 4514 { 4515 unsigned int _timer1; 4516 unsigned int _timer2; 4517 } 4518 _timer; 4519 struct 4520 { 4521 pid_t _pid; 4522 uid_t _uid; 4523 sigval_t _sigval; 4524 } 4525 _rt; 4526 struct 4527 { 4528 pid_t _pid; 4529 uid_t _uid; 4530 int _status; 4531 clock_t _utime; 4532 clock_t _stime; 4533 } 4534 _sigchld; 4535 struct 4536 { 4537 void *_addr; 4538 } 4539 _sigfault; 4540 struct 4541 { 4542 int _band; 4543 int _fd; 4544 } 4545 _sigpoll; 4546 } 4547 _sifields; 4548 } 4549 siginfo_t; 4550 #define SI_QUEUE -1 4551 #define SI_TIMER -2 4552 #define SI_MESGQ -3 4553 #define SI_ASYNCIO -4 4554 #define SI_SIGIO -5 4555 #define SI_TKILL -6 4556 #define SI_ASYNCNL -60 4557 #define SI_USER 0 4558 #define SI_KERNEL 0x80 4559 4560 #define ILL_ILLOPC 1 4561 #define ILL_ILLOPN 2 4562 #define ILL_ILLADR 3 4563 #define ILL_ILLTRP 4 4564 #define ILL_PRVOPC 5 4565 #define ILL_PRVREG 6 4566 #define ILL_COPROC 7 4567 #define ILL_BADSTK 8 4568 4569 #define FPE_INTDIV 1 4570 #define FPE_INTOVF 2 4571 #define FPE_FLTDIV 3 4572 #define FPE_FLTOVF 4 4573 #define FPE_FLTUND 5 4574 #define FPE_FLTRES 6 4575 #define FPE_FLTINV 7 4576 #define FPE_FLTSUB 8 4577 4578 #define SEGV_MAPERR 1 4579 #define SEGV_ACCERR 2 4580 4581 #define BUS_ADRALN 1 4582 #define BUS_ADRERR 2 4583 #define BUS_OBJERR 3 4584 4585 #define TRAP_BRKPT 1 4586 #define TRAP_TRACE 2 4587 4588 #define CLD_EXITED 1 4589 #define CLD_KILLED 2 4590 #define CLD_DUMPED 3 4591 #define CLD_TRAPPED 4 4592 #define CLD_STOPPED 5 4593 #define CLD_CONTINUED 6 4594 4595 #define POLL_IN 1 4596 #define POLL_OUT 2 4597 #define POLL_MSG 3 4598 #define POLL_ERR 4 4599 #define POLL_PRI 5 4600 #define POLL_HUP 6 4601 4602 typedef struct 4603 { 4604 unsigned long sig[_SIGSET_NWORDS]; 4605 } 4606 sigset_t; 4607 #define SA_NOCLDSTOP 0x00000001 4608 #define SA_NOCLDWAIT 0x00000002 4609 #define SA_SIGINFO 0x00000004 4610 #define SA_ONSTACK 0x08000000 4611 #define SA_RESTART 0x10000000 4612 #define SA_INTERRUPT 0x20000000 4613 #define SA_NODEFER 0x40000000 4614 #define SA_RESETHAND 0x80000000 4615 #define SA_NOMASK SA_NODEFER 4616 #define SA_ONESHOT SA_RESETHAND 4617 4618 typedef struct sigaltstack 4619 { 4620 void *ss_sp; 4621 int ss_flags; 4622 size_t ss_size; 4623 } 4624 stack_t; 4625 #define SS_ONSTACK 1 4626 #define SS_DISABLE 2 4627 4628 ------------------------------------------------------------------------------- 4629 4630 stddef.h 4631 4632 #define offsetof(TYPE,MEMBER) ((size_t)& ((TYPE*)0)->MEMBER) 4633 #define NULL (0L) 4634 4635 typedef int wchar_t; 4636 4637 ------------------------------------------------------------------------------- 4638 4639 stdio.h 4640 4641 #define EOF (-1) 4642 #define P_tmpdir "/tmp" 4643 #define FOPEN_MAX 16 4644 #define L_tmpnam 20 4645 #define FILENAME_MAX 4096 4646 #define BUFSIZ 8192 4647 #define L_ctermid 9 4648 #define L_cuserid 9 4649 4650 typedef struct 4651 { 4652 off_t __pos; 4653 mbstate_t __state; 4654 } 4655 fpos_t; 4656 typedef struct 4657 { 4658 off64_t __pos; 4659 mbstate_t __state; 4660 } 4661 fpos64_t; 4662 4663 typedef struct _IO_FILE FILE; 4664 #define _IOFBF 0 4665 #define _IOLBF 1 4666 #define _IONBF 2 4667 4668 ------------------------------------------------------------------------------- 4669 4670 stdlib.h 4671 4672 #define MB_CUR_MAX (__ctype_get_mb_cur_max()) 4673 #define EXIT_SUCCESS 0 4674 #define EXIT_FAILURE 1 4675 #define RAND_MAX 2147483647 4676 4677 typedef int (*__compar_fn_t) (const void *, const void *); 4678 struct random_data 4679 { 4680 int32_t *fptr; 4681 int32_t *rptr; 4682 int32_t *state; 4683 int rand_type; 4684 int rand_deg; 4685 int rand_sep; 4686 int32_t *end_ptr; 4687 } 4688 ; 4689 4690 typedef struct 4691 { 4692 int quot; 4693 int rem; 4694 } 4695 div_t; 4696 4697 typedef struct 4698 { 4699 long quot; 4700 long rem; 4701 } 4702 ldiv_t; 4703 4704 typedef struct 4705 { 4706 long long quot; 4707 long long rem; 4708 } 4709 lldiv_t; 4710 4711 ------------------------------------------------------------------------------- 4712 4713 sys/file.h 4714 4715 #define LOCK_SH 1 4716 #define LOCK_EX 2 4717 #define LOCK_NB 4 4718 #define LOCK_UN 8 4719 4720 ------------------------------------------------------------------------------- 4721 4722 sys/ipc.h 4723 4724 #define IPC_PRIVATE ((key_t)0) 4725 #define IPC_RMID 0 4726 #define IPC_CREAT 00001000 4727 #define IPC_EXCL 00002000 4728 #define IPC_NOWAIT 00004000 4729 #define IPC_SET 1 4730 #define IPC_STAT 2 4731 4732 ------------------------------------------------------------------------------- 4733 4734 sys/mman.h 4735 4736 #define MAP_FAILED ((void*)-1) 4737 #define PROT_NONE 0x0 4738 #define MAP_SHARED 0x01 4739 #define MAP_PRIVATE 0x02 4740 #define PROT_READ 0x1 4741 #define MAP_FIXED 0x10 4742 #define PROT_WRITE 0x2 4743 #define MAP_ANONYMOUS 0x20 4744 #define PROT_EXEC 0x4 4745 #define MS_ASYNC 1 4746 #define MS_INVALIDATE 2 4747 #define MS_SYNC 4 4748 #define MAP_ANON MAP_ANONYMOUS 4749 4750 ------------------------------------------------------------------------------- 4751 4752 sys/msg.h 4753 4754 #define MSG_NOERROR 010000 4755 4756 ------------------------------------------------------------------------------- 4757 4758 sys/param.h 4759 4760 #define NOFILE 256 4761 #define MAXPATHLEN 4096 4762 4763 ------------------------------------------------------------------------------- 4764 4765 sys/poll.h 4766 4767 #define POLLIN 0x0001 4768 #define POLLPRI 0x0002 4769 #define POLLOUT 0x0004 4770 #define POLLERR 0x0008 4771 #define POLLHUP 0x0010 4772 #define POLLNVAL 0x0020 4773 4774 struct pollfd 4775 { 4776 int fd; 4777 short events; 4778 short revents; 4779 } 4780 ; 4781 typedef unsigned long nfds_t; 4782 4783 ------------------------------------------------------------------------------- 4784 4785 sys/resource.h 4786 4787 #define RUSAGE_CHILDREN (-1) 4788 #define RUSAGE_BOTH (-2) 4789 #define RLIM_INFINITY (~0UL) 4790 #define RLIM_SAVED_CUR -1 4791 #define RLIM_SAVED_MAX -1 4792 #define RLIMIT_CPU 0 4793 #define RUSAGE_SELF 0 4794 #define RLIMIT_FSIZE 1 4795 #define RLIMIT_DATA 2 4796 #define RLIMIT_STACK 3 4797 #define RLIMIT_CORE 4 4798 #define RLIMIT_NOFILE 7 4799 #define RLIMIT_AS 9 4800 4801 typedef unsigned long rlim_t; 4802 typedef unsigned long long rlim64_t; 4803 typedef int __rlimit_resource_t; 4804 4805 struct rlimit 4806 { 4807 rlim_t rlim_cur; 4808 rlim_t rlim_max; 4809 } 4810 ; 4811 struct rlimit64 4812 { 4813 rlim64_t rlim_cur; 4814 rlim64_t rlim_max; 4815 } 4816 ; 4817 4818 struct rusage 4819 { 4820 struct timeval ru_utime; 4821 struct timeval ru_stime; 4822 long ru_maxrss; 4823 long ru_ixrss; 4824 long ru_idrss; 4825 long ru_isrss; 4826 long ru_minflt; 4827 long ru_majflt; 4828 long ru_nswap; 4829 long ru_inblock; 4830 long ru_oublock; 4831 long ru_msgsnd; 4832 long ru_msgrcv; 4833 long ru_nsignals; 4834 long ru_nvcsw; 4835 long ru_nivcsw; 4836 } 4837 ; 4838 4839 enum __priority_which 4840 { 4841 PRIO_PROCESS, PRIO_PGRP = 1, PRIO_USER = 2 4842 } 4843 ; 4844 #define PRIO_PGRP PRIO_PGRP 4845 #define PRIO_PROCESS PRIO_PROCESS 4846 #define PRIO_USER PRIO_USER 4847 4848 typedef enum __priority_which __priority_which_t; 4849 4850 ------------------------------------------------------------------------------- 4851 4852 sys/sem.h 4853 4854 #define SEM_UNDO 0x1000 4855 #define GETPID 11 4856 #define GETVAL 12 4857 #define GETALL 13 4858 #define GETNCNT 14 4859 #define GETZCNT 15 4860 #define SETVAL 16 4861 #define SETALL 17 4862 4863 struct sembuf 4864 { 4865 short sem_num; 4866 short sem_op; 4867 short sem_flg; 4868 } 4869 ; 4870 4871 ------------------------------------------------------------------------------- 4872 4873 sys/shm.h 4874 4875 #define SHM_RDONLY 010000 4876 #define SHM_W 0200 4877 #define SHM_RND 020000 4878 #define SHM_R 0400 4879 #define SHM_REMAP 040000 4880 #define SHM_LOCK 11 4881 #define SHM_UNLOCK 12 4882 4883 ------------------------------------------------------------------------------- 4884 4885 sys/socket.h 4886 4887 #define SHUT_RD 0 4888 #define MSG_WAITALL 0x100 4889 #define MSG_TRUNC 0x20 4890 #define MSG_EOR 0x80 4891 #define SIOCGIFCONF 0x8912 4892 #define SIOCGIFFLAGS 0x8913 4893 #define SIOCGIFADDR 0x8915 4894 #define SIOCGIFNETMASK 0x891b 4895 #define MSG_OOB 1 4896 #define SHUT_WR 1 4897 #define MSG_PEEK 2 4898 #define SHUT_RDWR 2 4899 #define MSG_DONTROUTE 4 4900 #define MSG_CTRUNC 8 4901 #define PF_UNSPEC AF_UNSPEC 4902 4903 struct linger 4904 { 4905 int l_onoff; 4906 int l_linger; 4907 } 4908 ; 4909 struct cmsghdr 4910 { 4911 size_t cmsg_len; 4912 int cmsg_level; 4913 int cmsg_type; 4914 } 4915 ; 4916 struct iovec 4917 { 4918 void *iov_base; 4919 size_t iov_len; 4920 } 4921 ; 4922 4923 typedef unsigned short sa_family_t; 4924 typedef unsigned int socklen_t; 4925 4926 struct sockaddr 4927 { 4928 sa_family_t sa_family; 4929 char sa_data[14]; 4930 } 4931 ; 4932 struct sockaddr_storage 4933 { 4934 sa_family_t ss_family; 4935 __ss_aligntype __ss_align; 4936 char __ss_padding[(128 - (2 * sizeof (__ss_aligntype)))]; 4937 } 4938 ; 4939 4940 struct msghdr 4941 { 4942 void *msg_name; 4943 int msg_namelen; 4944 struct iovec *msg_iov; 4945 size_t msg_iovlen; 4946 void *msg_control; 4947 size_t msg_controllen; 4948 unsigned int msg_flags; 4949 } 4950 ; 4951 #define AF_UNSPEC 0 4952 #define AF_UNIX 1 4953 #define AF_INET6 10 4954 #define AF_INET 2 4955 4956 #define PF_INET AF_INET 4957 #define PF_INET6 AF_INET6 4958 #define PF_UNIX AF_UNIX 4959 4960 #define SOCK_STREAM 1 4961 #define SOCK_PACKET 10 4962 #define SOCK_DGRAM 2 4963 #define SOCK_RAW 3 4964 #define SOCK_RDM 4 4965 #define SOCK_SEQPACKET 5 4966 4967 #define SOL_SOCKET 1 4968 #define SO_DEBUG 1 4969 #define SO_OOBINLINE 10 4970 #define SO_NO_CHECK 11 4971 #define SO_PRIORITY 12 4972 #define SO_LINGER 13 4973 #define SO_REUSEADDR 2 4974 #define SOL_RAW 255 4975 #define SO_TYPE 3 4976 #define SO_ERROR 4 4977 #define SO_DONTROUTE 5 4978 #define SO_BROADCAST 6 4979 #define SO_SNDBUF 7 4980 #define SO_RCVBUF 8 4981 #define SO_KEEPALIVE 9 4982 4983 ------------------------------------------------------------------------------- 4984 4985 sys/stat.h 4986 4987 #define S_ISBLK(m) (((m)& S_IFMT)==S_IFBLK) 4988 #define S_ISCHR(m) (((m)& S_IFMT)==S_IFCHR) 4989 #define S_ISDIR(m) (((m)& S_IFMT)==S_IFDIR) 4990 #define S_ISFIFO(m) (((m)& S_IFMT)==S_IFIFO) 4991 #define S_ISLNK(m) (((m)& S_IFMT)==S_IFLNK) 4992 #define S_ISREG(m) (((m)& S_IFMT)==S_IFREG) 4993 #define S_ISSOCK(m) (((m)& S_IFMT)==S_IFSOCK) 4994 #define S_TYPEISMQ(buf) ((buf)->st_mode - (buf)->st_mode) 4995 #define S_TYPEISSEM(buf) ((buf)->st_mode - (buf)->st_mode) 4996 #define S_TYPEISSHM(buf) ((buf)->st_mode - (buf)->st_mode) 4997 #define S_IRWXU (S_IREAD|S_IWRITE|S_IEXEC) 4998 #define S_IROTH (S_IRGRP>>3) 4999 #define S_IRGRP (S_IRUSR>>3) 5000 #define S_IRWXO (S_IRWXG>>3) 5001 #define S_IRWXG (S_IRWXU>>3) 5002 #define S_IWOTH (S_IWGRP>>3) 5003 #define S_IWGRP (S_IWUSR>>3) 5004 #define S_IXOTH (S_IXGRP>>3) 5005 #define S_IXGRP (S_IXUSR>>3) 5006 #define S_ISVTX 01000 5007 #define S_IXUSR 0x0040 5008 #define S_IWUSR 0x0080 5009 #define S_IRUSR 0x0100 5010 #define S_ISGID 0x0400 5011 #define S_ISUID 0x0800 5012 #define S_IFIFO 0x1000 5013 #define S_IFCHR 0x2000 5014 #define S_IFDIR 0x4000 5015 #define S_IFBLK 0x6000 5016 #define S_IFREG 0x8000 5017 #define S_IFLNK 0xa000 5018 #define S_IFSOCK 0xc000 5019 #define S_IFMT 0xf000 5020 #define st_atime st_atim.tv_sec 5021 #define st_ctime st_ctim.tv_sec 5022 #define st_mtime st_mtim.tv_sec 5023 #define S_IREAD S_IRUSR 5024 #define S_IWRITE S_IWUSR 5025 #define S_IEXEC S_IXUSR 5026 5027 ------------------------------------------------------------------------------- 5028 5029 sys/time.h 5030 5031 #define ITIMER_REAL 0 5032 #define ITIMER_VIRTUAL 1 5033 #define ITIMER_PROF 2 5034 5035 struct timezone 5036 { 5037 int tz_minuteswest; 5038 int tz_dsttime; 5039 } 5040 ; 5041 5042 typedef int __itimer_which_t; 5043 5044 struct timespec 5045 { 5046 time_t tv_sec; 5047 long tv_nsec; 5048 } 5049 ; 5050 5051 struct timeval 5052 { 5053 time_t tv_sec; 5054 suseconds_t tv_usec; 5055 } 5056 ; 5057 5058 struct itimerval 5059 { 5060 struct timeval it_interval; 5061 struct timeval it_value; 5062 } 5063 ; 5064 5065 ------------------------------------------------------------------------------- 5066 5067 sys/timeb.h 5068 5069 struct timeb 5070 { 5071 time_t time; 5072 unsigned short millitm; 5073 short timezone; 5074 short dstflag; 5075 } 5076 ; 5077 5078 ------------------------------------------------------------------------------- 5079 5080 sys/times.h 5081 5082 struct tms 5083 { 5084 clock_t tms_utime; 5085 clock_t tms_stime; 5086 clock_t tms_cutime; 5087 clock_t tms_cstime; 5088 } 5089 ; 5090 5091 ------------------------------------------------------------------------------- 5092 5093 sys/types.h 5094 5095 #define FD_ISSET(d,set) ((set)->fds_bits[((d)/(8*sizeof(long)))]& (1<<((d)%(8*sizeof(long))))) 5096 #define FD_CLR(d,set) ((set)->fds_bits[((d)/(8*sizeof(long)))]& =~(1<<((d)%(8*sizeof(long))))) 5097 #define FD_SET(d,set) ((set)->fds_bits[((d)/(8*sizeof(long)))]|=(1<<((d)%(8*sizeof(long))))) 5098 #define FALSE 0 5099 #define TRUE 1 5100 #define FD_SETSIZE 1024 5101 #define FD_ZERO(fdsetp) bzero(fdsetp, sizeof(*(fdsetp))) 5102 5103 typedef signed char int8_t; 5104 typedef short int16_t; 5105 typedef int int32_t; 5106 typedef unsigned char u_int8_t; 5107 typedef unsigned short u_int16_t; 5108 typedef unsigned int u_int32_t; 5109 typedef unsigned int uid_t; 5110 typedef int pid_t; 5111 typedef unsigned long off_t; 5112 typedef int key_t; 5113 typedef long suseconds_t; 5114 typedef unsigned int u_int; 5115 typedef struct 5116 { 5117 int __val[2]; 5118 } 5119 fsid_t; 5120 typedef unsigned int useconds_t; 5121 typedef unsigned long blksize_t; 5122 typedef long fd_mask; 5123 typedef int timer_t; 5124 typedef int clockid_t; 5125 5126 typedef unsigned int id_t; 5127 5128 typedef unsigned long long ino64_t; 5129 typedef long long loff_t; 5130 typedef unsigned long blkcnt_t; 5131 typedef unsigned long fsblkcnt_t; 5132 typedef unsigned long fsfilcnt_t; 5133 typedef unsigned long long blkcnt64_t; 5134 typedef unsigned long long fsblkcnt64_t; 5135 typedef unsigned long long fsfilcnt64_t; 5136 typedef unsigned char u_char; 5137 typedef unsigned short u_short; 5138 typedef unsigned long u_long; 5139 5140 typedef unsigned long ino_t; 5141 typedef unsigned int gid_t; 5142 typedef unsigned long long dev_t; 5143 typedef unsigned int mode_t; 5144 typedef unsigned long nlink_t; 5145 typedef char *caddr_t; 5146 5147 typedef struct 5148 { 5149 unsigned long fds_bits[__FDSET_LONGS]; 5150 } 5151 fd_set; 5152 5153 typedef long clock_t; 5154 typedef long time_t; 5155 5156 ------------------------------------------------------------------------------- 5157 5158 sys/un.h 5159 5160 #define UNIX_PATH_MAX 108 5161 5162 struct sockaddr_un 5163 { 5164 sa_family_t sun_family; 5165 char sun_path[UNIX_PATH_MAX]; 5166 } 5167 ; 5168 5169 ------------------------------------------------------------------------------- 5170 5171 sys/utsname.h 5172 5173 #define SYS_NMLN 65 5174 5175 struct utsname 5176 { 5177 char sysname[65]; 5178 char nodename[65]; 5179 char release[65]; 5180 char version[65]; 5181 char machine[65]; 5182 char domainname[65]; 5183 } 5184 ; 5185 5186 ------------------------------------------------------------------------------- 5187 5188 sys/wait.h 5189 5190 #define WIFSIGNALED(status) (!WIFSTOPPED(status) & & !WIFEXITED(status)) 5191 #define WIFSTOPPED(status) (((status) & 0xff) == 0x7f) 5192 #define WEXITSTATUS(status) (((status) & 0xff00) >> 8) 5193 #define WTERMSIG(status) ((status) & 0x7f) 5194 #define WCOREDUMP(status) ((status) & 0x80) 5195 #define WIFEXITED(status) (WTERMSIG(status) == 0) 5196 #define WNOHANG 0x00000001 5197 #define WUNTRACED 0x00000002 5198 #define WCOREFLAG 0x80 5199 #define WSTOPSIG(status) WEXITSTATUS(status) 5200 5201 typedef enum 5202 { 5203 P_ALL, P_PID, P_PGID 5204 } 5205 idtype_t; 5206 5207 ------------------------------------------------------------------------------- 5208 5209 syslog.h 5210 5211 #define LOG_EMERG 0 5212 #define LOG_PRIMASK 0x07 5213 #define LOG_ALERT 1 5214 #define LOG_CRIT 2 5215 #define LOG_ERR 3 5216 #define LOG_WARNING 4 5217 #define LOG_NOTICE 5 5218 #define LOG_INFO 6 5219 #define LOG_DEBUG 7 5220 5221 #define LOG_KERN (0<<3) 5222 #define LOG_AUTHPRIV (10<<3) 5223 #define LOG_FTP (11<<3) 5224 #define LOG_USER (1<<3) 5225 #define LOG_MAIL (2<<3) 5226 #define LOG_DAEMON (3<<3) 5227 #define LOG_AUTH (4<<3) 5228 #define LOG_SYSLOG (5<<3) 5229 #define LOG_LPR (6<<3) 5230 #define LOG_NEWS (7<<3) 5231 #define LOG_UUCP (8<<3) 5232 #define LOG_CRON (9<<3) 5233 #define LOG_FACMASK 0x03f8 5234 5235 #define LOG_LOCAL0 (16<<3) 5236 #define LOG_LOCAL1 (17<<3) 5237 #define LOG_LOCAL2 (18<<3) 5238 #define LOG_LOCAL3 (19<<3) 5239 #define LOG_LOCAL4 (20<<3) 5240 #define LOG_LOCAL5 (21<<3) 5241 #define LOG_LOCAL6 (22<<3) 5242 #define LOG_LOCAL7 (23<<3) 5243 5244 #define LOG_UPTO(pri) ((1 << ((pri)+1)) - 1) 5245 #define LOG_MASK(pri) (1 << (pri)) 5246 5247 #define LOG_PID 0x01 5248 #define LOG_CONS 0x02 5249 #define LOG_ODELAY 0x04 5250 #define LOG_NDELAY 0x08 5251 #define LOG_NOWAIT 0x10 5252 #define LOG_PERROR 0x20 5253 5254 ------------------------------------------------------------------------------- 5255 5256 termios.h 5257 5258 #define TCIFLUSH 0 5259 #define TCOOFF 0 5260 #define TCSANOW 0 5261 #define BS0 0000000 5262 #define CR0 0000000 5263 #define FF0 0000000 5264 #define NL0 0000000 5265 #define TAB0 0000000 5266 #define VT0 0000000 5267 #define OPOST 0000001 5268 #define OCRNL 0000010 5269 #define ONOCR 0000020 5270 #define ONLRET 0000040 5271 #define OFILL 0000100 5272 #define OFDEL 0000200 5273 #define NL1 0000400 5274 #define TCOFLUSH 1 5275 #define TCOON 1 5276 #define TCSADRAIN 1 5277 #define TCIOFF 2 5278 #define TCIOFLUSH 2 5279 #define TCSAFLUSH 2 5280 #define TCION 3 5281 5282 typedef unsigned int speed_t; 5283 typedef unsigned char cc_t; 5284 typedef unsigned int tcflag_t; 5285 #define NCCS 32 5286 5287 struct termios 5288 { 5289 tcflag_t c_iflag; 5290 tcflag_t c_oflag; 5291 tcflag_t c_cflag; 5292 tcflag_t c_lflag; 5293 cc_t c_line; 5294 cc_t c_cc[NCCS]; 5295 speed_t c_ispeed; 5296 speed_t c_ospeed; 5297 } 5298 ; 5299 #define VINTR 0 5300 #define VQUIT 1 5301 #define VLNEXT 15 5302 #define VERASE 2 5303 #define VKILL 3 5304 #define VEOF 4 5305 5306 #define IGNBRK 0000001 5307 #define BRKINT 0000002 5308 #define IGNPAR 0000004 5309 #define PARMRK 0000010 5310 #define INPCK 0000020 5311 #define ISTRIP 0000040 5312 #define INLCR 0000100 5313 #define IGNCR 0000200 5314 #define ICRNL 0000400 5315 #define IXANY 0004000 5316 #define IMAXBEL 0020000 5317 5318 #define CS5 0000000 5319 5320 #define ECHO 0000010 5321 5322 #define B0 0000000 5323 #define B50 0000001 5324 #define B75 0000002 5325 #define B110 0000003 5326 #define B134 0000004 5327 #define B150 0000005 5328 #define B200 0000006 5329 #define B300 0000007 5330 #define B600 0000010 5331 #define B1200 0000011 5332 #define B1800 0000012 5333 #define B2400 0000013 5334 #define B4800 0000014 5335 #define B9600 0000015 5336 #define B19200 0000016 5337 #define B38400 0000017 5338 5339 ------------------------------------------------------------------------------- 5340 5341 time.h 5342 5343 #define CLK_TCK ((clock_t)__sysconf(2)) 5344 #define CLOCK_REALTIME 0 5345 #define TIMER_ABSTIME 1 5346 #define CLOCKS_PER_SEC 1000000l 5347 5348 struct tm 5349 { 5350 int tm_sec; 5351 int tm_min; 5352 int tm_hour; 5353 int tm_mday; 5354 int tm_mon; 5355 int tm_year; 5356 int tm_wday; 5357 int tm_yday; 5358 int tm_isdst; 5359 long tm_gmtoff; 5360 char *tm_zone; 5361 } 5362 ; 5363 struct itimerspec 5364 { 5365 struct timespec it_interval; 5366 struct timespec it_value; 5367 } 5368 ; 5369 5370 ------------------------------------------------------------------------------- 5371 5372 ulimit.h 5373 5374 #define UL_GETFSIZE 1 5375 #define UL_SETFSIZE 2 5376 5377 ------------------------------------------------------------------------------- 5378 5379 unistd.h 5380 5381 #define SEEK_SET 0 5382 #define STDIN_FILENO 0 5383 #define SEEK_CUR 1 5384 #define STDOUT_FILENO 1 5385 #define SEEK_END 2 5386 #define STDERR_FILENO 2 5387 5388 typedef long long off64_t; 5389 #define F_OK 0 5390 #define X_OK 1 5391 #define W_OK 2 5392 #define R_OK 4 5393 5394 #define _POSIX_VDISABLE '\0' 5395 #define _POSIX_CHOWN_RESTRICTED 1 5396 #define _POSIX_JOB_CONTROL 1 5397 #define _POSIX_NO_TRUNC 1 5398 #define _POSIX_SHELL 1 5399 #define _POSIX_FSYNC 200112 5400 #define _POSIX_MAPPED_FILES 200112 5401 #define _POSIX_MEMLOCK 200112 5402 #define _POSIX_MEMLOCK_RANGE 200112 5403 #define _POSIX_MEMORY_PROTECTION 200112 5404 #define _POSIX_SEMAPHORES 200112 5405 #define _POSIX_SHARED_MEMORY_OBJECTS 200112 5406 #define _POSIX_TIMERS 200112 5407 #define _POSIX2_C_BIND 200112L 5408 #define _POSIX2_VERSION 200112L 5409 #define _POSIX_THREADS 200112L 5410 #define _POSIX_VERSION 200112L 5411 5412 #define _PC_LINK_MAX 0 5413 #define _PC_MAX_CANON 1 5414 #define _PC_ASYNC_IO 10 5415 #define _PC_PRIO_IO 11 5416 #define _PC_FILESIZEBITS 13 5417 #define _PC_REC_INCR_XFER_SIZE 14 5418 #define _PC_REC_MIN_XFER_SIZE 16 5419 #define _PC_REC_XFER_ALIGN 17 5420 #define _PC_ALLOC_SIZE_MIN 18 5421 #define _PC_MAX_INPUT 2 5422 #define _PC_2_SYMLINKS 20 5423 #define _PC_NAME_MAX 3 5424 #define _PC_PATH_MAX 4 5425 #define _PC_PIPE_BUF 5 5426 #define _PC_CHOWN_RESTRICTED 6 5427 #define _PC_NO_TRUNC 7 5428 #define _PC_VDISABLE 8 5429 #define _PC_SYNC_IO 9 5430 5431 #define _SC_ARG_MAX 0 5432 #define _SC_CHILD_MAX 1 5433 #define _SC_PRIORITY_SCHEDULING 10 5434 #define _SC_TIMERS 11 5435 #define _SC_ASYNCHRONOUS_IO 12 5436 #define _SC_XBS5_ILP32_OFF32 125 5437 #define _SC_XBS5_ILP32_OFFBIG 126 5438 #define _SC_XBS5_LP64_OFF64 127 5439 #define _SC_XBS5_LPBIG_OFFBIG 128 5440 #define _SC_XOPEN_LEGACY 129 5441 #define _SC_PRIORITIZED_IO 13 5442 #define _SC_XOPEN_REALTIME 130 5443 #define _SC_XOPEN_REALTIME_THREADS 131 5444 #define _SC_ADVISORY_INFO 132 5445 #define _SC_BARRIERS 133 5446 #define _SC_CLOCK_SELECTION 137 5447 #define _SC_CPUTIME 138 5448 #define _SC_THREAD_CPUTIME 139 5449 #define _SC_SYNCHRONIZED_IO 14 5450 #define _SC_MONOTONIC_CLOCK 149 5451 #define _SC_FSYNC 15 5452 #define _SC_READER_WRITER_LOCKS 153 5453 #define _SC_SPIN_LOCKS 154 5454 #define _SC_REGEXP 155 5455 #define _SC_SHELL 157 5456 #define _SC_SPAWN 159 5457 #define _SC_MAPPED_FILES 16 5458 #define _SC_SPORADIC_SERVER 160 5459 #define _SC_THREAD_SPORADIC_SERVER 161 5460 #define _SC_TIMEOUTS 164 5461 #define _SC_TYPED_MEMORY_OBJECTS 165 5462 #define _SC_2_PBS_ACCOUNTING 169 5463 #define _SC_MEMLOCK 17 5464 #define _SC_2_PBS_LOCATE 170 5465 #define _SC_2_PBS_MESSAGE 171 5466 #define _SC_2_PBS_TRACK 172 5467 #define _SC_SYMLOOP_MAX 173 5468 #define _SC_2_PBS_CHECKPOINT 175 5469 #define _SC_V6_ILP32_OFF32 176 5470 #define _SC_V6_ILP32_OFFBIG 177 5471 #define _SC_V6_LP64_OFF64 178 5472 #define _SC_V6_LPBIG_OFFBIG 179 5473 #define _SC_MEMLOCK_RANGE 18 5474 #define _SC_HOST_NAME_MAX 180 5475 #define _SC_TRACE 181 5476 #define _SC_TRACE_EVENT_FILTER 182 5477 #define _SC_TRACE_INHERIT 183 5478 #define _SC_TRACE_LOG 184 5479 #define _SC_MEMORY_PROTECTION 19 5480 #define _SC_CLK_TCK 2 5481 #define _SC_MESSAGE_PASSING 20 5482 #define _SC_SEMAPHORES 21 5483 #define _SC_SHARED_MEMORY_OBJECTS 22 5484 #define _SC_AIO_LISTIO_MAX 23 5485 #define _SC_AIO_MAX 24 5486 #define _SC_AIO_PRIO_DELTA_MAX 25 5487 #define _SC_DELAYTIMER_MAX 26 5488 #define _SC_MQ_OPEN_MAX 27 5489 #define _SC_MQ_PRIO_MAX 28 5490 #define _SC_VERSION 29 5491 #define _SC_NGROUPS_MAX 3 5492 #define _SC_PAGESIZE 30 5493 #define _SC_PAGE_SIZE 30 5494 #define _SC_RTSIG_MAX 31 5495 #define _SC_SEM_NSEMS_MAX 32 5496 #define _SC_SEM_VALUE_MAX 33 5497 #define _SC_SIGQUEUE_MAX 34 5498 #define _SC_TIMER_MAX 35 5499 #define _SC_BC_BASE_MAX 36 5500 #define _SC_BC_DIM_MAX 37 5501 #define _SC_BC_SCALE_MAX 38 5502 #define _SC_BC_STRING_MAX 39 5503 #define _SC_OPEN_MAX 4 5504 #define _SC_COLL_WEIGHTS_MAX 40 5505 #define _SC_EXPR_NEST_MAX 42 5506 #define _SC_LINE_MAX 43 5507 #define _SC_RE_DUP_MAX 44 5508 #define _SC_2_VERSION 46 5509 #define _SC_2_C_BIND 47 5510 #define _SC_2_C_DEV 48 5511 #define _SC_2_FORT_DEV 49 5512 #define _SC_STREAM_MAX 5 5513 #define _SC_2_FORT_RUN 50 5514 #define _SC_2_SW_DEV 51 5515 #define _SC_2_LOCALEDEF 52 5516 #define _SC_TZNAME_MAX 6 5517 #define _SC_IOV_MAX 60 5518 #define _SC_THREADS 67 5519 #define _SC_THREAD_SAFE_FUNCTIONS 68 5520 #define _SC_GETGR_R_SIZE_MAX 69 5521 #define _SC_JOB_CONTROL 7 5522 #define _SC_GETPW_R_SIZE_MAX 70 5523 #define _SC_LOGIN_NAME_MAX 71 5524 #define _SC_TTY_NAME_MAX 72 5525 #define _SC_THREAD_DESTRUCTOR_ITERATIONS 73 5526 #define _SC_THREAD_KEYS_MAX 74 5527 #define _SC_THREAD_STACK_MIN 75 5528 #define _SC_THREAD_THREADS_MAX 76 5529 #define _SC_THREAD_ATTR_STACKADDR 77 5530 #define _SC_THREAD_ATTR_STACKSIZE 78 5531 #define _SC_THREAD_PRIORITY_SCHEDULING 79 5532 #define _SC_SAVED_IDS 8 5533 #define _SC_THREAD_PRIO_INHERIT 80 5534 #define _SC_THREAD_PRIO_PROTECT 81 5535 #define _SC_THREAD_PROCESS_SHARED 82 5536 #define _SC_ATEXIT_MAX 87 5537 #define _SC_PASS_MAX 88 5538 #define _SC_XOPEN_VERSION 89 5539 #define _SC_REALTIME_SIGNALS 9 5540 #define _SC_XOPEN_UNIX 91 5541 #define _SC_XOPEN_CRYPT 92 5542 #define _SC_XOPEN_ENH_I18N 93 5543 #define _SC_XOPEN_SHM 94 5544 #define _SC_2_CHAR_TERM 95 5545 #define _SC_2_C_VERSION 96 5546 #define _SC_2_UPE 97 5547 5548 #define _CS_PATH 0 5549 #define _POSIX_REGEXP 1 5550 #define _CS_XBS5_ILP32_OFF32_CFLAGS 1100 5551 #define _CS_XBS5_ILP32_OFF32_LDFLAGS 1101 5552 #define _CS_XBS5_ILP32_OFF32_LIBS 1102 5553 #define _CS_XBS5_ILP32_OFF32_LINTFLAGS 1103 5554 #define _CS_XBS5_ILP32_OFFBIG_CFLAGS 1104 5555 #define _CS_XBS5_ILP32_OFFBIG_LDFLAGS 1105 5556 #define _CS_XBS5_ILP32_OFFBIG_LIBS 1106 5557 #define _CS_XBS5_ILP32_OFFBIG_LINTFLAGS 1107 5558 #define _CS_XBS5_LP64_OFF64_CFLAGS 1108 5559 #define _CS_XBS5_LP64_OFF64_LDFLAGS 1109 5560 #define _CS_XBS5_LP64_OFF64_LIBS 1110 5561 #define _CS_XBS5_LP64_OFF64_LINTFLAGS 1111 5562 #define _CS_XBS5_LPBIG_OFFBIG_CFLAGS 1112 5563 #define _CS_XBS5_LPBIG_OFFBIG_LDFLAGS 1113 5564 #define _CS_XBS5_LPBIG_OFFBIG_LIBS 1114 5565 #define _CS_XBS5_LPBIG_OFFBIG_LINTFLAGS 1115 5566 5567 #define _XOPEN_REALTIME 1 5568 #define _XOPEN_XPG4 1 5569 #define _XOPEN_XCU_VERSION 4 5570 #define _XOPEN_VERSION 500 5571 5572 #define F_ULOCK 0 5573 #define F_LOCK 1 5574 #define F_TLOCK 2 5575 #define F_TEST 3 5576 5577 ------------------------------------------------------------------------------- 5578 5579 utime.h 5580 5581 struct utimbuf 5582 { 5583 time_t actime; 5584 time_t modtime; 5585 } 5586 ; 5587 5588 ------------------------------------------------------------------------------- 5589 5590 utmp.h 5591 5592 #define UT_HOSTSIZE 256 5593 #define UT_LINESIZE 32 5594 #define UT_NAMESIZE 32 5595 5596 struct exit_status 5597 { 5598 short e_termination; 5599 short e_exit; 5600 } 5601 ; 5602 5603 #define EMPTY 0 5604 #define RUN_LVL 1 5605 #define BOOT_TIME 2 5606 #define NEW_TIME 3 5607 #define OLD_TIME 4 5608 #define INIT_PROCESS 5 5609 #define LOGIN_PROCESS 6 5610 #define USER_PROCESS 7 5611 #define DEAD_PROCESS 8 5612 #define ACCOUNTING 9 5613 5614 ------------------------------------------------------------------------------- 5615 5616 wchar.h 5617 5618 #define WEOF (0xffffffffu) 5619 #define WCHAR_MAX 0x7FFFFFFF 5620 #define WCHAR_MIN 0x80000000 5621 5622 ------------------------------------------------------------------------------- 5623 5624 wctype.h 5625 5626 typedef unsigned long wctype_t; 5627 typedef unsigned int wint_t; 5628 typedef const int32_t *wctrans_t; 5629 typedef struct 5630 { 5631 int count; 5632 wint_t value; 5633 } 5634 __mbstate_t; 5635 5636 typedef __mbstate_t mbstate_t; 5637 5638 ------------------------------------------------------------------------------- 5639 5640 wordexp.h 5641 5642 enum 5643 { 5644 WRDE_DOOFFS, WRDE_APPEND, WRDE_NOCMD, WRDE_REUSE, WRDE_SHOWERR, WRDE_UNDEF, 5645 __WRDE_FLAGS 5646 } 5647 ; 5648 5649 typedef struct 5650 { 5651 int we_wordc; 5652 char **we_wordv; 5653 int we_offs; 5654 } 5655 wordexp_t; 5656 5657 enum 5658 { 5659 WRDE_NOSYS, WRDE_NOSPACE, WRDE_BADCHAR, WRDE_BADVAL, WRDE_CMDSUB, 5660 WRDE_SYNTAX 5661 } 5662 ; 5663 5664 ------------------------------------------------------------------------------- 5665 5666 Interface Definitions for libc 5667 5668 Table of Contents 5669 _IO_feof -- alias for feof 5670 _IO_getc -- alias for getc 5671 _IO_putc -- alias for putc 5672 _IO_puts -- alias for puts 5673 __assert_fail -- abort the program after false assertion 5674 __ctype_b_loc -- accessor function for __ctype_b array for ctype functions 5675 __ctype_get_mb_cur_max -- maximum length of a multibyte character in the 5676 current locale 5677 __ctype_tolower_loc -- accessor function for __ctype_b_tolower array for ctype 5678 tolower() function 5679 __ctype_toupper_loc -- accessor function for __ctype_b_toupper array for ctype 5680 toupper() function 5681 __cxa_atexit -- register a function to be called by exit or when a shared 5682 library is unloaded 5683 __daylight -- Daylight savings time flag 5684 __environ -- alias for environ - user environment 5685 __errno_location -- address of errno variable 5686 __fpending -- returns in bytes the amount of output pending on a stream 5687 __getpagesize -- alias for getpagesize - get current page size 5688 __getpgid -- get the process group id 5689 __h_errno_location -- address of h_errno variable 5690 __isinf -- test for infinity 5691 __isinff -- test for infinity 5692 __isinfl -- test for infinity 5693 __isnan -- test for infinity 5694 __isnanf -- test for infinity 5695 __isnanl -- test for infinity 5696 __libc_current_sigrtmax -- return number of available real-time signal with 5697 lowest priority 5698 __libc_current_sigrtmin -- return number of available real-time signal with 5699 highest priority 5700 __libc_start_main -- initialization routine 5701 __lxstat -- inline wrapper around call to lxstat 5702 __mempcpy -- copy given number of bytes of source to destination 5703 __rawmemchr -- scan memory 5704 __register_atfork -- alias for register_atfork 5705 __sigsetjmp -- save stack context for non-local goto 5706 __stpcpy -- copy a string returning a pointer to its end 5707 __strdup -- alias for strdup 5708 __strtod_internal -- underlying function for strtod 5709 __strtof_internal -- underlying function for strtof 5710 __strtok_r -- alias for strtok_r 5711 __strtol_internal -- alias for strtol 5712 __strtold_internal -- underlying function for strtold 5713 __strtoll_internal -- underlying function for strtoll 5714 __strtoul_internal -- underlying function for strtoul 5715 __strtoull_internal -- underlying function for strtoull 5716 __sysconf -- get configuration information at runtime 5717 __sysv_signal -- signal handling 5718 __timezone -- global variable containing timezone 5719 __tzname -- global variable containing the timezone 5720 __wcstod_internal -- underlying function for wcstod 5721 __wcstof_internal -- underlying function for wcstof 5722 __wcstol_internal -- underlying function for wcstol 5723 __wcstold_internal -- underlying function for wcstold 5724 __wcstoul_internal -- underlying function for wcstoul 5725 __xmknod -- make block or character special file 5726 __xstat -- Get File Status 5727 __xstat64 -- Get File Status 5728 _environ -- alias for environ - user environment 5729 _nl_msg_cat_cntr -- new catalog load counter 5730 _obstack_begin -- initialize an obstack for use 5731 _obstack_newchunk -- allocate a new current chunk of memory for the obstack 5732 _sys_errlist -- array containing the "C" locale strings used by strerror() 5733 _sys_siglist -- array containing the names of the signal names 5734 acct -- switch process accounting on or off 5735 adjtime -- correct the time to allow synchronization of the system clock 5736 adjtimex -- tune kernel clock (DEPRECATED) 5737 asprintf -- write formatted output to a dynamically allocated string 5738 bind_textdomain_codeset -- specify encoding for message retrieval 5739 bindresvport -- bind socket to privileged IP port 5740 bindtextdomain -- specify the location of a message catalog 5741 cfmakeraw -- get and set terminal attributes 5742 cfsetspeed -- set terminal input and output data rate 5743 creat -- open a file 5744 daemon -- run in the background 5745 dcgettext -- perform domain and category specific lookup in message catalog 5746 dcngettext -- perform domain and category specific lookup in message catalog 5747 with plural 5748 dgettext -- perform lookup in message catalog for the current LC_MESSAGES 5749 locale 5750 dngettext -- perform lookup in message catalog for the current locale 5751 err -- display formatted error messages 5752 error -- print error message 5753 errx -- display formatted error message and exit 5754 fcntl -- file control 5755 fflush_unlocked -- non thread safe fflush 5756 fgetwc_unlocked -- non thread safe fgetwc 5757 flock -- apply or remove an advisory lock on an open file 5758 fopen -- open a file 5759 freopen -- open a file 5760 getdomainname -- get NIS domain name (DEPRECATED). 5761 gethostbyname_r -- find network host database entry matching host name 5762 (DEPRECATED) 5763 getloadavg -- get system load averages 5764 getopt -- parse command line options 5765 getopt_long -- parse command line options 5766 getopt_long_only -- parse command line options 5767 gettext -- Search message catalogs for a string 5768 getutent -- access user accounting database entries 5769 getutent_r -- access user accounting database entries 5770 glob64 -- find pathnames matching a pattern (Large File Support) 5771 globfree64 -- free memory from glob64() (Large File Support) 5772 initgroups -- initialize the supplementary group access list 5773 ioctl -- control device 5774 sockio -- socket ioctl commands 5775 kill -- send a signal 5776 mbsnrtowcs -- convert a multibyte string to a wide character string 5777 memmem -- locate bytes 5778 memrchr -- scan memory for a character 5779 ngettext -- Search message catalogs for plural string 5780 obstack_free -- free an object in the obstack 5781 open -- open a file 5782 opterr -- external variable used in getopt() 5783 optind -- external variable used in getopt() 5784 optopt -- external variable used in getopt() 5785 pmap_getport -- Find the port number assigned to a service registered with a 5786 portmapper. 5787 pmap_set -- Establishes mapping to machine's RPC Bind service. 5788 pmap_unset -- Destroys RPC Binding 5789 psignal -- print signal message 5790 random_r -- generate random number 5791 setbuffer -- stream buffering operation 5792 setdomainname -- set NIS domain name (DEPRECATED). 5793 setgroups -- set list of supplementary group IDs 5794 sethostid -- set the unique identifier of the current host 5795 sethostname -- set host name 5796 setsockopt -- set options on sockets 5797 setutent -- access user accounting database entries 5798 sigandset -- build a new signal set by combining the two input sets using 5799 logical AND 5800 sigblock -- manipulate the signal mask 5801 siggetmask -- manipulate the signal mask 5802 sigisemptyset -- check for empty signal set 5803 sigorset -- build a new signal set by combining the two input sets using 5804 logical OR 5805 sigreturn -- return from signal handler and cleanup stack frame 5806 stime -- set time 5807 stpcpy -- copy a string returning a pointer to its end 5808 stpncpy -- copy a fixed-size string, returning a pointer to its end 5809 strcasestr -- locate a substring ignoring case 5810 strerror_r -- reentrant version of strerror 5811 strfry -- randomize a string 5812 strndup -- return a malloc'd copy of at most the specified number of bytes of a 5813 string 5814 strnlen -- determine the length of a fixed-size string 5815 strptime -- parse a time string 5816 strsep -- extract token from string 5817 strsignal -- return string describing signal 5818 strtoq -- convert string value to a long or quad_t integer 5819 strtouq -- convert a string to an uquad_t 5820 strverscmp -- compare strings holding name and indices/version numbers 5821 svc_register -- Register Remote Procedure Call Interface 5822 svc_run -- Waits for RPC requests to arrive and calls service procedure. 5823 svc_sendreply -- called by RPC service's dispatch routine 5824 svctcp_create -- Creates a TCP/IP-based RPC service transport. 5825 svcudp_create -- Creates a UDP-based RPC service transport. 5826 system -- execute a shell command 5827 textdomain -- set the current default message domain 5828 unlink -- remove a directory entry 5829 vasprintf -- write formatted output to a dynamically allocated string 5830 vdprintf -- write formatted output to a file descriptor 5831 verrx -- display formatted error message and exit 5832 vsyslog -- log to system log 5833 wait3 -- wait for child process 5834 wait4 -- wait for process termination, BSD style 5835 waitpid -- wait for child process 5836 warn -- formatted error messages 5837 warnx -- formatted error messages 5838 wcpcpy -- copy a wide character string, returning a pointer to its end 5839 wcpncpy -- copy a fixed-size string of wide characters, returning a pointer to 5840 its end 5841 wcscasecmp -- compare two wide-character strings, ignoring case 5842 wcsdup -- duplicate a wide-character string 5843 wcsncasecmp -- compare two fixed-size wide-character strings, ignoring case 5844 wcsnlen -- determine the length of a fixed-size wide-character string 5845 wcsnrtombs -- convert a wide character string to a multi-byte string 5846 wcstoq -- convert wide string to long long int representation 5847 wcstouq -- convert wide string to unsigned long long int representation 5848 xdr_u_int -- library routines for external data representation 5849 5850 The following interfaces are included in libc and are defined by this 5851 specification. Unless otherwise noted, these interfaces shall be included in 5852 the source standard. 5853 5854 Other interfaces listed above for libc shall behave as described in the 5855 referenced base document. 5856 5857 _IO_feof 5858 5859 Name 5860 5861 _IO_feof -- alias for feof 5862 5863 Synopsis 5864 5865 int _IO_feof(_IO_FILE *__fp); 5866 5867 Description 5868 5869 _IO_feof tests the end-of-file indicator for the stream pointed to by __fp, 5870 returning a non-zero value if it is set. 5871 5872 _IO_feof is not in the source standard; it is only in the binary standard. 5873 5874 _IO_getc 5875 5876 Name 5877 5878 _IO_getc -- alias for getc 5879 5880 Synopsis 5881 5882 int _IO_getc(_IO_FILE *__fp); 5883 5884 Description 5885 5886 _IO_getc reads the next character from __fp and returns it as an unsigned char 5887 cast to an int, or EOF on end-of-file or error. 5888 5889 _IO_getc is not in the source standard; it is only in the binary standard. 5890 5891 _IO_putc 5892 5893 Name 5894 5895 _IO_putc -- alias for putc 5896 5897 Synopsis 5898 5899 int _IO_putc(int __c, _IO_FILE *__fp); 5900 5901 Description 5902 5903 _IO_putc writes the character __c, cast to an unsigned char, to __fp. 5904 5905 _IO_putc is not in the source standard; it is only in the binary standard. 5906 5907 _IO_puts 5908 5909 Name 5910 5911 _IO_puts -- alias for puts 5912 5913 Synopsis 5914 5915 int _IO_puts(const char *__c); 5916 5917 Description 5918 5919 _IO_puts writes the string __s and a trailing newline to stdout. 5920 5921 _IO_puts is not in the source standard; it is only in the binary standard. 5922 5923 __assert_fail 5924 5925 Name 5926 5927 __assert_fail -- abort the program after false assertion 5928 5929 Synopsis 5930 5931 void __assert_fail(const char *assertion, const char *file, unsigned int line, 5932 const char *function); 5933 5934 Description 5935 5936 The __assert_fail function is used to implement the assert interface of ISO 5937 POSIX (2003). The __assert_fail function shall print the given file filename, 5938 line line number, function function name and a message on the standard error 5939 stream in an unspecified format, and abort program execution via the abort 5940 function. For example: 5941 5942 5943 a.c:10: foobar: Assertion a == b failed. 5944 5945 If function is NULL, __assert_fail shall omit information about the function. 5946 5947 assertion, file, and line shall be non-NULL. 5948 5949 The __assert_fail function is not in the source standard; it is only in the 5950 binary standard. The assert interface is not in the binary standard; it is only 5951 in the source standard. The assert may be implemented as a macro. 5952 5953 __ctype_b_loc 5954 5955 Name 5956 5957 __ctype_b_loc -- accessor function for __ctype_b array for ctype functions 5958 5959 Synopsis 5960 5961 #include 5962 5963 const unsigned short int **ctype_b_loc (void); 5964 5965 Description 5966 5967 The __ctype_b_loc function shall return a pointer into an array of characters 5968 in the current locale that contains characteristics for each character in the 5969 current character set. The array shall contain a total of 384 characters, and 5970 can be indexed with any signed or unsigned char (i.e. with an index value 5971 between -128 and 255). If the application is multithreaded, the array shall be 5972 local to the current thread. 5973 5974 This interface is not in the source standard; it is only in the binary 5975 standard. 5976 5977 Return Value 5978 5979 The __ctype_b_loc function shall return a pointer to the array of characters to 5980 be used for the ctype family of functions (see ). 5981 5982 __ctype_get_mb_cur_max 5983 5984 Name 5985 5986 __ctype_get_mb_cur_max -- maximum length of a multibyte character in the 5987 current locale 5988 5989 Synopsis 5990 5991 size_t __ctype_get_mb_cur_max(void); 5992 5993 Description 5994 5995 __ctype_get_mb_cur_max returns the maximum length of a multibyte character in 5996 the current locale. 5997 5998 __ctype_get_mb_cur_max is not in the source standard; it is only in the binary 5999 standard. 6000 6001 __ctype_tolower_loc 6002 6003 Name 6004 6005 __ctype_tolower_loc -- accessor function for __ctype_b_tolower array for ctype 6006 tolower() function 6007 6008 Synopsis 6009 6010 #include 6011 6012 int32_t **__ctype_tolower_loc(void); 6013 6014 Description 6015 6016 The __ctype_tolower_loc function shall return a pointer into an array 6017 characters in the current locale that contains lower case equivalents for each 6018 character in the current character set. The array shall contain a total of 384 6019 characters, and can be indexed with any signed or unsigned char (i.e. with an 6020 index value between -128 and 255). If the application is multithreaded, the 6021 array shall be local to the current thread. 6022 6023 This interface is not in the source standard; it is only in the binary 6024 standard. 6025 6026 __ctype_toupper_loc 6027 6028 Name 6029 6030 __ctype_toupper_loc -- accessor function for __ctype_b_toupper array for ctype 6031 toupper() function 6032 6033 Synopsis 6034 6035 #include 6036 6037 int32_t **__ctype_toupper_loc(void); 6038 6039 Description 6040 6041 The __ctype_toupper_loc function shall return a pointer into an array 6042 characters in the current locale that contains upper case equivalents for each 6043 character in the current character set. The array shall contain a total of 384 6044 characters, and can be indexed with any signed or unsigned char (i.e. with an 6045 index value between -128 and 255). If the application is multithreaded, the 6046 array shall be local to the current thread. 6047 6048 This interface is not in the source standard; it is only in the binary 6049 standard. 6050 6051 __cxa_atexit 6052 6053 Name 6054 6055 __cxa_atexit -- register a function to be called by exit or when a shared 6056 library is unloaded 6057 6058 Synopsis 6059 6060 int __cxa_atexit(void (*func) (void *), void *arg, void *dso_handle); 6061 6062 Description 6063 6064 __cxa_atexit registers a function to be called by exit or when a shared library 6065 is unloaded. 6066 6067 The __cxa_atexit function is used to implement atexit, as described in ISO 6068 POSIX (2003). Calling 6069 6070 atexit(func) 6071 6072 from the statically linked part of an application shall be equivalent to 6073 6074 __cxa_atexit(func, NULL, NULL) 6075 6076 . 6077 6078 __cxa_atexit is not in the source standard; it is only in the binary standard. 6079 atexit is not in the binary standard; it is only in the source standard. 6080 6081 __daylight 6082 6083 Name 6084 6085 __daylight -- Daylight savings time flag 6086 6087 Synopsis 6088 6089 int __daylight; 6090 6091 Description 6092 6093 The integer variable __daylight shall implement the daylight savings time flag 6094 daylight as specified in the ISO POSIX (2003) header file . 6095 6096 __daylight is not in the source standard; it is only in the binary standard. 6097 daylight is not in the binary standard; it is only in the source standard. 6098 6099 __environ 6100 6101 Name 6102 6103 __environ -- alias for environ - user environment 6104 6105 Synopsis 6106 6107 extern char **__environ; 6108 6109 Description 6110 6111 __environ is an alias for environ - user environment. 6112 6113 __environ has the same specification as environ. 6114 6115 __environ is not in the source standard; it is only in the binary standard. 6116 6117 __errno_location 6118 6119 Name 6120 6121 __errno_location -- address of errno variable 6122 6123 Synopsis 6124 6125 int *__errno_location(void); 6126 6127 Description 6128 6129 __errno_location is not in the source standard; it is only in the binary 6130 standard. 6131 6132 __fpending 6133 6134 Name 6135 6136 __fpending -- returns in bytes the amount of output pending on a stream 6137 6138 Synopsis 6139 6140 #include 6141 6142 size_t __fpending(FILE *stream); 6143 6144 Description 6145 6146 __fpending returns the amount of output in bytes pending on a stream. 6147 6148 __fpending is not in the source standard; it is only in the binary standard. 6149 6150 __getpagesize 6151 6152 Name 6153 6154 __getpagesize -- alias for getpagesize - get current page size 6155 6156 Synopsis 6157 6158 int __getpagesize(void); 6159 6160 Description 6161 6162 __getpagesize is an alias for getpagesize - get current page size. 6163 6164 __getpagesize has the same specification as getpagesize. 6165 6166 __getpagesize is not in the source standard; it is only in the binary standard. 6167 6168 __getpgid 6169 6170 Name 6171 6172 __getpgid -- get the process group id 6173 6174 Synopsis 6175 6176 pid_t __getpgid(pid_t pid); 6177 6178 Description 6179 6180 __getpgid has the same specification as getpgid. 6181 6182 __getpgid is not in the source standard; it is only in the binary standard. 6183 6184 __h_errno_location 6185 6186 Name 6187 6188 __h_errno_location -- address of h_errno variable 6189 6190 Synopsis 6191 6192 int *__h_errno_location(void); 6193 6194 Description 6195 6196 __h_errno_location returns the address of the h_errno variable, where h_errno 6197 is as specified in the Single Unix Specification. 6198 6199 __h_errno_location is not in the source standard; it is only in the binary 6200 standard. Note that h_errno itself is only in the source standard; it is not in 6201 the binary standard. 6202 6203 __isinf 6204 6205 Name 6206 6207 __isinf -- test for infinity 6208 6209 Synopsis 6210 6211 int __isinf(double arg); 6212 6213 Description 6214 6215 __isinf has the same specification as isinf in the Single UNIX Specification, 6216 Version 3, except that the argument type for __isinf is known to be double. 6217 6218 __isinf is not in the source standard; it is only in the binary standard. 6219 6220 __isinff 6221 6222 Name 6223 6224 __isinff -- test for infinity 6225 6226 Synopsis 6227 6228 int __isinff(float arg); 6229 6230 Description 6231 6232 __isinff has the same specification as isinf in the Single UNIX Specification, 6233 Version 3, except that the argument type for __isinff is known to be float. 6234 6235 __isinff is not in the source standard; it is only in the binary standard. 6236 6237 __isinfl 6238 6239 Name 6240 6241 __isinfl -- test for infinity 6242 6243 Synopsis 6244 6245 int __isinfl(long double arg); 6246 6247 Description 6248 6249 __isinfl has the same specification as isinf in the Single UNIX Specification, 6250 Version 3, except that the argument type for __isinfl is known to be long 6251 double. 6252 6253 __isinfl is not in the source standard; it is only in the binary standard. 6254 6255 __isnan 6256 6257 Name 6258 6259 __isnan -- test for infinity 6260 6261 Synopsis 6262 6263 int __isnan(double arg); 6264 6265 Description 6266 6267 __isnan has the same specification as isnan in the Single UNIX Specification, 6268 Version 3, except that the argument type for __isnan is known to be double. 6269 6270 __isnan is not in the source standard; it is only in the binary standard. 6271 6272 __isnanf 6273 6274 Name 6275 6276 __isnanf -- test for infinity 6277 6278 Synopsis 6279 6280 int __isnanf(float arg); 6281 6282 Description 6283 6284 __isnanf has the same specification as isnan in the Single UNIX Specification, 6285 Version 3, except that the argument type for __isnanf is known to be float. 6286 6287 __isnanf is not in the source standard; it is only in the binary standard. 6288 6289 __isnanl 6290 6291 Name 6292 6293 __isnanl -- test for infinity 6294 6295 Synopsis 6296 6297 int __isnanl(long double arg); 6298 6299 Description 6300 6301 __isnanl has the same specification as isnan in the Single UNIX Specification, 6302 Version 3, except that the argument type for __isnanl is known to be long 6303 double. 6304 6305 __isnanl is not in the source standard; it is only in the binary standard. 6306 6307 __libc_current_sigrtmax 6308 6309 Name 6310 6311 __libc_current_sigrtmax -- return number of available real-time signal with 6312 lowest priority 6313 6314 Synopsis 6315 6316 int __libc_current_sigrtmax(void); 6317 6318 Description 6319 6320 __libc_current_sigrtmax returns the number of an available real-time signal 6321 with the lowest priority. 6322 6323 __libc_current_sigrtmax is not in the source standard; it is only in the binary 6324 standard. 6325 6326 __libc_current_sigrtmin 6327 6328 Name 6329 6330 __libc_current_sigrtmin -- return number of available real-time signal with 6331 highest priority 6332 6333 Synopsis 6334 6335 int __libc_current_sigrtmin(void); 6336 6337 Description 6338 6339 __libc_current_sigrtmin returns the number of an available real-time signal 6340 with the highest priority. 6341 6342 __libc_current_sigrtmin is not in the source standard; it is only in the binary 6343 standard. 6344 6345 __libc_start_main 6346 6347 Name 6348 6349 __libc_start_main -- initialization routine 6350 6351 Synopsis 6352 6353 int __libc_start_main(int (*main) (int, char**, char**), int argc, char 6354 *__unbounded *__unbounded ubp_av, void (*init) (void), void (*fini) (void), 6355 void (*rtld_fini) (void), void (*__unbounded stack_end)); 6356 6357 Description 6358 6359 The __libc_start_main function shall initialize the process, call the main 6360 function with appropriate arguments, and handle the return from main. 6361 6362 __libc_start_main is not in the source standard; it is only in the binary 6363 standard. 6364 6365 __lxstat 6366 6367 Name 6368 6369 __lxstat -- inline wrapper around call to lxstat 6370 6371 Synopsis 6372 6373 #include 6374 6375 int __lxstat(int version, char *__path, (struct stat *__statbuf)); 6376 6377 Description 6378 6379 __lxstat is an inline wrapper around call to lxstat. 6380 6381 __lxstat is not in the source standard; it is only in the binary standard. 6382 6383 __mempcpy 6384 6385 Name 6386 6387 __mempcpy -- copy given number of bytes of source to destination 6388 6389 Synopsis 6390 6391 #include 6392 6393 ptr_t __mempcpy(ptr_t restrict dest, const ptr_t restrict src, size_t n); 6394 6395 Description 6396 6397 __mempcpy copies n bytes of source to destination, returning pointer to bytes 6398 after the last written byte. 6399 6400 __mempcpy is not in the source standard; it is only in the binary standard. 6401 6402 __rawmemchr 6403 6404 Name 6405 6406 __rawmemchr -- scan memory 6407 6408 Synopsis 6409 6410 #include 6411 6412 ptr_t __rawmemchr(const ptr_t s, int c); 6413 6414 Description 6415 6416 __rawmemchr searches in s for c. 6417 6418 __rawmemchr is a weak alias to rawmemchr. It is similar to memchr, but it has 6419 no length limit. 6420 6421 __rawmemchr is not in the source standard; it is only in the binary standard. 6422 6423 __register_atfork 6424 6425 Name 6426 6427 __register_atfork -- alias for register_atfork 6428 6429 Synopsis 6430 6431 int __register_atfork(void (*prepare)(), void (*parent)(), void (*child)(), 6432 void *__dso_handle); 6433 6434 Description 6435 6436 __register_atfork implements pthread_atfork as specified in ISO POSIX (2003). 6437 The additional parameter __dso_handle allows a shared object to pass in it's 6438 handle so that functions registered by __register_atfork can be unregistered by 6439 the runtime when the shared object is unloaded. 6440 6441 __sigsetjmp 6442 6443 Name 6444 6445 __sigsetjmp -- save stack context for non-local goto 6446 6447 Synopsis 6448 6449 int __sigsetjmp(jmp_buf env, int savemask); 6450 6451 Description 6452 6453 __sigsetjmp has the same behavior as sigsetjmp as specified by ISO POSIX (2003) 6454 . 6455 6456 __sigsetjmp is not in the source standard; it is only in the binary standard. 6457 6458 __stpcpy 6459 6460 Name 6461 6462 __stpcpy -- copy a string returning a pointer to its end 6463 6464 Synopsis 6465 6466 #include 6467 6468 char *__stpcpy(char *dest, const char *src); 6469 6470 Description 6471 6472 __stpcpy copies the string src (including the terminating /0 character) to the 6473 array dest. The strings may not overlap, and dest must be large enough to 6474 receive the copy. 6475 6476 Return Value 6477 6478 __stpcpy returns a pointer to the end of the string dest (that is, the address 6479 of the terminating NULL character) rather than the beginning. 6480 6481 __stpcpy has the same specification as stpcpy. 6482 6483 __stpcpy is not in the source standard; it is only in the binary standard. 6484 6485 __strdup 6486 6487 Name 6488 6489 __strdup -- alias for strdup 6490 6491 Synopsis 6492 6493 char *__strdup(const char string); 6494 6495 Description 6496 6497 __strdup has the same specification as strdup. 6498 6499 __strdup is not in the source standard; it is only in the binary standard. 6500 6501 __strtod_internal 6502 6503 Name 6504 6505 __strtod_internal -- underlying function for strtod 6506 6507 Synopsis 6508 6509 double __strtod_internal(const char *__nptr, char **__endptr, int __group); 6510 6511 Description 6512 6513 __group shall be 0 or the behavior of __strtod_internal is undefined. 6514 6515 __strtod_internal(__nptr, __endptr, 0) has the same specification as strtod 6516 (__nptr, __endptr). 6517 6518 __strtod_internal is not in the source standard; it is only in the binary 6519 standard. 6520 6521 __strtof_internal 6522 6523 Name 6524 6525 __strtof_internal -- underlying function for strtof 6526 6527 Synopsis 6528 6529 float __strtof_internal(const char *__nptr, char **__endptr, int __group); 6530 6531 Description 6532 6533 __group shall be 0 or the behavior of __strtof_internal is undefined. 6534 6535 __strtof_internal(__nptr, __endptr, 0) has the same specification as strtof 6536 (__nptr, __endptr). 6537 6538 __strtof_internal is not in the source standard; it is only in the binary 6539 standard. 6540 6541 __strtok_r 6542 6543 Name 6544 6545 __strtok_r -- alias for strtok_r 6546 6547 Synopsis 6548 6549 char *__strtok_r(char *__restrict s, __const char *__restrict delim, char 6550 **__restrict save_ptr); 6551 6552 Description 6553 6554 __strtok_r has the same specification as strtok_r. 6555 6556 __strtok_r is not in the source standard; it is only in the binary standard. 6557 6558 __strtol_internal 6559 6560 Name 6561 6562 __strtol_internal -- alias for strtol 6563 6564 Synopsis 6565 6566 long int __strtol_internal(const char *__nptr, char **__endptr, int __base, int 6567 __group); 6568 6569 Description 6570 6571 __group shall be 0 or the behavior of __strtol_internal is undefined. 6572 6573 __strtol_internal(__nptr, __endptr, __base, 0) has the same specification as 6574 strtol(__nptr, __endptr, __base). 6575 6576 __strtol_internal is not in the source standard; it is only in the binary 6577 standard. 6578 6579 __strtold_internal 6580 6581 Name 6582 6583 __strtold_internal -- underlying function for strtold 6584 6585 Synopsis 6586 6587 long double __strtold_internal(const char *__nptr, char **__endptr, int 6588 __group); 6589 6590 Description 6591 6592 __group shall be 0 or the behavior of __strtold_internal is undefined. 6593 6594 __strtold_internal(__nptr, __endptr, 0) has the same specification as strtold 6595 (__nptr, __endptr). 6596 6597 __strtold_internal is not in the source standard; it is only in the binary 6598 standard. 6599 6600 __strtoll_internal 6601 6602 Name 6603 6604 __strtoll_internal -- underlying function for strtoll 6605 6606 Synopsis 6607 6608 long long __strtoll_internal(const char *__nptr, char **__endptr, int __base, 6609 int __group); 6610 6611 Description 6612 6613 __group shall be 0 or the behavior of __strtoll_internal is undefined. 6614 6615 __strtoll_internal(__nptr, __endptr, __base, 0) has the same specification as 6616 strtoll(__nptr, __endptr, __base). 6617 6618 __strtoll_internal is not in the source standard; it is only in the binary 6619 standard. 6620 6621 __strtoul_internal 6622 6623 Name 6624 6625 __strtoul_internal -- underlying function for strtoul 6626 6627 Synopsis 6628 6629 unsigned long int __strtoul_internal(const char *__nptr, char **__endptr, int 6630 __base, int __group); 6631 6632 Description 6633 6634 __group shall be 0 or the behavior of __strtoul_internal is undefined. 6635 6636 __strtoul_internal(__nptr, __endptr, __base, 0) has the same specification as 6637 strtoul(__nptr, __endptr, __base). 6638 6639 __strtoul_internal is not in the source standard; it is only in the binary 6640 standard. 6641 6642 __strtoull_internal 6643 6644 Name 6645 6646 __strtoull_internal -- underlying function for strtoull 6647 6648 Synopsis 6649 6650 unsigned long long __strtoull_internal(const char *__nptr, char **__endptr, int 6651 __base, int __group); 6652 6653 Description 6654 6655 __group shall be 0 or the behavior of __strtoull_internal is undefined. 6656 6657 __strtoull_internal(__nptr, __endptr, __base, 0) has the same specification as 6658 strtoull(__nptr, __endptr, __base). 6659 6660 __strtoull_internal is not in the source standard; it is only in the binary 6661 standard. 6662 6663 __sysconf 6664 6665 Name 6666 6667 __sysconf -- get configuration information at runtime 6668 6669 Synopsis 6670 6671 #include 6672 6673 long __sysconf(int name); 6674 6675 Description 6676 6677 __sysconf gets configuration information at runtime. 6678 6679 __sysconf is weak alias to sysconf. 6680 6681 __sysconf has the same specification as sysconf. 6682 6683 __sysconf is not in the source standard; it is only in the binary standard. 6684 6685 __sysv_signal 6686 6687 Name 6688 6689 __sysv_signal -- signal handling 6690 6691 Synopsis 6692 6693 __sighandler_t __sysv_signal(int sig, __sighandler_t handler); 6694 6695 Description 6696 6697 __sysv_signal has the same behavior as signal as specified by ISO POSIX (2003). 6698 6699 __sysv_signal is not in the source standard; it is only in the binary standard. 6700 6701 __timezone 6702 6703 Name 6704 6705 -- global variable containing timezone 6706 6707 Synopsis 6708 6709 long int __timezone; 6710 6711 Description 6712 6713 __timezone has the same specification as timezone in the ISO POSIX (2003) 6714 6715 __tzname 6716 6717 Name 6718 6719 -- global variable containing the timezone 6720 6721 Synopsis 6722 6723 char *__tzname[2]; 6724 6725 Description 6726 6727 __tzname has the same specification as tzname in the ISO POSIX (2003). 6728 6729 Note that the array size of 2 is explicit in the ISO POSIX (2003), but not in 6730 the SUSv2. 6731 6732 __wcstod_internal 6733 6734 Name 6735 6736 __wcstod_internal -- underlying function for wcstod 6737 6738 Synopsis 6739 6740 double __wcstod_internal(const wchar_t *nptr, wchar_t **endptr, int group); 6741 6742 Description 6743 6744 group shall be 0 or the behavior of __wcstod_internal is undefined. 6745 6746 __wcstod_internal(nptr, endptr, 0) has the same specification as wcstod(nptr, 6747 endptr). 6748 6749 __wcstod_internal is not in the source standard; it is only in the binary 6750 standard. 6751 6752 __wcstof_internal 6753 6754 Name 6755 6756 __wcstof_internal -- underlying function for wcstof 6757 6758 Synopsis 6759 6760 float __wcstof_internal(const wchar_t *nptr, wchar_t **endptr, int group); 6761 6762 Description 6763 6764 group shall be 0 or the behavior of __wcstof_internal is undefined. 6765 6766 __wcstof_internal(nptr, endptr, 0) has the same specification as wcstof(nptr, 6767 endptr). 6768 6769 __wcstof_internal is not in the source standard; it is only in the binary 6770 standard. 6771 6772 __wcstol_internal 6773 6774 Name 6775 6776 __wcstol_internal -- underlying function for wcstol 6777 6778 Synopsis 6779 6780 long __wcstol_internal(const wchar_t *nptr, wchar_t **endptr, int base, int 6781 group); 6782 6783 Description 6784 6785 group shall be 0 or the behavior of __wcstol_internal is undefined. 6786 6787 __wcstol_internal(nptr, endptr, base, 0) has the same specification as wcstol 6788 (nptr, endptr, base). 6789 6790 __wcstol_internal is not in the source standard; it is only in the binary 6791 standard. 6792 6793 __wcstold_internal 6794 6795 Name 6796 6797 __wcstold_internal -- underlying function for wcstold 6798 6799 Synopsis 6800 6801 long double __wcstold_internal(const wchar_t *nptr, wchar_t **endptr, int 6802 group); 6803 6804 Description 6805 6806 group shall be 0 or the behavior of __wcstold_internal is undefined. 6807 6808 __wcstold_internal(nptr, endptr, 0) has the same specification as wcstold(nptr, 6809 endptr). 6810 6811 __wcstold_internal is not in the source standard; it is only in the binary 6812 standard. 6813 6814 __wcstoul_internal 6815 6816 Name 6817 6818 __wcstoul_internal -- underlying function for wcstoul 6819 6820 Synopsis 6821 6822 unsigned long __wcstoul_internal(const wchar_t *restrict nptr, wchar_t 6823 **restrict endptr, int base, int group); 6824 6825 Description 6826 6827 group shall be 0 or the behavior of __wcstoul_internal is undefined. 6828 6829 __wcstoul_internal(nptr, endptr, base, 0) has the same specification as wcstoul 6830 (nptr, endptr, base). 6831 6832 __wcstoul_internal is not in the source standard; it is only in the binary 6833 standard. 6834 6835 __xmknod 6836 6837 Name 6838 6839 __xmknod -- make block or character special file 6840 6841 Synopsis 6842 6843 int __xmknod(int ver, const char *path, mode_t mode, dev_t *dev); 6844 6845 Description 6846 6847 The __xmknod shall implement the mknod interface from ISO POSIX (2003). 6848 6849 __xmknod(1, path, mode, dev) has the same specification as mknod(path, mode, 6850 dev). 6851 6852 ver shall be 1 or the behavior of __xmknod is undefined. 6853 6854 The __xmknod function is not in the source standard; it is only in the binary 6855 standard. The mknod function is not in the binary standard; it is only in the 6856 source standard. 6857 6858 __xstat 6859 6860 Name 6861 6862 __xstat -- Get File Status 6863 6864 Synopsis 6865 6866 #include 6867 #include 6868 6869 int __xstat(int ver, const char *path, (struct stat *stat_buf)); 6870 6871 int __lxstat(int ver, const char *path, (struct stat *stat_buf)); 6872 6873 int __fxstat(int ver, int fildes, (struct stat *stat_buf)); 6874 6875 Description 6876 6877 The functions __xstat, __lxstat, and __fxstat shall implement the ISO POSIX 6878 (2003) functions stat, lstat, and fstat respectively. 6879 6880 ver shall be 3 or the behavior of these functions is undefined. 6881 6882 __xstat(3, path, stat_buf) shall behave as stat(path, stat_buf) as specified by 6883 ISO POSIX (2003). 6884 6885 __lxstat(3, path, stat_buf) shall behave as lstat(path, stat_buf) as specified 6886 by ISO POSIX (2003). 6887 6888 __fxstat(3, fildes, stat_buf) shall behave as fstat(fildes, stat_buf) as 6889 specified by ISO POSIX (2003). 6890 6891 __xstat, __lxstat, and __fxstat are not in the source standard; they are only 6892 in the binary standard. 6893 6894 stat, lstat, and fstat are not in the binary standard; they are only in the 6895 source standard. 6896 6897 __xstat64 6898 6899 Name 6900 6901 __xstat64 -- Get File Status 6902 6903 Synopsis 6904 6905 #define _LARGEFILE_SOURCE 1 6906 #include 6907 #include 6908 6909 int __xstat64(int ver, const char *path, (struct stat64 *stat_buf)); 6910 6911 int __lxstat64(int ver, const char *path, (struct stat64 *stat_buf)); 6912 6913 int __fxstat64(int ver, int fildes, (struct stat64 *stat_buf)); 6914 6915 Description 6916 6917 The functions __xstat64, __lxstat64, and __fxstat64 shall implement the Large 6918 File Support functions stat64, lstat64, and fstat64 respectively. 6919 6920 ver shall be 3 or the behavior of these functions is undefined. 6921 6922 __xstat64(3, path, stat_buf) shall behave as stat(path, stat_buf) as specified 6923 by Large File Support. 6924 6925 __lxstat64(3, path, stat_buf) shall behave as lstat(path, stat_buf) as 6926 specified by Large File Support. 6927 6928 __fxstat64(3, fildes, stat_buf) shall behave as fstat(fildes, stat_buf) as 6929 specified by Large File Support. 6930 6931 __xstat64, __lxstat64, and __fxstat64 are not in the source standard; they are 6932 only in the binary standard. 6933 6934 stat64, lstat64, and fstat64 are not in the binary standard; they are only in 6935 the source standard. 6936 6937 _environ 6938 6939 Name 6940 6941 _environ -- alias for environ - user environment 6942 6943 Synopsis 6944 6945 extern char **_environ; 6946 6947 Description 6948 6949 _environ is an alias for environ - user environment. 6950 6951 _nl_msg_cat_cntr 6952 6953 Name 6954 6955 _nl_msg_cat_cntr -- new catalog load counter 6956 6957 Synopsis 6958 6959 #include 6960 6961 extern int _nl_msg_cat_cntr; 6962 6963 Description 6964 6965 _nl_msg_cat_cntr is incremented each time a new catalong is loaded. It is a 6966 variable defined in loadmsgcat.c and is used by Message catalogs for 6967 internationalization. 6968 6969 _obstack_begin 6970 6971 Name 6972 6973 _obstack_begin -- initialize an obstack for use 6974 6975 Synopsis 6976 6977 #include 6978 6979 int _obstack_begin(struct obstack *, int, int, void *(*) (long), void (*) (void 6980 *)); 6981 6982 Description 6983 6984 _obstack_begin initializes an obstack for use. 6985 6986 Future Directions 6987 6988 Future versions of this specification may not include support for this 6989 interface. 6990 6991 _obstack_newchunk 6992 6993 Name 6994 6995 _obstack_newchunk -- allocate a new current chunk of memory for the obstack 6996 6997 Synopsis 6998 6999 #include 7000 7001 void _obstack_newchunk(struct obstack *, int); 7002 7003 Description 7004 7005 _obstack_newchunk allocates a new current chunk of memory for the obstack. 7006 7007 Future Directions 7008 7009 Future versions of this specification may not include support for this 7010 interface. 7011 7012 _sys_errlist 7013 7014 Name 7015 7016 _sys_errlist -- array containing the "C" locale strings used by strerror() 7017 7018 Synopsis 7019 7020 #include 7021 7022 extern const char *const _sys_errlist[]; 7023 7024 Description 7025 7026 _sys_errlist is an array containing the "C" locale strings used by strerror. 7027 This normally should not be used directly. strerror provides all of the needed 7028 functionality. 7029 7030 _sys_siglist 7031 7032 Name 7033 7034 _sys_siglist -- array containing the names of the signal names 7035 7036 Synopsis 7037 7038 #include 7039 7040 extern const char *const _sys_siglist[NSIG]; 7041 7042 Description 7043 7044 _sys_siglist is an array containing the names of the signal names. 7045 7046 The _sys_siglist array is only in the binary standard; it is not in the source 7047 standard. Applications wishing to access the names of signals should use the 7048 strsignal function. 7049 7050 acct 7051 7052 Name 7053 7054 acct -- switch process accounting on or off 7055 7056 Synopsis 7057 7058 #include 7059 7060 int acct(const char *filename); 7061 7062 Description 7063 7064 When filename is the name of an existing file, acct turns accounting on and 7065 appends a record to filename for each terminating process. When filename is 7066 NULL, acct turns accounting off. 7067 7068 Return Value 7069 7070 On success, 0 is returned. On error, -1 is returned and the global variable 7071 errno is set appropriately. 7072 7073 Errors 7074 7075 ENOSYS 7076 7077 BSD process accounting has not been enabled when the operating system 7078 kernel was compiled. The kernel configuration parameter controlling this 7079 feature is CONFIG_BSD_PROCESS_ACCT. 7080 7081 ENOMEM 7082 7083 Out of memory. 7084 7085 EPERM 7086 7087 The calling process has no permission to enable process accounting. 7088 7089 EACCES 7090 7091 filename is not a regular file. 7092 7093 EIO 7094 7095 Error writing to the filename. 7096 7097 EUSERS 7098 7099 There are no more free file structures or we run out of memory. 7100 7101 adjtime 7102 7103 Name 7104 7105 adjtime -- correct the time to allow synchronization of the system clock 7106 7107 Synopsis 7108 7109 #include 7110 7111 int adjtime((const struct timeval *delta), (struct timeval *olddelta)); 7112 7113 Description 7114 7115 adjtime makes small adjustments to the system time as returned by gettimeofday 7116 (2), advancing or retarding it by the time specified by the timeval delta. If 7117 delta is negative, the clock is slowed down by incrementing it more slowly than 7118 normal until the correction is complete. If delta is positive, a larger 7119 increment than normal is used. The skew used to perform the correction is 7120 generally a fraction of one percent. Thus, the time is always a monotonically 7121 increasing function. A time correction from an earlier call to adjtime may not 7122 be finished when adjtime is called again. If olddelta is non-NULL, the 7123 structure pointed to will contain, upon return, the number of microseconds 7124 still to be corrected from the earlier call. 7125 7126 adjtime may be used by time servers that synchronize the clocks of computers in 7127 a local area network. Such time servers would slow down the clocks of some 7128 machines and speed up the clocks of others to bring them to the average network 7129 time. 7130 7131 The adjtime is restricted to the super-user. 7132 7133 Return Value 7134 7135 On success, 0 is returned. On error, -1 is returned and the global variable 7136 errno is set appropriately. 7137 7138 Errors 7139 7140 EFAULT 7141 7142 An argument points outside the process's allocated address space. 7143 7144 EPERM 7145 7146 The process's effective user ID is not that of the super-user. 7147 7148 adjtimex 7149 7150 Name 7151 7152 adjtimex -- tune kernel clock (DEPRECATED) 7153 7154 Synopsis 7155 7156 #include 7157 7158 int adjtimex((struct timex *buf)); 7159 7160 Description 7161 7162 The adjtimex function is deprecated from the LSB and is expected to disappear 7163 from a future version of the LSB. 7164 7165 7166 Note: The LSB generally does not include interfaces unlikely to be used by 7167 software applications. 7168 7169 Linux uses David L. Mills' clock adjustment algorithm (see RFC 1305). adjtimex 7170 reads and optionally sets adjustment parameters for this algorithm. adjtimex 7171 takes a pointer to a timex structure, updates kernel parameters from field 7172 values, and returns the same structure with current kernel values. This 7173 structure is declared as follows: 7174 7175 struct timex { 7176 int modes; /* mode selector */ 7177 long offset; /* time offset (usec) */ 7178 long freq; /* frequency offset (scaled ppm) */ 7179 long maxerror; /* maximum error (usec) */ 7180 long esterror; /* estimated error (usec) */ 7181 int status; /* clock command/status */ 7182 long constant; /* pll time constant */ 7183 long precision; /* clock precision (usec) (read only) */ 7184 long tolerance; /* clock frequency tolerance (ppm) 7185 (read only) */ 7186 struct timeval time; /* current time (read only) */ 7187 long tick; /* usecs between clock ticks */ 7188 }; 7189 7190 modes determines which parameters, if any, to set. modes may contain a 7191 bitwise-or combination of zero or more of the following bits: 7192 7193 #define ADJ_OFFSET 0x0001 /* time offset */ 7194 #define ADJ_FREQUENCY 0x0002 /* frequency offset */ 7195 #define ADJ_MAXERROR 0x0004 /* maximum time error */ 7196 #define ADJ_ESTERROR 0x0008 /* estimated time error */ 7197 #define ADJ_STATUS 0x0010 /* clock status */ 7198 #define ADJ_TIMECONST 0x0020 /* pll time constant */ 7199 #define ADJ_TICK 0x4000 /* tick value */ 7200 #define ADJ_OFFSET_SINGLESHOT 0x8001 /* old-fashioned adjtime */ 7201 7202 Ordinary users are restricted to a 0 value for modes. Only the superuser may 7203 set any parameters. 7204 7205 Return Value 7206 7207 On success, adjtimex returns the clock state: 7208 7209 #define TIME_OK 0 /* clock synchronized */ 7210 #define TIME_INS 1 /* insert leap second */ 7211 #define TIME_DEL 2 /* delete leap second */ 7212 #define TIME_OOP 3 /* leap second in progress */ 7213 #define TIME_WAIT 4 /* leap second has occurred */ 7214 #define TIME_BAD 5 /* clock not synchronized */ 7215 7216 On error, the global variable errno is set to -1. 7217 7218 Errors 7219 7220 EFAULT 7221 7222 buf does not point to writable memory. 7223 7224 EPERM 7225 7226 buf.mode is nonzero and the user is not super-user. 7227 7228 EINVAL 7229 7230 An attempt is made to set buf.offset to a value outside of the range 7231 -131071 to +131071, or to set buf.status to a value other than those listed 7232 above, or to set buf.tick to a value outside of the range 900000/HZ to 7233 1100000/HZ, where HZ is the system timer interrupt frequency. 7234 7235 asprintf 7236 7237 Name 7238 7239 asprintf -- write formatted output to a dynamically allocated string 7240 7241 Synopsis 7242 7243 #include 7244 7245 int asprintf(char ** restrict ptr, const char * restrict format ...); 7246 7247 Description 7248 7249 The asprintf function shall behave as sprintf, except that the output string 7250 shall be dynamically allocated space of sufficient length to hold the resulting 7251 string. The address of this dynamically allocated string shall be stored in the 7252 location referenced by ptr. 7253 7254 Return Value 7255 7256 Refer to fprintf. 7257 7258 Errors 7259 7260 Refer to fprintf. 7261 7262 bind_textdomain_codeset 7263 7264 Name 7265 7266 bind_textdomain_codeset -- specify encoding for message retrieval 7267 7268 Synopsis 7269 7270 #include 7271 7272 char * bind_textdomain_codeset (const char * domainname , const char * codeset 7273 ); 7274 7275 Description 7276 7277 The bind_textdomain_codeset function can be used to specify the output codeset 7278 for message catalogs for domain domainname. The codeset argument shall be a 7279 valid codeset name which can be used tor the iconv_open function, or a null 7280 pointer. If the codeset argument is the null pointer, then function returns the 7281 currently selected codeset for the domain with the name domainname. It shall 7282 return a null pointer if no codeset has yet been selected 7283 7284 Each successive call to bind_textdomain_codeset function overrrides the 7285 settings made by the preceding call with the same domainname. 7286 7287 The bind_textdomain_codeset function shall return a pointer to a string 7288 containing the name of the selected codeset. The string shall be allocated 7289 internally in the function and shall not be changed or freed by the user. 7290 7291 The bind_textdomain_codeset function returns a pointer to a string containing 7292 the name of the selected codeset. The string is allocated internally in the 7293 function and shall not be changed by the user. 7294 7295 Parameters 7296 7297 domainname 7298 7299 The domainname argument is applied to the currently active LC_MESSAGE 7300 locale. It is equivalent in syntax and meaning to the domainname argument 7301 to textdomain, except that the selection of the domain is valid only for 7302 the duration of the call. 7303 7304 codeset 7305 7306 The name of the output codeset for the selected domain, or NULL to select 7307 the current codeset. 7308 7309 If domainname is the null pointer, or is an empty string, 7310 bind_textdomain_codeset shall fail, but need not set errno. 7311 7312 Return Value 7313 7314 Returns the currently selected codeset name. It returns a null pointer if no 7315 codeset has yet been selected. 7316 7317 Errors 7318 7319 ENOMEM 7320 7321 Insufficient memory available to allocate return value. 7322 7323 See Also 7324 7325 gettext, dgettext, ngettext, dngettext, dcgettext, dcngettext, textdomain, 7326 bindtextdomain 7327 7328 bindresvport 7329 7330 Name 7331 7332 bindresvport -- bind socket to privileged IP port 7333 7334 Synopsis 7335 7336 #include 7337 #include 7338 7339 int bindresvport(int sd, struct sockaddr_in *sin); 7340 7341 Description 7342 7343 If the process has appropriate privilege, the bindresvport function shall bind 7344 a socket to a privileged IP port. 7345 7346 Return Value 7347 7348 On success, 0 is returned. On error, -1 is returned and the global variable 7349 errno is set appropriately. 7350 7351 Errors 7352 7353 EPERM 7354 7355 The process did not have appropriate privilege. 7356 7357 EPFNOSUPPORT 7358 7359 Address of sin did not match address family of sd. 7360 7361 bindtextdomain 7362 7363 Name 7364 7365 bindtextdomain -- specify the location of a message catalog 7366 7367 Synopsis 7368 7369 #include 7370 7371 char *bindtextdomain(const char *domainname, const char *dirname); 7372 7373 Description 7374 7375 The bindtextdomain shall set the the base directory of the hierarchy containing 7376 message catalogs for a given message domain. 7377 7378 The bindtextdomain function specifies that the domainname message catalog can 7379 be found in the dirname directory hierarchy, rather than in the system default 7380 locale data base. 7381 7382 If dirname is not NULL, the base directory for message catalogs belonging to 7383 domain domainname shall be set to dirname. If dirname is NULL, the base 7384 directory for message catalogs shall not be altered. 7385 7386 The function shall make copies of the argument strings as needed. 7387 7388 dirname can be an absolute or relative pathname. 7389 7390 7391 Note: Applications that wish to use chdir should always use absolute 7392 pathnames to avoid misadvertently selecting the wrong or non-existant 7393 directory. 7394 7395 If domainname is the null pointer, or is an empty string, bindtextdomain shall 7396 fail, but need not set errno. 7397 7398 The bindtextdomain function shall return a pointer to a string containing the 7399 name of the selected directory. The string shall be allocated internally in the 7400 function and shall not be changed or freed by the user. 7401 7402 Return Value 7403 7404 On success, bindtextdomain shall return a pointer to a string containing the 7405 directory pathname currently bound to the domain. On failure, a NULL pointer is 7406 returned, and the global variable errno may be set to indicate the error. 7407 7408 Errors 7409 7410 ENOMEM 7411 7412 Insufficient memory was available. 7413 7414 See Also 7415 7416 gettext, dgettext, ngettext, dngettext, dcgettext, dcngettext, textdomain, 7417 bind_textdomain_codeset 7418 7419 cfmakeraw 7420 7421 Name 7422 7423 cfmakeraw -- get and set terminal attributes 7424 7425 Synopsis 7426 7427 #include 7428 7429 void cfmakeraw(struct termios *termios_p); 7430 7431 Description 7432 7433 The cfmakeraw function shall set the attributes of the termios structure 7434 referenced by termios_p as follows: 7435 7436 termios_p->c_iflag &= ~(IGNBRK|BRKINT|PARMRK|ISTRIP 7437 |INLCR|IGNCR|ICRNL|IXON); 7438 7439 termios_p->c_oflag &= ~OPOST; 7440 7441 termios_p->c_lflag &= ~(ECHO|ECHONL|ICANON|ISIG|IEXTEN); 7442 7443 termios_p->c_cflag &= ~(CSIZE|PARENB); 7444 7445 termios_p->c_cflag |= CS8; 7446 7447 termios_p shall point to a termios structure that contains the following 7448 members: 7449 7450 tcflag_t c_iflag; /* input modes */ 7451 tcflag_t c_oflag; /* output modes */ 7452 tcflag_t c_cflag; /* control modes */ 7453 tcflag_t c_lflag; /* local modes */ 7454 cc_t c_cc[NCCS]; /* control chars */ 7455 7456 cfsetspeed 7457 7458 Name 7459 7460 cfsetspeed -- set terminal input and output data rate 7461 7462 Synopsis 7463 7464 #include 7465 7466 int cfsetspeed(struct termios *t, speedt speed); 7467 7468 Description 7469 7470 cfsetspeed sets the baud rate values in the termios structure. The effects of 7471 the function on the terminal as described below do not become effective, nor 7472 are all errors detected, until the tcsetattr function is called. Certain values 7473 for baud rates set in termios and passed to tcsetattr have special meanings. 7474 7475 Getting and Setting the Baud Rate 7476 7477 Input and output baud rates are found in the termios structure. The unsigned 7478 integer speed_t is typdef'd in the include file termios.h. The value of the 7479 integer corresponds directly to the baud rate being represented; however, the 7480 following symbolic values are defined. 7481 7482 #define B0 0 7483 #define B50 50 7484 #define B75 75 7485 #define B110 110 7486 #define B134 134 7487 #define B150 150 7488 #define B200 200 7489 #define B300 300 7490 #define B600 600 7491 #define B1200 1200 7492 #define B1800 1800 7493 #define B2400 2400 7494 #define B4800 4800 7495 #define B9600 9600 7496 #define B19200 19200 7497 #define B38400 38400 7498 #ifndef _POSIX_SOURCE 7499 #define EXTA 19200 7500 #define EXTB 38400 7501 #endif /*_POSIX_SOURCE */ 7502 7503 cfsetspeed sets both the input and output baud rates in the termios structure 7504 referenced by t to speed. 7505 7506 Return Value 7507 7508 On success, 0 is returned. On error, -1 is returned and the global variable 7509 errno is set appropriately. 7510 7511 Errors 7512 7513 EINVAL 7514 7515 Invalid speed argument 7516 7517 creat 7518 7519 Name 7520 7521 creat -- open a file 7522 7523 Description 7524 7525 creat is as specified in ISO POSIX (2003), but with differences as listed 7526 below. 7527 7528 May return ENODEV in place of ENXIO 7529 7530 Where the ISO POSIX (2003) specifies an ENXIO return, the implementation may 7531 return either ENXIO or ENODEV. Implementations are encouraged to return ENXIO. 7532 7533 7534 Note: As of spring 2004, we don't know of any Linux kernel patches to 7535 switch to ENXIO, but we believe that such a kernel patch would be accepted 7536 if submitted. 7537 7538 daemon 7539 7540 Name 7541 7542 daemon -- run in the background 7543 7544 Synopsis 7545 7546 #include 7547 7548 int daemon(int nochdir, int noclose); 7549 7550 Description 7551 7552 The daemon function shall create a new process, detached from the controlling 7553 terminal. If successful, the calling process shall exit and the new process 7554 shall continue to execute the application in the background. If nochdir 7555 evaluates to true, the current directory shall not be changed. Otherwise, 7556 daemon shall change the current working directory to the root (`/'). If noclose 7557 evaluates to true the standard input, standard output, and standard error file 7558 descriptors shall not be altered. Otherwise, daemon shall close the standard 7559 input, standard output and standard error file descriptors and reopen them 7560 attached to /dev/null. 7561 7562 Return Value 7563 7564 On error, -1 is returned, and the global variable errno is set to any of the 7565 errors specified for the library functions fork and setsid. 7566 7567 dcgettext 7568 7569 Name 7570 7571 dcgettext -- perform domain and category specific lookup in message catalog 7572 7573 Synopsis 7574 7575 #include 7576 #include 7577 7578 char *dcgettext(const char *domainname, const char *msgid, int category); 7579 7580 Description 7581 7582 The dcgettext function is a domain specified version of gettext. 7583 7584 The dcgettext function shall lookup the translation in the current locale of 7585 the message identified by msgid in the domain specified by domainname and in 7586 the locale category specified by category. If domainname is NULL, the current 7587 default domain shall be used. The msgid argument shall be a NULL-terminated 7588 string to be matched in the catalogue. category shall specify the locale 7589 category to be used for retrieving message strings. The category parameter 7590 shall be one of LC_CTYPE, LC_COLLATE, LC_MESSAGES, LC_MONETARY, LC_NUMERIC, or 7591 LC_TIME. The default domain shall not be changed by a call to dcgettext. 7592 7593 Return Value 7594 7595 If a translation was found in one of the specified catalogs, it shall be 7596 converted to the current locale's codeset and returned. The resulting 7597 NULL-terminated string shall be allocated by the dcgettext function, and must 7598 not be modified or freed. If no translation was found, or category was invalid, 7599 msgid shall be returned. 7600 7601 Errors 7602 7603 dcgettext shall not modify the errno global variable. 7604 7605 See Also 7606 7607 gettext, dgettext, ngettext, dngettext, dcngettext, textdomain, bindtextdomain, 7608 bind_textdomain_codeset 7609 7610 dcngettext 7611 7612 Name 7613 7614 dcngettext -- perform domain and category specific lookup in message catalog 7615 with plural 7616 7617 Synopsis 7618 7619 #include 7620 #include 7621 7622 char *dcngettext(const char *domainname, const char *msgid1, const char 7623 *msgid2, unsigned long int n, int category); 7624 7625 Description 7626 7627 The dcngettext function is a domain specific version of gettext, capable of 7628 returning either a singular or plural form of the message. The dcngettext 7629 function shall lookup the translation in the current locale of the message 7630 identified by msgid1 in the domain specified by domainname and in the locale 7631 category specified by category. If domainname is NULL, the current default 7632 domain shall be used. The msgid1 argument shall be a NULL-terminated string to 7633 be matched in the catalogue. category shall specify the locale category to be 7634 used for retrieving message strings. The category parameter shall be one of 7635 LC_CTYPE, LC_COLLATE, LC_MESSAGES, LC_MONETARY, LC_NUMERIC, or LC_TIME. The 7636 default domain shall not be changed by a call to dcgettext. If n is 1 then the 7637 singular version of the message is returned, otherwise one of the plural forms 7638 is returned, depending on the value of n and the current locale settings. 7639 7640 Return Value 7641 7642 If a translation corresponding to the value of n was found in one of the 7643 specified catalogs for msgid1, it shall be converted to the current locale's 7644 codeset and returned. The resulting NULL-terminated string shall be allocated 7645 by the dcngettext function, and must not be modified or freed. If no 7646 translation was found, or category was invalid, msgid1 shall be returned if n 7647 has the value 1, otherwise msgid2 shall be returned. 7648 7649 Errors 7650 7651 dcngettext shall not modify the errno global variable. 7652 7653 See Also 7654 7655 gettext, dgettext, ngettext, dngettext, dcgettext, textdomain, bindtextdomain, 7656 bind_textdomain_codeset 7657 7658 dgettext 7659 7660 Name 7661 7662 dgettext -- perform lookup in message catalog for the current LC_MESSAGES 7663 locale 7664 7665 Synopsis 7666 7667 #include 7668 7669 char *dgettext(const char *domainname, const char *msgid); 7670 7671 Description 7672 7673 dgettext is a domain specified version of gettext. 7674 7675 Parameters 7676 7677 domainname 7678 7679 dgettext applies domainname to the currently active LC_MESSAGE locale. This 7680 usage is equivalent in syntax and meaning to the textdomain function's 7681 application of domainname, except that the selection of the domain in 7682 dgettext is valid only for the duration of the call. 7683 7684 msgid 7685 7686 a NULL-terminated string to be matched in the catalogue with respect to a 7687 specific domain and the current locale. 7688 7689 Return Value 7690 7691 On success of a msgid query, the translated NULL-terminated string is returned. 7692 On error, the original msgid is returned. The length of the string returned is 7693 undetermined until dgettext is called. 7694 7695 Errors 7696 7697 dgettext will not modify the errno global variable. 7698 7699 See Also 7700 7701 gettext, dgettext, ngettext, dngettext, dcgettext, dcngettext, textdomain, 7702 bindtextdomain, bind_textdomain_codeset 7703 7704 dngettext 7705 7706 Name 7707 7708 dngettext -- perform lookup in message catalog for the current locale 7709 7710 Synopsis 7711 7712 #include 7713 7714 char *dngettext(const char *domainname, const char *msgid1, const char *msgid2, 7715 unsigned long int n); 7716 7717 Description 7718 7719 dngettext shall be equivalent to a call to 7720 7721 dcngettext(domainname, msgid1, msgid2, n, LC_MESSAGES) 7722 7723 See dgettext for more information. 7724 7725 See Also 7726 7727 gettext, dgettext, ngettext, dcgettext, dcngettext, textdomain, bindtextdomain, 7728 bind_textdomain_codeset 7729 7730 err 7731 7732 Name 7733 7734 err -- display formatted error messages 7735 7736 Synopsis 7737 7738 #include 7739 7740 void err(int eval, const char *fmt ...); 7741 7742 Description 7743 7744 The err function shall display a formatted error message on the standard error 7745 stream. First, err shall write the last component of the program name, a colon 7746 character, and a space character. If fmt is non-NULL, it shall be used as a 7747 format string for the printf family of functions, and err shall write the 7748 formatted message, a colon character, and a space. Finally, the error message 7749 string affiliated with the current value of the global variable errno shall be 7750 written, followed by a newline character. 7751 7752 The err function shall not return, the program shall terminate with the exit 7753 value of eval. 7754 7755 See Also 7756 7757 error, errx 7758 7759 Return Value 7760 7761 None. 7762 7763 Errors 7764 7765 None. 7766 7767 error 7768 7769 Name 7770 7771 error -- print error message 7772 7773 Synopsis 7774 7775 void error(int exitstatus, int errnum, const char *format ...); 7776 7777 Description 7778 7779 error shall print a message to standard error. 7780 7781 error shall build the message from the following elements in their specified 7782 order: 7783 7784 1. the program name. If the application has provided a function named 7785 error_print_progname, error shall call this to supply the program name; 7786 otherwise, error uses the content of the global variable program_name. 7787 7788 2. the colon and space characters, then the result of using the printf-style 7789 format and the optional arguments. 7790 7791 3. if errnum is nonzero, error shall add the colon and space characters, then 7792 the result of strerror(errnum). 7793 7794 4. a newline. 7795 7796 If exitstatus is nonzero, error shall call exit(exitstatus). 7797 7798 See Also 7799 7800 err, errx 7801 7802 errx 7803 7804 Name 7805 7806 errx -- display formatted error message and exit 7807 7808 Synopsis 7809 7810 #include 7811 7812 void errx(int eval, const char *fmt ...); 7813 7814 Description 7815 7816 The errx function shall display a formatted error message on the standard error 7817 stream. The last component of the program name, a colon character, and a space 7818 shall be output. If fmt is non-NULL, it shall be used as the format string for 7819 the printf family of functions, and the formatted error message, a colon 7820 character, and a space shall be output. The output shall be followed by a 7821 newline character. 7822 7823 errx does not return, but shall exit with the value of eval. 7824 7825 Return Value 7826 7827 None. 7828 7829 Errors 7830 7831 None. 7832 7833 See Also 7834 7835 error, err 7836 7837 fcntl 7838 7839 Name 7840 7841 fcntl -- file control 7842 7843 Description 7844 7845 fcntl is as specified in ISO POSIX (2003), but with differences as listed 7846 below. 7847 7848 Implementation may set O_LARGEFILE 7849 7850 According to the Single UNIX Specification, only an application sets fcntl 7851 flags, for example O_LARGEFILE. However, this specification also allows an 7852 implementation to set O_LARGEFILE in the case where the system default behavior 7853 matches the O_LARGEFILE behavior, for example if sizeof(off_t) is 8. Thus, 7854 calling fcntl with the F_GETFL command may return O_LARGEFILE as well as flags 7855 explicitly set by the application. 7856 7857 fflush_unlocked 7858 7859 Name 7860 7861 fflush_unlocked -- non thread safe fflush 7862 7863 Description 7864 7865 fflush_unlocked is the same as fflush except that it need not be thread safe. 7866 That is, it may only be invoked in the ways which are legal for getc_unlocked. 7867 7868 fgetwc_unlocked 7869 7870 Name 7871 7872 fgetwc_unlocked -- non thread safe fgetwc 7873 7874 Description 7875 7876 fgetwc_unlocked is the same as fgetwc except that it need not be thread safe. 7877 That is, it may only be invoked in the ways which are legal for getc_unlocked. 7878 7879 flock 7880 7881 Name 7882 7883 flock -- apply or remove an advisory lock on an open file 7884 7885 Synopsis 7886 7887 int flock(int fd, int operation); 7888 7889 Description 7890 7891 flock applies or removes an advisory lock on the open file fd. Valid operation 7892 types are: 7893 7894 LOCK_SH 7895 7896 Shared lock. More than one process may hold a shared lock for a given file 7897 at a given time. 7898 7899 LOCK_EX 7900 7901 Exclusive lock. Only one process may hold an exclusive lock for a given 7902 file at a given time. 7903 7904 LOCK_UN 7905 7906 Unlock. 7907 7908 LOCK_NB 7909 7910 Don't block when locking. May be specified (by oring) along with one of the 7911 other operations. 7912 7913 A single file may not simultaneously have both shared and exclusive locks. 7914 7915 Return Value 7916 7917 On success, 0 is returned. On error, -1 is returned and the global variable 7918 errno is set appropriately. 7919 7920 Errors 7921 7922 EWOULDBLOCK 7923 7924 The file is locked and the LOCK_NB flag was selected. 7925 7926 fopen 7927 7928 Name 7929 7930 fopen -- open a file 7931 7932 Description 7933 7934 fopen is as specified in ISO POSIX (2003), but with differences as listed 7935 below. 7936 7937 May return ENODEV in place of ENXIO 7938 7939 Where the ISO POSIX (2003) specifies an ENXIO return, the implementation may 7940 return either ENXIO or ENODEV. Implementations are encouraged to return ENXIO. 7941 7942 7943 Note: As of spring 2004, we don't know of any Linux kernel patches to 7944 switch to ENXIO, but we believe that such a kernel patch would be accepted 7945 if submitted. 7946 7947 freopen 7948 7949 Name 7950 7951 freopen -- open a file 7952 7953 Description 7954 7955 freopen is as specified in ISO POSIX (2003), but with differences as listed 7956 below. 7957 7958 May return ENODEV in place of ENXIO 7959 7960 Where the ISO POSIX (2003) specifies an ENXIO return, the implementation may 7961 return either ENXIO or ENODEV. Implementations are encouraged to return ENXIO. 7962 7963 7964 Note: As of spring 2004, we don't know of any Linux kernel patches to 7965 switch to ENXIO, but we believe that such a kernel patch would be accepted 7966 if submitted. 7967 7968 getdomainname 7969 7970 Name 7971 7972 getdomainname -- get NIS domain name (DEPRECATED). 7973 7974 Synopsis 7975 7976 #include 7977 7978 int getdomainname (char * name , size_t namelen ); 7979 7980 Description 7981 7982 If the Network Information System (NIS) is in use, getdomainname shall copy the 7983 NIS domain name to the supplied buffer identified by name, with maximum length 7984 namelen. If the NIS domain name is not currently set, getdomainname shall copy 7985 the string "(none)" to the name. If namelen is less the length of the string to 7986 be copied, getdomainname may either truncate the string to namelen characters 7987 and place it in name (without a terminating null character), or may fail with 7988 EINVAL. 7989 7990 Note that the NIS domain name is not the same as the domain portion of a fully 7991 qualified domain name (for example, in DNS). 7992 7993 Return Value 7994 7995 On success, getdomainname shall return 0. Otherwise, it shall return -1 and set 7996 errno to indicate the error). 7997 7998 Errors 7999 8000 EINVAL 8001 8002 name was a null pointer. 8003 8004 EINVAL 8005 8006 The buffer identified by name and namelen is of insufficient size to store 8007 the NIS domain name string, and the implementation considers this an error. 8008 8009 Future Directions 8010 8011 The LSB does not include other NIS interfaces, and a future version of this 8012 specification may deprecate this interface. Application developers should avoid 8013 using this interface where possible. 8014 8015 gethostbyname_r 8016 8017 Name 8018 8019 gethostbyname_r -- find network host database entry matching host name 8020 (DEPRECATED) 8021 8022 Synopsis 8023 8024 int gethostbyname_r(__const char *__restrict __name, (struct hostent 8025 *__restrict __result_buf), char *__restrict __buf, size_t __buflen, (struct 8026 hostent **__restrict __result), int *__restrict __h_errnop); 8027 8028 Description 8029 8030 The gethostbyname_r function is deprecated; applications should call 8031 getaddrinfo instead. 8032 8033 gethostbyname_r is a reentrant version of gethostbyname that searches the 8034 network host database for a host name match. 8035 8036 getloadavg 8037 8038 Name 8039 8040 getloadavg -- get system load averages 8041 8042 Synopsis 8043 8044 #include 8045 8046 int getloadavg(double loadavg[], int nelem); 8047 8048 Description 8049 8050 getloadavg returns the number of processes in the system run queue averaged 8051 over various periods of time. Up to nelem samples are retrieved and assigned to 8052 successive elements of loadavg[]. The system imposes a maximum of 3 samples, 8053 representing averages over the last 1, 5, and 15 minutes, respectively. 8054 8055 getopt 8056 8057 Name 8058 8059 getopt -- parse command line options 8060 8061 Synopsis 8062 8063 #include 8064 8065 int getopt(int argc, char * const argv[], const char *optstring); 8066 8067 extern char *optarg; 8068 extern int optind, opterr, optopt; 8069 8070 Description 8071 8072 The getopt function shall parse command line arguments as described in ISO 8073 POSIX (2003), with the following exceptions, where LSB and POSIX specifications 8074 vary. LSB systems shall implement the modified behaviors described below. 8075 8076 Argument Ordering 8077 8078 The getopt function can process command line arguments referenced by argv in 8079 one of three ways: 8080 8081 PERMUTE 8082 8083 the order of arguments in argv is altered so that all options (and their 8084 arguments) are moved in front of all of the operands. This is the default 8085 behavior. 8086 8087 8088 Note: This behavior has undefined results if argv is not modifiable. 8089 This is to support historic behavior predating the use of const and ISO 8090 C (1999). The function prototype was aligned with ISO POSIX (2003) 8091 despite the fact that it modifies argv, and the library maintainers are 8092 unwilling to change this. 8093 8094 REQUIRE_ORDER 8095 8096 The arguments in argv are processed in exactly the order given, and option 8097 processing stops when the first non-option argument is reached, or when the 8098 element of argv is "--". This ordering can be enforced either by setting 8099 the environment variable POSIXLY_CORRECT, or by setting the first character 8100 of optstring to '+'. 8101 8102 RETURN_IN_ORDER 8103 8104 The order of arguments is not altered, and all arguments are processed. 8105 Non-option arguments (operands) are handled as if they were the argument to 8106 an option with the value 1 ('\001'). This ordering is selected by setting 8107 the first character of optstring to '-'; 8108 8109 Option Characteristics 8110 8111 LSB specifies that: 8112 8113 * an element of argv that starts with "-" (and is not exactly "-" or "--") is 8114 an option element. 8115 8116 * characters of an option element, aside from the initial "-", are option 8117 characters. 8118 8119 POSIX specifies that: 8120 8121 * applications using getopt shall obey the following syntax guidelines: 8122 8123 + option name is a single alphanumeric character from the portable 8124 character set 8125 8126 + option is preceded by the '-' delimiter character 8127 8128 + options without option-arguments should be accepted when grouped behind 8129 one '-' delimiter 8130 8131 + each option and option-argument is a separate argument 8132 8133 + option-arguments are not optional 8134 8135 + all options should precede operands on the command line 8136 8137 + the argument "--" is accepted as a delimiter indicating the end of 8138 options and the consideration of subsequent arguments, if any, as 8139 operands 8140 8141 * historical implementations of getopt support other characters as options as 8142 an allowed extension, but applications that use extensions are not 8143 maximally portable. 8144 8145 * support for multi-byte option characters is only possible when such 8146 characters can be represented as type int. 8147 8148 * applications that call any utility with a first operand starting with '-' 8149 should usually specify "--" to mark the end of the options. Standard 8150 utilities that do not support this guideline indicate that fact in the 8151 OPTIONS section of the utility description. 8152 8153 Extensions 8154 8155 LSB specifies that: 8156 8157 * if a character is followed by two colons, the option takes an optional 8158 argument; if there is text in the current argv element, it is returned in 8159 optarg, otherwise optarg is set to 0. 8160 8161 * if optstring contains W followed by a semi-colon (;), then -W foo is 8162 treated as the long option --foo. 8163 8164 8165 Note: See getopt_long for a description of long options. 8166 8167 * The first character of optstring shall modify the behavior of getopt as 8168 follows: 8169 8170 + if the first character is '+', then REQUIRE_ORDER processing shall be 8171 in effect (see above) 8172 8173 + if the first character is '-', then RETURN_IN_ORDER processing shall be 8174 in effect (see above) 8175 8176 + if the first character is ':', then getopt shall return ':' instead of 8177 '?' to indicate a missing option argument, and shall not print any 8178 diagnostic message to stderr. 8179 8180 POSIX specifies that: 8181 8182 * the -W option is reserved for implementation extensions. 8183 8184 Return Values 8185 8186 LSB specifies the following additional getopt return values: 8187 8188 * '\001' is returned if RETURN_IN_ORDER argument ordering is in effect, and 8189 the next argument is an operand, not an option. The argument is available 8190 in optarg. 8191 8192 Any other return value has the same meaning as for POSIX. 8193 8194 POSIX specifies the following getopt return values: 8195 8196 * the next option character is returned, if found successfully. 8197 8198 * ':' is returned if a parameter is missing for one of the options and the 8199 first character of optstring is ':'. 8200 8201 * '?' is returned if an unknown option character not in optstring is 8202 encountered, or if getopt detects a missing argument and the first 8203 character of optstring is not ':'. 8204 8205 * -1 is returned for the end of the option list. 8206 8207 Environment Variables 8208 8209 LSB specifies that: 8210 8211 * if the variable POSIXLY_CORRECT is set, option processing stops as soon as 8212 a non-option argument is encountered. 8213 8214 * the variable _[PID]_GNU_nonoption_argv_flags_ (where [PID] is the process 8215 ID for the current process), contains a space separated list of arguments 8216 that should not be treated as arguments even though they appear to be so. 8217 8218 8219 Rationale: This was used by bash 2.0 to communicate to GNU libc which 8220 arguments resulted from wildcard expansion and so should not be 8221 considered as options. This behavior was removed in bash version 2.01, 8222 but the support remains in GNU libc. 8223 8224 This behavior is DEPRECATED in this version of the LSB; future revisions of 8225 this specification may not include this requirement. 8226 8227 getopt_long 8228 8229 Name 8230 8231 getopt_long -- parse command line options 8232 8233 Synopsis 8234 8235 #define _GNU_SOURCE 8236 #include 8237 8238 int getopt_long(int argc, char * const argv[], const char *opstring, (const 8239 struct option *longopts), int *longindex); 8240 8241 Description 8242 8243 getopt_long works like getopt except that it also accepts long options, started 8244 out by two dashes. Long option names may be abbreviated if the abbreviation is 8245 unique or is an exact match for some defined option. A long option may take a 8246 parameter, of the form --arg=param or --arg param. 8247 8248 longopts is a pointer to the first element of an array of struct option 8249 declared in getopt.h as: 8250 8251 struct option { 8252 const char *name; 8253 int has_arg; 8254 int *flag; 8255 int val; 8256 }; 8257 8258 The fields in this structure have the following meaning: 8259 8260 name 8261 8262 The name of the long option. 8263 8264 has_arg 8265 8266 One of: 8267 8268 no_argument (or 0) if the option does not take an argument, 8269 required_argument (or 1) if the option requires an argument, or 8270 optional_argument (or 2) if the option takes an optional argument. 8271 8272 flag 8273 8274 specifies how results are returned for a long option. If flag is NULL, then 8275 getopt_long shall return val. (For example, the calling program may set val 8276 to the equivalent short option character.) Otherwise, getopt_long returns 8277 0, and flag shall point to a variable which shall be set to val if the 8278 option is found, but left unchanged if the option is not found. 8279 8280 val 8281 8282 The value to return, or to load into the variable pointed to by flag. 8283 8284 Return Value 8285 8286 getopt_long returns the option character if a short option was found 8287 successfully, or ":" if there was a missing parameter for one of the options, 8288 or "?" for an unknown option character, or -1 for the end of the option list. 8289 8290 For a long option, getopt_long returns val if flag is NULL, and 0 otherwise. 8291 Error and -1 returns are the same as for getopt, plus "?" for an ambiguous 8292 match or an extraneous parameter. 8293 8294 getopt_long_only 8295 8296 Name 8297 8298 getopt_long_only -- parse command line options 8299 8300 Synopsis 8301 8302 #define _GNU_SOURCE 8303 #include 8304 8305 int getopt_long_only(int argc, char * const argv[], const char *optstring, 8306 (const struct option *longopts), int *longindex); 8307 8308 Description 8309 8310 getopt_long_only is like getopt_long, but "-" as well as "--" can indicate a 8311 long option. If an option that starts with "-" (not "--") doesn't match a long 8312 option, but does match a short option, it is parsed as a short option instead. 8313 8314 Return Value 8315 8316 getopt_long_only returns the option character if the option was found 8317 successfully, or ":" if there was a missing parameter for one of the options, 8318 or "?" for an unknown option character, or -1 for the end of the option list. 8319 8320 getopt_long_only also returns the option character when a short option is 8321 recognized. For a long option, they return val if flag is NULL, and 0 8322 otherwise. Error and -1 returns are the same as for getopt, plus "?" for an 8323 ambiguous match or an extraneous parameter. 8324 8325 gettext 8326 8327 Name 8328 8329 gettext -- Search message catalogs for a string 8330 8331 Synopsis 8332 8333 #include 8334 8335 char *gettext(const char *msgid); 8336 8337 Description 8338 8339 The gettext function shall search the currently selected message catalogs for a 8340 string identified by the string msgid. If a string is located, that string 8341 shall be returned. 8342 8343 The gettext function is equivalent to dcgettext(NULL, msgid, LC_MESSAGES). 8344 8345 Return Value 8346 8347 If a string is found in the currently selected message catalogs for msgid, then 8348 a pointer to that string shall be returned. Otherwise, a pointer to msgid shall 8349 be returned. 8350 8351 Applications shall not modify the string returned by gettext. 8352 8353 Errors 8354 8355 None. 8356 8357 The gettext function shall not modify errno. 8358 8359 See Also 8360 8361 dgettext, ngettext, dngettext, dcgettext, dcngettext, textdomain, 8362 bindtextdomain, bind_textdomain_codeset 8363 8364 getutent 8365 8366 Name 8367 8368 getutent -- access user accounting database entries 8369 8370 Synopsis 8371 8372 #include 8373 8374 struct utmp *getutent(void); 8375 8376 Description 8377 8378 The getutent function shall read the next entry from the user accounting 8379 database. 8380 8381 Return Value 8382 8383 Upon successful completion, getutent shall return a pointer to a utmp structure 8384 containing a copy of the requested entry in the user accounting database. 8385 Otherwise, a null pointer shall be returned. The return value may point to a 8386 static area which is overwritten by a subsequent call to getutent. 8387 8388 Errors 8389 8390 None defined. 8391 8392 getutent_r 8393 8394 Name 8395 8396 getutent_r -- access user accounting database entries 8397 8398 Synopsis 8399 8400 int getutent_r(struct utmp * buffer, struct utmp ** result); 8401 8402 Description 8403 8404 The getutent_r function is a reentrant version of the getutent function. On 8405 entry, buffer should point to a user supplied buffer to which the next entry in 8406 the database will be copied, and result should point to a location where the 8407 result will be stored. 8408 8409 Return Value 8410 8411 On success, getutent_r shall return 0 and set the location referenced by result 8412 to a pointer to buffer. Otherwise, getutent_r shall return -1 and set the 8413 location referenced by result to NULL. 8414 8415 glob64 8416 8417 Name 8418 8419 glob64 -- find pathnames matching a pattern (Large File Support) 8420 8421 Synopsis 8422 8423 #include 8424 8425 int glob64(const char *pattern, int flags, int (*errfunc) (const char *, int), 8426 glob64_t *pglob); 8427 8428 Description 8429 8430 The glob64 function is a large-file version of the glob defined in ISO POSIX 8431 (2003). It shall search for pathnames matching pattern according to the rules 8432 used by the shell, /bin/sh. No tilde expansion or parameter substitution is 8433 done; see wordexp. 8434 8435 The results of a glob64 call are stored in the structure pointed to by pglob, 8436 which is a glob64_t declared in glob.h with the following members: 8437 8438 typedef struct 8439 { 8440 size_t gl_pathc; 8441 char **gl_pathv; 8442 size_t gl_offs; 8443 int gl_flags; 8444 void (*gl_closedir) (void *); 8445 struct dirent64 *(*gl_readdir64) (void *); 8446 void *(*gl_opendir) (const char *); 8447 int (*gl_lstat) (const char *, struct stat *); 8448 int (*gl_stat) (const char *, struct stat *); 8449 } 8450 glob64_t; 8451 8452 Structure members with the same name as corresponding members of a glob_t as 8453 defined in ISO POSIX (2003) shall have the same purpose. 8454 8455 Other members are defined as follows: 8456 8457 gl_flags 8458 8459 reserved for internal use 8460 8461 gl_closedir 8462 8463 pointer to a function capable of closing a directory opened by gl_opendir 8464 8465 gl_readdir64 8466 8467 pointer to a function capable of reading entries in a large directory 8468 8469 gl_opendir 8470 8471 pointer to a function capable of opening a large directory 8472 8473 gl_stat 8474 8475 pointer to a function capable of returning file status for a large file 8476 8477 gl_lstat 8478 8479 pointer to a function capable of returning file status information for a 8480 large file or symbolic link 8481 8482 A large file or large directory is one with a size which cannot be represented 8483 by a variable of type off_t. 8484 8485 Return Value 8486 8487 On success, 0 is returned. Other possible returns are: 8488 8489 GLOB_NOSPACE 8490 8491 out of memory 8492 8493 GLOB_ABORTED 8494 8495 read error 8496 8497 GLOB_NOMATCH 8498 8499 no match found 8500 8501 globfree64 8502 8503 Name 8504 8505 globfree64 -- free memory from glob64() (Large File Support) 8506 8507 Synopsis 8508 8509 #include 8510 8511 void globfree64(glob64_t *pglob); 8512 8513 Description 8514 8515 globfree64 frees the dynamically allocated storage from an earlier call to 8516 glob64. 8517 8518 globfree64 is a 64-bit version of globfree. 8519 8520 initgroups 8521 8522 Name 8523 8524 initgroups -- initialize the supplementary group access list 8525 8526 Synopsis 8527 8528 #include 8529 #include 8530 8531 int initgroups(const char *user, gid_t group); 8532 8533 Description 8534 8535 If the process has appropriate privilege, the initgroups function shall 8536 initialize the Supplementary Group IDs for the current process by reading the 8537 group database and using all groups of which user is a member. The additional 8538 group group is also added to the list. 8539 8540 Return Value 8541 8542 On success, 0 is returned. On error, -1 is returned and the global variable 8543 errno is set appropriately. 8544 8545 Errors 8546 8547 EPERM 8548 8549 The calling process does not have sufficient privileges. 8550 8551 ENOMEM 8552 8553 Insufficient memory to allocate group information structure. 8554 8555 See Also 8556 8557 setgroups 8558 8559 ioctl 8560 8561 Name 8562 8563 ioctl -- control device 8564 8565 Synopsis 8566 8567 #include 8568 8569 int ioctl (int d , int request , ... ); 8570 8571 Description 8572 8573 The ioctl function shall manipulate the underlying device parameters of special 8574 files. d shall be an open file descriptor referring to a special file. The 8575 ioctl function shall take three parameters; the type and value of the third 8576 parameter is dependent on the device and request. 8577 8578 Conforming LSB applications shall not call ioctl except in situations 8579 explicitly stated in this specification. 8580 8581 Return Value 8582 8583 On success, 0 is returned. An ioctl may use the return value as an output 8584 parameter and return a non-negative value on success. On error, -1 is returned 8585 and the global variable errno is set appropriately. 8586 8587 Errors 8588 8589 EBADF 8590 8591 d is not a valid descriptor. 8592 8593 EFAULT 8594 8595 The third parameter references an inaccessible memory area. 8596 8597 ENOTTY 8598 8599 d is not associated with a character special device. 8600 8601 ENOTTY 8602 8603 The specified request does not apply to the kind of object that d 8604 references. 8605 8606 EINVAL 8607 8608 request or the third parameter is not valid. 8609 8610 sockio 8611 8612 Name 8613 8614 sockio -- socket ioctl commands 8615 8616 Synopsis 8617 8618 #include 8619 #include 8620 #include 8621 8622 int ioctl(int sockfd, int request, char *argp); 8623 8624 Description 8625 8626 Socket ioctl commands are a subset of the ioctl calls, which can perform a 8627 variety of functions on sockets. sockfd shall contain the value of a file 8628 descriptor that was created with the socket or accept calls. 8629 8630 Socket ioctl commands apply to the underlying network interfaces, and affect 8631 the entire system, not just the file descriptor used to issue the ioctl. 8632 8633 The following values for request are accepted: 8634 8635 SIOCGIFCONF 8636 8637 Gets the interface configuration list for the system. 8638 8639 8640 Note: SIOCGIFCONF is similar to the if_nameindex family found in the 8641 ISO POSIX (2003) or the getifaddrs family found in BSD derived systems. 8642 8643 argp shall point to a ifconf structure, as described in . Before 8644 calling, the caller shall set the ifc_ifcu.ifcu_req field to point to an 8645 array of ifreq structures, and set ifc_len to the size in bytes of this 8646 allocated array. Upon return, ifc_len will contain the size in bytes of the 8647 array which was actually used. If it is the same as the length upon 8648 calling, the caller should assume that the array was too small and try 8649 again with a larger array. 8650 8651 On success, SIOCGIFCONF can return any nonnegative value. 8652 8653 8654 Rationale: Historical UNIX systems disagree on the meaning of the 8655 return value. 8656 8657 SIOCGIFFLAGS 8658 8659 Gets the interface flags for the indicated interface. argp shall point to a 8660 ifreq structure. Before calling, the caller should fill in the ifr_name 8661 field with the interface name, and upon return, the ifr_ifru.ifru_flags 8662 field is set with the interface flags. 8663 8664 SIOCGIFADDR 8665 8666 Gets the interface address for the given interface. argp shall point to a 8667 ifreq structure. Before calling, the caller should fill in the ifr_name 8668 field with the interface name, and upon return, the ifr_ifru.ifru_addr 8669 field is set with the interface address. 8670 8671 SIOCGIFNETMASK 8672 8673 Gets the network mask for the given interface. argp shall point to a ifreq 8674 structure. Before calling, the caller should fill in the ifr_name field 8675 with the interface name, and upon return, the ifr_ifru.ifru_netmask field 8676 is set with the network mask. 8677 8678 FIONREAD 8679 8680 Returns the amount of queued unread data in the receive buffer. argp shall 8681 point to an integer where the result is to be placed. 8682 8683 Return Value 8684 8685 On success, if request is SIOCGIFCONF, a non-negative integer shall be 8686 returned. If request is not SIOCGIFCONF, on success 0 is returned. On error, -1 8687 is returned and the global variable errno is set appropriately. 8688 8689 Errors 8690 8691 EBADF 8692 8693 sockfd is not a valid descriptor. 8694 8695 EFAULT 8696 8697 argp references an inaccessible memory area. 8698 8699 ENOTTY 8700 8701 The specified request does not apply to the kind of object that the 8702 descriptor sockfd references. 8703 8704 EINVAL 8705 8706 Either request or argp is invalid. 8707 8708 ENOTCONN 8709 8710 The operation is only defined on a connected socket, but the socket wasn't 8711 connected. 8712 8713 kill 8714 8715 Name 8716 8717 kill -- send a signal 8718 8719 Synopsis 8720 8721 #include 8722 8723 int kill(pid_t pid, int sig); 8724 8725 Description 8726 8727 kill is as specified in the ISO POSIX (2003), but with differences as listed 8728 below. 8729 8730 Process ID -1 doesn't affect calling process 8731 8732 If pid is specified as -1, sig shall not be sent to the calling process. Other 8733 than this, the rules in the ISO POSIX (2003) apply. 8734 8735 8736 Rationale: This was a deliberate Linus decision after an unpopular 8737 experiment in including the calling process in the 2.5.1 kernel. See "What 8738 does it mean to signal everybody?", Linux Weekly News, 20 December 2001, 8739 http://lwn.net/2001/1220/kernel.php3 8740 8741 mbsnrtowcs 8742 8743 Name 8744 8745 mbsnrtowcs -- convert a multibyte string to a wide character string 8746 8747 Synopsis 8748 8749 #include 8750 8751 size_t mbsnrtowcs(wchar_t *dest, const char **src, size_t nms, size_t len, 8752 mbstate_t *ps); 8753 8754 Description 8755 8756 mbsnrtowcs is like mbsrtowcs, except that the number of bytes to be converted, 8757 starting at src, is limited to nms. 8758 8759 If dest is not a NULL pointer, mbsnrtowcs converts at most nms bytes from the 8760 multibyte string src to a wide-character string starting at dest. At most, len 8761 wide characters are written to dest. The state ps is updated. 8762 8763 The conversion is effectively performed by repeatedly calling: 8764 8765 8766 mbrtowc(dest, *src, n, ps) 8767 8768 where n is some positive number, as long as this call succeeds, and then 8769 incrementing dest by one and src by the number of bytes consumed. 8770 8771 The conversion can stop for three reasons: 8772 8773 * An invalid multibyte sequence has been encountered. In this case src is 8774 left pointing to the invalid multibyte sequence, (size_t)(-1) is returned, 8775 and errno is set to EILSEQ. 8776 8777 * The nms limit forces a stop, or len non-L'\0' wide characters have been 8778 stored at dest. In this case, src is left pointing to the next multibyte 8779 sequence to be converted, and the number of wide characters written to dest 8780 is returned. 8781 8782 * The multibyte string has been completely converted, including the 8783 terminating '\0' (which has the side effect of bringing back ps to the 8784 initial state). In this case, src is set to NULL, and the number of wide 8785 characters written to dest, excluding the terminating L'\0' character, is 8786 returned. 8787 8788 If dest is NULL, len is ignored, and the conversion proceeds as above, except 8789 that the converted wide characters are not written out to memory, and that no 8790 destination length limit exists. 8791 8792 In both of the above cases, if ps is a NULL pointer, a static anonymous state 8793 only known to mbsnrtowcs is used instead. 8794 8795 The programmer shall ensure that there is room for at least len wide characters 8796 at dest. 8797 8798 Return Value 8799 8800 mbsnrtowcs returns the number of wide characters that make up the converted 8801 part of the wide character string, not including the terminating null wide 8802 character. If an invalid multibyte sequence was encountered, (size_t)(-1) is 8803 returned, and the global variable errno is set to EILSEQ. 8804 8805 Notes 8806 8807 The behavior of mbsnrtowcs depends on the LC_CTYPE category of the current 8808 locale. 8809 8810 Passing NULL as ps is not multi-thread safe. 8811 8812 memmem 8813 8814 Name 8815 8816 memmem -- locate bytes 8817 8818 Synopsis 8819 8820 #define _GNU_SOURCE 8821 #include 8822 8823 void *memmem(const void *haystack, size_t haystacklen, const void *needle, 8824 size_t needlelen); 8825 8826 Description 8827 8828 memmem finds the start of the first occurrence of the byte array referenced by 8829 needle of length needlelen in the memory area haystack of length haystacklen. 8830 8831 Return Value 8832 8833 memmem returns a pointer to the beginning of the byte array, or NULL if the 8834 byte array is not found. 8835 8836 Notes 8837 8838 Earlier versions of the C library (prior to glibc 2.1) contained a memmem with 8839 various problems, and application developers should treat this function with 8840 care. 8841 8842 memrchr 8843 8844 Name 8845 8846 memrchr -- scan memory for a character 8847 8848 Synopsis 8849 8850 #include 8851 8852 void *memrchr(const void *s, int c, size_t n); 8853 8854 Description 8855 8856 The memrchr function shall locate the last occurence of c (converted to an 8857 unsigned char) in the initial n bytes (each interpreted as an unsigned char) of 8858 the object pointed to by s. 8859 8860 Return Value 8861 8862 The memrchr shall return a pointer to the located byte, or a null pointer if 8863 the byte does not occur in the object. 8864 8865 Errors 8866 8867 No errors are defined. 8868 8869 See Also 8870 8871 memchr 8872 8873 ngettext 8874 8875 Name 8876 8877 ngettext -- Search message catalogs for plural string 8878 8879 Synopsis 8880 8881 #include 8882 8883 char *ngettext(const char *msgid1, const char *msgid2, unsigned long int n); 8884 8885 Description 8886 8887 The ngettext function shall search the currently selected message catalogs for 8888 a string matching the singular string msgid1. If a string is located, and if n 8889 is 1, that string shall be returned. If n is not 1, a pluralized version 8890 (dependant on n) of the string shall be returned. 8891 8892 The ngettext function is equivalent to dcngettext(NULL, msgid1, msgid2, n, 8893 LC_MESSAGES). 8894 8895 Return Value 8896 8897 If a string is found in the currently selected message catalogs for msgid1, 8898 then if n is 1 a pointer to the located string shall be returned. If n is not 8899 1, a pointer to an appropriately pluralized version of the string shall be 8900 returned. If no message could be found in the currently selected mesage 8901 catalogs, then if n is 1, a pointer to msgid1 shall be returned, otherwise a 8902 pointer to msgid2 shall be returned. 8903 8904 Applications shall not modify the string returned by ngettext. 8905 8906 Errors 8907 8908 None. 8909 8910 The ngettext function shall not modify errno. 8911 8912 See Also 8913 8914 gettext, dgettext, ngettext, dngettext, dcgettext, dcngettext, textdomain, 8915 bindtextdomain, bind_textdomain_codeset 8916 8917 obstack_free 8918 8919 Name 8920 8921 obstack_free -- free an object in the obstack 8922 8923 Synopsis 8924 8925 #include 8926 8927 void obstack_free((struct obstack *obstack), void *block); 8928 8929 Description 8930 8931 obstack_free frees an object in the obstack. 8932 8933 Future Directions 8934 8935 Future versions of this specification may not include support for this 8936 interface. 8937 8938 open 8939 8940 Name 8941 8942 open -- open a file 8943 8944 Synopsis 8945 8946 #include 8947 #include 8948 8949 int open(const char *path, int oflag, ...); 8950 8951 Description 8952 8953 The open function shall behave as specified in ISO POSIX (2003), except with 8954 differences as listed below. 8955 8956 May return ENODEV in place of ENXIO 8957 8958 Where ISO POSIX (2003) specifies an ENXIO return, a conforming implementation 8959 may return either ENXIO or ENODEV. Implementations are encouraged to return 8960 ENXIO. 8961 8962 8963 Rationale: As of spring 2004, no Linux kernel patches to switch to ENXIO 8964 are known, but it is believed that such a kernel patch would be accepted if 8965 submitted. 8966 8967 opterr 8968 8969 Name 8970 8971 opterr -- external variable used in getopt() 8972 8973 Synopsis 8974 8975 extern int opterr; 8976 8977 Description 8978 8979 opterr is used as a flag to suppress an error message generated by getopt. When 8980 opterr is set to 0, it suppresses the error message generated by getopt when 8981 that function does not recognize an option character. 8982 8983 optind 8984 8985 Name 8986 8987 optind -- external variable used in getopt() 8988 8989 Synopsis 8990 8991 extern int optind; 8992 8993 Description 8994 8995 optind holds the current index of the array argv[], which contains the command 8996 line options being parsed by getopt. 8997 8998 optopt 8999 9000 Name 9001 9002 optopt -- external variable used in getopt() 9003 9004 Synopsis 9005 9006 extern int optopt; 9007 9008 Description 9009 9010 optopt holds the unknown option character when that option character is not 9011 recognized by getopt. 9012 9013 pmap_getport 9014 9015 Name 9016 9017 pmap_getport -- Find the port number assigned to a service registered with a 9018 portmapper. 9019 9020 Synopsis 9021 9022 #include 9023 9024 u_short *pmap_getport(struct sockaddr_in *address, __const u_long program, 9025 __const u_long *version, u_int protocol); 9026 9027 Description 9028 9029 The pmap_getport function shall return the port number assigned to a service 9030 registered with a RPC Binding service running on a given target system, using 9031 the protocol described in RFC 1833: Binding Protocols for ONC RPC Version 2. 9032 The pmap_getport function shall be called given the RPC program number program, 9033 the program version version, and transport protocol protocol. Conforming 9034 implementations shall support both IPPROTO_UDP and IPPROTO_TCP protocols. On 9035 entry, address shall specify the address of the system on which the portmapper 9036 to be contacted resides. The value of address->sin_port shall be ignored, and 9037 the standard value for the portmapper port shall always be used. 9038 9039 Note: Security and network restrictions may prevent a conforming 9040 application from contacting a remote RPC Binding Service. 9041 9042 Return Value 9043 9044 On success, the pmap_getport function shall return the port number in host byte 9045 order of the RPC application registered with the remote portmapper. On failure, 9046 if either the program was not registered or the remote portmapper service could 9047 not be reached, the pmap_getport function shall return 0. If the remote portmap 9048 service could not be reached, the status is left in the global variable 9049 rpc_createerr. 9050 9051 pmap_set 9052 9053 Name 9054 9055 pmap_set -- Establishes mapping to machine's RPC Bind service. 9056 9057 Synopsis 9058 9059 #include 9060 9061 *pmap_set(__const u_long program, __const u_long version, int protocol, u_short 9062 port); 9063 9064 Description 9065 9066 pmap_set establishes a mapping between the triple [program,version,protocol] 9067 and port on the machine's RPC Bind service. The value of protocol is most 9068 likely IPPROTO_UDP or IPPROTO_TCP. Automatically done by svc_register. 9069 9070 Return Value 9071 9072 pmap_set returns 1 if it suceeds, 0 otherwise. 9073 9074 pmap_unset 9075 9076 Name 9077 9078 pmap_unset -- Destroys RPC Binding 9079 9080 Synopsis 9081 9082 #include 9083 9084 void pmap_unset(u_long prognum, u_long versnum); 9085 9086 Description 9087 9088 As a user interface to the RPC Bind service, pmap_unset destroys all mapping 9089 between the triple [prognum,versnum, *] and ports on the machine's RPC Bind 9090 service. 9091 9092 Return Value 9093 9094 pmap_unset returns 1 if it succeeds, zero otherwise. 9095 9096 psignal 9097 9098 Name 9099 9100 psignal -- print signal message 9101 9102 Synopsis 9103 9104 #include 9105 9106 void psignal(int sig, const char *s); 9107 9108 extern const char *const sys_siglist[] 9109 9110 Description 9111 9112 The psignal function shall display a message on the stderr stream. If s is not 9113 the null pointer, and does not point to an empty string (e.g. "\0"), the 9114 message shall consist of the string s, a colon, a space, and a string 9115 describing the signal number sig; otherwise psignal shall display only a 9116 message describing the signal number sig. If sig is invalid, the message 9117 displayed shall indicate an unknown signal. 9118 9119 The array sys_siglist holds the signal description strings indexed by signal 9120 number. 9121 9122 Return Value 9123 9124 psignal returns no value. 9125 9126 random_r 9127 9128 Name 9129 9130 random_r -- generate random number 9131 9132 Synopsis 9133 9134 int random_r((struct random_data *__restrict __buf), int32_t *__restrict 9135 __result); 9136 9137 Description 9138 9139 random_r is a reentrant version of random, which generates a pseudorandom 9140 number. 9141 9142 Future Directions 9143 9144 Since this function requires support from other functions not specified in this 9145 specification (most notably initstate_r), a future version of this 9146 specification may deprecate this interface. 9147 9148 setbuffer 9149 9150 Name 9151 9152 setbuffer -- stream buffering operation 9153 9154 Synopsis 9155 9156 #include 9157 9158 void setbuffer(FILE *stream, char *buf, size_t size); 9159 9160 Description 9161 9162 setbuffer is an alias for the call to setvbuf. It works the same, except that 9163 the size of the buffer in setbuffer is up to the caller, rather than being 9164 determined by the default BUFSIZ. 9165 9166 setdomainname 9167 9168 Name 9169 9170 setdomainname -- set NIS domain name (DEPRECATED). 9171 9172 Synopsis 9173 9174 #include 9175 9176 int setdomainname (char * name , size_t namelen ); 9177 9178 Description 9179 9180 If NIS is in use, set the NIS domain name. Note that this is not the same as 9181 the domain name which provides the domain portion of a fully qualified domain 9182 name (for example, in DNS). If NIS is not in use, this function may set the 9183 domain name anyway, or it may fail. 9184 9185 This call shall fail unless the caller has appropriate privileges. 9186 9187 namelen shall be the length of the string pointed to by name. 9188 9189 Return Value 9190 9191 On success, setdomainname shall return 0. Otherwise, it shall return -1 and set 9192 errno to indicate the error. 9193 9194 Errors 9195 9196 EPERM 9197 9198 The process did not have sufficient privilege to set the domain name. 9199 9200 EINVAL 9201 9202 name is a null pointer. 9203 9204 setgroups 9205 9206 Name 9207 9208 setgroups -- set list of supplementary group IDs 9209 9210 Synopsis 9211 9212 #include 9213 9214 int setgroups(size_t size, const gid_t *list); 9215 9216 Description 9217 9218 If the process has appropriate privilege, the setgroups function shall set the 9219 supplementary group IDs for the current process. list shall reference an array 9220 of size group IDs. A process may have at most NGROUPS_MAX supplementary group 9221 IDs. 9222 9223 Return Value 9224 9225 On successful completion, 0 is returned. On error, -1 is returned and the errno 9226 is set to indicate the error. 9227 9228 Errors 9229 9230 EFAULT 9231 9232 list has an invalid address. 9233 9234 EPERM 9235 9236 The process does not have appropriate privileges. 9237 9238 EINVAL 9239 9240 size is greater than NGROUPS_MAX. 9241 9242 sethostid 9243 9244 Name 9245 9246 sethostid -- set the unique identifier of the current host 9247 9248 Synopsis 9249 9250 #include 9251 9252 int sethostid(long int hostid); 9253 9254 Description 9255 9256 sethostid sets a unique 32-bit identifier for the current machine. The 32-bit 9257 identifier is intended to be unique among all UNIX systems in existence. This 9258 normally resembles the Internet address for the local machine as returned by 9259 gethostbyname(3), and thus usually never needs to be set. 9260 9261 The sethostid call is restricted to the superuser. 9262 9263 hostid is stored in the file /etc/hostid. 9264 9265 Return Value 9266 9267 gethostid returns the 32-bit identifier for the current host as set by 9268 sethostid(2). 9269 9270 Files 9271 9272 /etc/hostid 9273 9274 sethostname 9275 9276 Name 9277 9278 sethostname -- set host name 9279 9280 Synopsis 9281 9282 #include 9283 #include 9284 #include 9285 9286 int sethostname(const char *name, size_t len); 9287 9288 Description 9289 9290 If the process has appropriate privileges, the sethostname function shall 9291 change the host name for the current macine. The name shall point to a 9292 null-terminated string of at most len bytes that holds the new hostname. 9293 9294 If the symbol HOST_NAME_MAX is defined, or if sysconf(_SC_HOST_NAME_MAX) 9295 returns a value greater than 0, this value shall represent the maximum length 9296 of the new hostname. Otherwise, if the symbol MAXHOSTLEN is defined, this value 9297 shall represent the maximum length for the new hostname. If none of these 9298 values are defined, the maximum length shall be the size of the nodename field 9299 of the utsname structure. 9300 9301 Return Value 9302 9303 On success, 0 is returned. On error, -1 is returned and the global variable 9304 errno is set appropriately. 9305 9306 Errors 9307 9308 EINVAL 9309 9310 len is negative or larger than the maximum allowed size. 9311 9312 EPERM 9313 9314 the process did not have appropriate privilege. 9315 9316 EFAULT 9317 9318 name is an invalid address. 9319 9320 Rationale 9321 9322 ISO POSIX (2003) guarantees that: 9323 9324 9325 Maximum length of a host name (not including the terminating null) as 9326 returned from the gethostname function shall be at least 255 bytes. 9327 9328 The glibc C library does not currently define HOST_NAME_MAX, and although it 9329 provides the name _SC_HOST_NAME_MAX a call to sysconf returns -1 and does not 9330 alter errno in this case (indicating that there is no restriction on the 9331 hostname length). However, the glibc manual idicates that some implementations 9332 may have MAXHOSTNAMELEN as a means of detecting the maximum length, while the 9333 Linux kernel at release 2.4 and 2.6 stores this hostname in the utsname 9334 structure. While the glibc manual suggests simply shortening the name until 9335 sethostname succeeds, the LSB requires that one of the first four mechanisms 9336 works. Future versions of glibc may provide a more reasonable result from 9337 sysconf(_SC_HOST_NAME_MAX). 9338 9339 setsockopt 9340 9341 Name 9342 9343 setsockopt -- set options on sockets 9344 9345 Synopsis 9346 9347 #include 9348 #include 9349 9350 int setsockopt(int sockfd, int level, int optname, void *optval, socklen_t 9351 optlen); 9352 9353 Description 9354 9355 In addition to the setsockopt options specified in SUSv3, setsockopt also 9356 supports the options specified here. 9357 9358 The following setsockopt operations are provided for level IPPROTO_IP: 9359 9360 IP_MULTICAST_TTL 9361 9362 Set or reads the time-to-live value of outgoing multicast packets for this 9363 socket. optval is a pointer to an integer which contains the new TTL value. 9364 9365 IP_MULTICAST_LOOP 9366 9367 Sets a boolean flag indicating whether multicast packets originating 9368 locally should be looped back to the local sockets. optval is a pointer to 9369 an integer which contains the new flag value. 9370 9371 IP_ADD_MEMBERSHIP 9372 9373 Join a multicast group. optval is a pointer to a ip_mreq structure. Before 9374 calling, the caller should fill in the imr_multiaddr field with the 9375 multicast group address and the imr_address field with the address of the 9376 local interface. If imr_address is set to INADDR_ANY, then an appropriate 9377 interface is chosen by the system. 9378 9379 IP_DROP_MEMBERSHIP 9380 9381 Leave a multicast group. optval is a pointer to a ip_mreq structure 9382 containing the same values as were used with IP_ADD_MEMBERSHIP. 9383 9384 IP_MULTICAST_IF 9385 9386 Set the local device for a multicast socket. optval is a pointer to a 9387 ip_mreq structure initialized in the same manner as with IP_ADD_MEMBERSHIP. 9388 9389 The ip_mreq structure contains two struct in_addr fields: imr_multiaddr and 9390 imr_address. 9391 9392 Return Value 9393 9394 On success, 0 is returned. On error, -1 is returned and the global variable 9395 errno is set appropriately. 9396 9397 setutent 9398 9399 Name 9400 9401 setutent -- access user accounting database entries 9402 9403 Synopsis 9404 9405 #include 9406 9407 void setutent(void); 9408 9409 Description 9410 9411 The setutent function shall reset the user accounting database such that the 9412 next call to getutent shall be return the first record in the database. It is 9413 recommended to call it before any of the other functions that operate on the 9414 user accounting databases (e.g. getutent) 9415 9416 Return Value 9417 9418 None. 9419 9420 sigandset 9421 9422 Name 9423 9424 sigandset -- build a new signal set by combining the two input sets using 9425 logical AND 9426 9427 Synopsis 9428 9429 #include 9430 9431 int sigandset(sigset_t *set, const sigset_t *left, const sigset_t *right); 9432 9433 Description 9434 9435 The sigandset shall combine the two signal sets referenced by left and right, 9436 using a logical AND operation, and shall place the result in the location 9437 referenced by set, The resulting signal set shall contain only signals that are 9438 in both the set referenced by left and the set referenced by right. 9439 9440 Return Value 9441 9442 On success, sigandset shall return 0. Otherise, sigandset shall return -1 and 9443 set errno to indicate the error. 9444 9445 Errors 9446 9447 EINVAL 9448 9449 One or more of set, left, or right was a null pointer. 9450 9451 See Also 9452 9453 sigorset 9454 9455 sigblock 9456 9457 Name 9458 9459 sigblock -- manipulate the signal mask 9460 9461 Synopsis 9462 9463 #include _BSD_SOURCE 9464 #include 9465 9466 int sigblock(int mask); 9467 9468 Description 9469 9470 The sigblock function shall add the signals corresponding to the bits set in 9471 mask to the set of signals currently being blocked from delivery. 9472 9473 Return Value 9474 9475 The sigblock function shall return the previous signal mask. 9476 9477 Errors 9478 9479 None. 9480 9481 Notes 9482 9483 sigblock is made obsolete by sigprocmask(2). A future version of this 9484 specification may deprecate this function. 9485 9486 siggetmask 9487 9488 Name 9489 9490 siggetmask -- manipulate the signal mask 9491 9492 Synopsis 9493 9494 #define _BSD_SOURCE 9495 #include 9496 9497 int siggetmask(void); 9498 9499 Description 9500 9501 The siggetmask function shall return the current set of masked signals. 9502 9503 Notes 9504 9505 siggetmask is made obsolete by sigprocmask(2). 9506 9507 sigisemptyset 9508 9509 Name 9510 9511 sigisemptyset -- check for empty signal set 9512 9513 Synopsis 9514 9515 #include 9516 9517 int sigisemptyset(const sigset_t *set); 9518 9519 Description 9520 9521 The sigisemptyset function shall check for empty signal set referenced by set. 9522 9523 Return Value 9524 9525 The sigisemptyset function shall return a positive non-zero value if the signal 9526 set referenced by set is empty, or zero if this set is empty. On error, 9527 sigisemptyset shall return -1 and set errno to indicate the error. 9528 9529 Errors 9530 9531 EINVAL 9532 9533 set is a null pointer. 9534 9535 sigorset 9536 9537 Name 9538 9539 sigorset -- build a new signal set by combining the two input sets using 9540 logical OR 9541 9542 Synopsis 9543 9544 #include 9545 9546 int sigorset(sigset_t *set, const sigset_t *left, const sigset_t *right); 9547 9548 Description 9549 9550 The sigorset shall combine the two signal sets referenced by left and right, 9551 using a logical OR operation, and shall place the result in the location 9552 referenced by set, The resulting signal set shall contain only signals that are 9553 in either the set referenced by left or the set referenced by right. 9554 9555 Return Value 9556 9557 On success, sigorset shall return 0. Otherise, sigorset shall return -1 and set 9558 errno to indicate the error. 9559 9560 Errors 9561 9562 EINVAL 9563 9564 One or more of set, left, or right was a null pointer. 9565 9566 See Also 9567 9568 sigorset 9569 9570 sigreturn 9571 9572 Name 9573 9574 sigreturn -- return from signal handler and cleanup stack frame 9575 9576 Synopsis 9577 9578 int sigreturn(unsigned long __unused); 9579 9580 Description 9581 9582 The sigreturn function is used by the system to cleanup after a signal handler 9583 has returned. This function is not in the source standard; it is only in the 9584 binary standard. 9585 9586 Return Value 9587 9588 sigreturn never returns. 9589 9590 stime 9591 9592 Name 9593 9594 stime -- set time 9595 9596 Synopsis 9597 9598 #define _SVID_SOURCE 9599 #include 9600 9601 int stime(time_t *t); 9602 9603 Description 9604 9605 If the process has appropriate privilege, the stime function shall set the 9606 system's idea of the time and date. Time, referenced by t, is measured in 9607 seconds from the epoch (defined in ISO POSIX (2003) as 00:00:00 UTC January 1, 9608 1970). 9609 9610 Return Value 9611 9612 On success, stime shall return 0. Otherwise, stime shall return -1 and errno 9613 shall be set to indicate the error. 9614 9615 Errors 9616 9617 EPERM 9618 9619 The process does not have appropriate privilege. 9620 9621 EINVAL 9622 9623 t is a null pointer. 9624 9625 stpcpy 9626 9627 Name 9628 9629 stpcpy -- copy a string returning a pointer to its end 9630 9631 Synopsis 9632 9633 #include 9634 9635 char *stpcpy(char * restrict dest, const char * restrict src); 9636 9637 Description 9638 9639 The stpcpy function shall copy the string pointed to by src (including the 9640 terminating '\0' character) to the array pointed to by dest. The strings may 9641 not overlap, and the destination string dest shall be large enough to receive 9642 the copy. 9643 9644 Return Value 9645 9646 stpcpy returns a pointer to the end of the string dest (that is, the address of 9647 the terminating '\0' character) rather than the beginning. 9648 9649 Example 9650 9651 This program uses stpcpy to concatenate foo and bar to produce foobar, which it 9652 then prints. 9653 9654 #include 9655 9656 int 9657 main (void) 9658 { 9659 char buffer[256]; 9660 char *to = buffer; 9661 to = stpcpy (to, "foo"); 9662 to = stpcpy (to, "bar"); 9663 printf ("%s\n", buffer); 9664 } 9665 9666 stpncpy 9667 9668 Name 9669 9670 stpncpy -- copy a fixed-size string, returning a pointer to its end 9671 9672 Synopsis 9673 9674 #include 9675 9676 char *stpncpy(char * restrict dest, const char * restrict src, size_t n); 9677 9678 Description 9679 9680 The stpncpy function shall copy at most n characters from the string pointed to 9681 by src, including the terminating \0 character, to the array pointed to by 9682 dest. Exactly n characters are written at dest. If the length strlen(src) is 9683 smaller than n, the remaining characters in dest are filled with \0 characters. 9684 If the length strlen(src) is greater than or equal to n, dest will not be \0 9685 terminated. 9686 9687 The strings may not overlap. 9688 9689 The programmer shall ensure that there is room for at least n characters at 9690 dest. 9691 9692 Return Value 9693 9694 The stpncpy function shall return a pointer to the terminating NULL in dest, 9695 or, if dest is not NULL-terminated, dest + n. 9696 9697 strcasestr 9698 9699 Name 9700 9701 strcasestr -- locate a substring ignoring case 9702 9703 Synopsis 9704 9705 #include 9706 9707 char *strcasestr(const char *s1, const char *s2); 9708 9709 Description 9710 9711 The strcasestr shall behave as strstr, except that it shall ignore the case of 9712 both strings. The strcasestr function shall be locale aware; that is strcasestr 9713 shall behave as if both strings had been converted to lower case in the current 9714 locale before the comparison is performed. 9715 9716 Return Value 9717 9718 Upon successful completion, strcasestr shall return a pointer to the located 9719 string or a null pointer if the string is not found. If s2 points to a string 9720 with zero length, the function shall return s1. 9721 9722 strerror_r 9723 9724 Name 9725 9726 strerror_r -- reentrant version of strerror 9727 9728 Synopsis 9729 9730 #include 9731 9732 char *strerror_r(int errnum, char *buf, size_t buflen); 9733 9734 Description 9735 9736 strerror_r is a reentrant version of strerror. strerror_r returns a pointer to 9737 an error message corresponding to error number errnum. The returned pointer may 9738 point within the buffer buf (at most buflen bytes). 9739 9740 9741 Note: Note the optional use of the buffer, unlike the strerror_r found in 9742 ISO POSIX (2003), in which the message is always copied into the supplied 9743 buffer. The return types also differ. 9744 9745 9746 9747 strfry 9748 9749 Name 9750 9751 strfry -- randomize a string 9752 9753 Synopsis 9754 9755 #include 9756 9757 char *strfry(char *string); 9758 9759 Description 9760 9761 strfry randomizes the contents of string by using rand(3) to randomly swap 9762 characters in the string. The result is an anagram of string. 9763 9764 Return Value 9765 9766 strfry returns a pointer to the randomized string. 9767 9768 strndup 9769 9770 Name 9771 9772 strndup -- return a malloc'd copy of at most the specified number of bytes of a 9773 string 9774 9775 Synopsis 9776 9777 #include 9778 9779 char *strndup(const char *string, size_t n); 9780 9781 Description 9782 9783 The strndup function shall return a malloc'd copy of at most n bytes of string. 9784 The resultant string shall be terminated even if no NULL terminator appears 9785 before string+n. 9786 9787 Return Value 9788 9789 On success, strndup shall return a pointer to a newly allocated block of memory 9790 containing a copy of at most n bytes of string. Otherwise, strndup shall return 9791 NULL and set errno to indicate the error. 9792 9793 Errors 9794 9795 ENOMEM 9796 9797 Insufficient memory available. 9798 9799 strnlen 9800 9801 Name 9802 9803 strnlen -- determine the length of a fixed-size string 9804 9805 Synopsis 9806 9807 #include 9808 9809 size_t strnlen(const char *s, size_t maxlen); 9810 9811 Description 9812 9813 strnlen returns the number of characters in the string s, not including the 9814 terminating \0 character, but at most maxlen. In doing this, strnlen looks only 9815 at the first maxlen characters at s and never beyond s + maxlen. 9816 9817 Return Value 9818 9819 strnlen returns strlen(s), if that is less than maxlen, or maxlen if there is 9820 no \0 character among the first maxlen characters pointed to by s. 9821 9822 strptime 9823 9824 Name 9825 9826 strptime -- parse a time string 9827 9828 Description 9829 9830 The strptime shall behave as specified in the ISO POSIX (2003) with differences 9831 as listed below. 9832 9833 Number of leading zeroes may be limited 9834 9835 The ISO POSIX (2003) specifies fields for which "leading zeros are permitted 9836 but not required"; however, applications shall not expect to be able to supply 9837 more leading zeroes for these fields than would be implied by the range of the 9838 field. Implementations may choose to either match an input with excess leading 9839 zeroes, or treat this as a non-matching input. For example, %j has a range of 9840 001 to 366, so 0, 00, 000, 001, and 045 are acceptable inputs, but inputs such 9841 as 0000, 0366 and the like are not. 9842 9843 Rationale 9844 9845 glibc developers consider it appropriate behavior to forbid excess leading 9846 zeroes. When trying to parse a given input against several format strings, 9847 forbidding excess leading zeroes could be helpful. For example, if one matches 9848 0011-12-26 against %m-%d-%Y and then against %Y-%m-%d, it seems useful for the 9849 first match to fail, as it would be perverse to parse that date as November 12, 9850 year 26. The second pattern parses it as December 26, year 11. 9851 9852 The ISO POSIX (2003) is not explicit that an unlimited number of leading zeroes 9853 are required, although it may imply this. The LSB explicitly allows 9854 implementations to have either behavior. Future versions of this standard may 9855 require implementations to forbid excess leading zeroes. 9856 9857 An Interpretation Request is currently pending against ISO POSIX (2003) for 9858 this matter. 9859 9860 strsep 9861 9862 Name 9863 9864 strsep -- extract token from string 9865 9866 Synopsis 9867 9868 #include 9869 9870 char *strsep(char **stringp, const char *delim); 9871 9872 Description 9873 9874 The strsep function shall find the first token in the string referenced by the 9875 pointer stringp, using the characters in delim as delimiters. 9876 9877 If stringp is NULL, strsep shall return NULL and do nothing else. 9878 9879 If stringp is non-NULL, strsep shall find the first token in the string 9880 referenced by stringp, where tokens are delimited by characters in the string 9881 delim. This token shall be terminated with a \0 character by overwriting the 9882 delimiter, and stringp shall be updated to point past the token. In case no 9883 delimiter was found, the token is taken to be the entire string referenced by 9884 stringp, and the location referenced by stringp is made NULL. 9885 9886 Return Value 9887 9888 strsep shall return a pointer to the beginning of the token. 9889 9890 Notes 9891 9892 The strsep function was introduced as a replacement for strtok, since the 9893 latter cannot handle empty fields. However, strtok conforms to ISO C (1999) and 9894 to ISO POSIX (2003) and hence is more portable. 9895 9896 See Also 9897 9898 strtok, strtok_r. 9899 9900 strsignal 9901 9902 Name 9903 9904 strsignal -- return string describing signal 9905 9906 Synopsis 9907 9908 #define _GNU_SOURCE 9909 #include 9910 9911 char *strsignal(int sig); 9912 9913 extern const char * const sys_siglist[]; 9914 9915 Description 9916 9917 The strsignal function shall return a pointer to a string describing the signal 9918 number sig. The string can only be used until the next call to strsignal. 9919 9920 The array sys_siglist holds the signal description strings indexed by signal 9921 number. This array should not be accessed directly by applications. 9922 9923 Return Value 9924 9925 If sig is a valid signal number, strsignal shall return a pointer to the 9926 appropriate description string. Otherwise, strsignal shall return either a 9927 pointer to the string "unknown signal", or a null pointer. 9928 9929 Although the function is not declared as returning a pointer to a constant 9930 character string, applications shall not modify the returned string. 9931 9932 strtoq 9933 9934 Name 9935 9936 strtoq -- convert string value to a long or quad_t integer 9937 9938 Synopsis 9939 9940 #include 9941 #include 9942 #include 9943 9944 quadt strtoq(const char *nptr, char **endptr, int base); 9945 9946 Description 9947 9948 strtoq converts the string nptr to a quadt value. The conversion is done 9949 according to the given base, which shall be between 2 and 36 inclusive, or be 9950 the special value 0. 9951 9952 nptr may begin with an arbitrary amount of white space (as determined by 9953 isspace(3)), followed by a single optional + or - sign character. If base is 0 9954 or 16, the string may then include a 0x prefix, and the number will be read in 9955 base 16; otherwise, a 0 base is taken as 10 (decimal), unless the next 9956 character is 0, in which case it is taken as 8 (octal). 9957 9958 The remainder of the string is converted to a long value in the obvious manner, 9959 stopping at the first character which is not a valid digit in the given base. 9960 (In bases above 10, the letter A in either upper or lower case represents 10, B 9961 represents 11, and so forth, with Z representing 35.) 9962 9963 Return Value 9964 9965 strtoq returns the result of the conversion, unless the value would underflow 9966 or overflow. If an underflow occurs, strtoq returns QUAD_MIN. If an overflow 9967 occurs, strtoq returns QUAD_MAX. In both cases, the global variable errno is 9968 set to ERANGE. 9969 9970 Errors 9971 9972 ERANGE 9973 9974 The given string was out of range; the value converted has been clamped. 9975 9976 strtouq 9977 9978 Name 9979 9980 strtouq -- convert a string to an uquad_t 9981 9982 Synopsis 9983 9984 #include 9985 #include 9986 #include 9987 9988 uquadt strtouq(const char *nptr, char **endptr, int base); 9989 9990 Description 9991 9992 strtouq converts the string nptr to a uquadt value. The conversion is done 9993 according to the given base, which shall be between 2 and 36 inclusive, or be 9994 the special value 0. 9995 9996 nptr may begin with an arbitrary amount of white space (as determined by 9997 isspace(3)), followed by a single optional + or - sign character. If base is 0 9998 or 16, the string may then include a 0x prefix, and the number will be read in 9999 base 16; otherwise, a 0 base is taken as 10 (decimal), unless the next 10000 character is 0, in which case it is taken as 8 (octal). 10001 10002 The remainder of the string is converted to an unsigned long value in the 10003 obvious manner, stopping at the end of the string or at the first character 10004 that does not produce a valid digit in the given base. (In bases above 10, the 10005 letter A in either upper or lower case represents 10, B represents 11, and so 10006 forth, with Z representing 35.) 10007 10008 Return Value 10009 10010 On success, strtouq returns either the result of the conversion or, if there 10011 was a leading minus sign, the negation of the result of the conversion, unless 10012 the original (non-negated) value would overflow. In the case of an overflow the 10013 function returns UQUAD_MAX and the global variable errno is set to ERANGE. 10014 10015 Errors 10016 10017 ERANGE 10018 10019 The given string was out of range; the value converted has been clamped. 10020 10021 strverscmp 10022 10023 Name 10024 10025 strverscmp -- compare strings holding name and indices/version numbers 10026 10027 Synopsis 10028 10029 #include 10030 10031 int strverscmp(const char *s1, const char *s2); 10032 10033 Description 10034 10035 The strversmp function shall compare two strings in a similar manner to strcmp. 10036 If s1 and s2 contain no digits, strversmp shall behave as strcmp. 10037 10038 The strings are compared by scanning from left to right. If a digit or sequence 10039 of digits is encountered in both strings at the same position, the digit 10040 sequence is specially compared, as described below. If the digit sequences 10041 compared equal, the string comparison resumes in both s1 and s2 after the digit 10042 sequence. 10043 10044 Digit sequences are classified as either "integral" or "fractional". A 10045 fractional digit sequence begins with a '0'; otherwise the digit sequence shall 10046 be treated as an integral digit sequence. 10047 10048 If two integral digit sequences are encountered, they shall be compared as 10049 integers for equality. A fractional digit sequence shall always compare less 10050 than an integral digit sequence. If two fractional digit sequences are being 10051 compared, then if the common prefix contains only leading zeroes, the longer 10052 part shall compare less than the shorter; otherwise the comparison shall be 10053 strictly numeric. 10054 10055 Examples 10056 10057 Table 1-1. Examples 10058 10059 +-----------------------------------------------------------------------------+ 10060 | Call | Return Value | 10061 |------------------------------+----------------------------------------------| 10062 |strverscmp( "no digit", "no |0 /* same behavior as strcmp */ | 10063 |digit") | | 10064 |------------------------------+----------------------------------------------| 10065 |strverscmp( "item#99", "item# |< 0 /* same prefix, but 99 < 100 */ | 10066 |100") | | 10067 |------------------------------+----------------------------------------------| 10068 |strverscmp( "alpha1", |> 0 /* fractional part inferior to integral */| 10069 |"alpha001") | | 10070 |------------------------------+----------------------------------------------| 10071 |strverscmp( "part1_f012", |> 0 /* two fractional parts */ | 10072 |"part1_f01") | | 10073 |------------------------------+----------------------------------------------| 10074 |strverscmp( "foo.009", |< 0 /* two fractional parts but with leading | 10075 |"foo.0") |zeroes only */ | 10076 +-----------------------------------------------------------------------------+ 10077 10078 svc_register 10079 10080 Name 10081 10082 svc_register -- Register Remote Procedure Call Interface 10083 10084 Synopsis 10085 10086 #include 10087 10088 void svc_register(SVCXPRT *xprt, u_long prognum, u_long versnum, void 10089 (*dispatch)(), u_long protocol); 10090 10091 Description 10092 10093 The svc_register function shall associate the program identified by prognum at 10094 version versnum with the service dispatch procedure, dispatch. If protocol is 10095 zero, the service is not registered with the portmap service. If protocol is 10096 non-zero, then a mapping of the triple [prognum, versnum, protocol] to xprt-> 10097 xp_port is established with the local portmap service. The procedure dispatch 10098 has the following form: 10099 10100 int dispatch(struct svc_req * request, SVCXPRT * xprt); 10101 10102 Return Value 10103 10104 svc_register returns 1 if it succeeds, and zero otherwise. 10105 10106 svc_run 10107 10108 Name 10109 10110 svc_run -- Waits for RPC requests to arrive and calls service procedure. 10111 10112 Synopsis 10113 10114 #include 10115 10116 void svc_run(void); 10117 10118 Description 10119 10120 The svc_run function shall wait for RPC requests to arrive, read and unpack 10121 each request, and dispatch it to the appropriate registered handler. Under 10122 normal conditions, svc_run shall not return; it shall only return if serious 10123 errors occur that prevent further processing. 10124 10125 svc_sendreply 10126 10127 Name 10128 10129 svc_sendreply -- called by RPC service's dispatch routine 10130 10131 Synopsis 10132 10133 svc_sendreply(SVCXPRT *xprt, xdrproc_t outproc, char out); 10134 10135 Description 10136 10137 Called by an RPC service's dispatch routine to send the results of a remote 10138 procedure call. The parameter xprt is the request's associated transport 10139 handle; outproc is the XDR routine which is used to encode the results; and out 10140 is the address of the results. This routine returns one if it succeeds, zero 10141 other-wise. 10142 10143 svctcp_create 10144 10145 Name 10146 10147 svctcp_create -- Creates a TCP/IP-based RPC service transport. 10148 10149 Synopsis 10150 10151 #include 10152 10153 SVCXPRT *svctcp_create(int sock, u_int send_buf_size, u_int recv_buf_size); 10154 10155 Description 10156 10157 svctcp_create cretes a TCP/IP-based RPC service transport, to which it returns 10158 a pointer. The transport is associated with the socket sock, which may be 10159 RPC_ANYSOCK, in which case a new socket is created. If the socket is not bound 10160 to a local TCP port, ten this routine binds it to an arbitrary port. Upon 10161 completion, xprt->xp_sock is the transport's socket descriptor, and xprt-> 10162 xp_port is the transport's port number. Since TCP-based RPC uses buffered I/O, 10163 users may specify the size of buffers; values of zero choose suitable defaults. 10164 10165 Return Value 10166 10167 svctcp_create returns NULL if it fails, or a pointer to the RPC service 10168 transport otherwise. 10169 10170 svcudp_create 10171 10172 Name 10173 10174 svcudp_create -- Creates a UDP-based RPC service transport. 10175 10176 Synopsis 10177 10178 SVCXPRT * 10179 10180 svcudp_create(int sock); 10181 10182 Description 10183 10184 This call is equivalent to svcudp_bufcreate (sock, SZ, SZ) for some default 10185 size SZ. 10186 10187 system 10188 10189 Name 10190 10191 system -- execute a shell command 10192 10193 Synopsis 10194 10195 #include 10196 10197 int system(const char *string); 10198 10199 Description 10200 10201 The system function shall behave as described in ISO POSIX (2003). 10202 10203 Notes 10204 10205 The fact that system ignores interrupts is often not what a program wants. ISO 10206 POSIX (2003) describes some of the consequences; an additional consequence is 10207 that a program calling system from a loop cannot be reliably interrupted. Many 10208 programs will want to use the exec family of functions instead. 10209 10210 Do not use system from a program with suid or sgid privileges, because 10211 unexpected values for some environment variables might be used to subvert 10212 system integrity. Use the exec family of functions instead, but not execlp or 10213 execvp. system will not, in fact, work properly from programs with suid or sgid 10214 privileges on systems on which /bin/sh is bash version 2, since bash 2 drops 10215 privileges on startup. (Debian uses a modified bash which does not do this when 10216 invoked as sh.) 10217 10218 The check for the availability of /bin/sh is not actually performed; it is 10219 always assumed to be available. ISO C (1999) specifies the check, but ISO POSIX 10220 (2003) specifies that the return shall always be nonzero, since a system 10221 without the shell is not conforming, and it is this that is implemented. 10222 10223 It is possible for the shell command to return 127, so that code is not a sure 10224 indication that the execve call failed; check the global variable errno to make 10225 sure. 10226 10227 textdomain 10228 10229 Name 10230 10231 textdomain -- set the current default message domain 10232 10233 Synopsis 10234 10235 #include 10236 10237 char *textdomain(const char *domainname); 10238 10239 Description 10240 10241 The textdomain function shall set the current default message domain to 10242 domainname. Subsequent calls to gettext and ngettext use the default message 10243 domain. 10244 10245 If domainname is NULL, the default message domain shall not be altered. 10246 10247 If domainname is "", textdomain shall reset the default domain to the system 10248 default of "messages". 10249 10250 Return 10251 10252 On success, textdomain shall return the currently selected domain. Otherwise, a 10253 null pointer shall be returned, and errno set to indicate the error. 10254 10255 Errors 10256 10257 ENOMEM 10258 10259 Insufficent memory available. 10260 10261 unlink 10262 10263 Name 10264 10265 unlink -- remove a directory entry 10266 10267 Synopsis 10268 10269 int unlink(const char *path); 10270 10271 Description 10272 10273 unlink is as specified in ISO POSIX (2003), but with differences as listed 10274 below. 10275 10276 See also Additional behaviors: unlink/link on directory. 10277 10278 May return EISDIR on directories 10279 10280 If path specifies a directory, the implementation may return EISDIR instead of 10281 EPERM as specified by ISO POSIX (2003). 10282 10283 10284 Rationale: The Linux kernel has deliberately chosen EISDIR for this case 10285 and does not expect to change (Al Viro, personal communication). 10286 10287 vasprintf 10288 10289 Name 10290 10291 vasprintf -- write formatted output to a dynamically allocated string 10292 10293 Synopsis 10294 10295 #include 10296 #include 10297 10298 int vasprintf(char ** restrict ptr, const char * restrict format, va_list arg); 10299 10300 Description 10301 10302 The vasprintf function shall write formatted output to a dynamically allocated 10303 string, and store the address of that string in the location referenced by ptr. 10304 It shall behave as asprintf, except that instead of being called with a 10305 variable number of arguments, it is called with an argument list as defined by 10306 . 10307 10308 Return Value 10309 10310 Refer to fprintf. 10311 10312 Errors 10313 10314 Refer to fprintf. 10315 10316 vdprintf 10317 10318 Name 10319 10320 vdprintf -- write formatted output to a file descriptor 10321 10322 Synopsis 10323 10324 #include 10325 10326 int vdprintf(int fd, const char * restrict format, va_list arg); 10327 10328 Description 10329 10330 The vdprintf shall behave as vfprintf, except that the first argument is a file 10331 descriptor rather than a STDIO stream. 10332 10333 Return Value 10334 10335 Refer to fprintf. 10336 10337 Errors 10338 10339 Refer to fprintf. 10340 10341 verrx 10342 10343 Name 10344 10345 verrx -- display formatted error message and exit 10346 10347 Synopsis 10348 10349 #include 10350 #include 10351 10352 void verrx(int eval, const char *fmt, va_list args); 10353 10354 Description 10355 10356 The verrx shall behave as errx except that instead of being called with a 10357 variable number of arguments, it is called with an argument list as defined by 10358 . 10359 10360 verrx does not return, but exits with the value of eval. 10361 10362 Return Value 10363 10364 None. 10365 10366 Errors 10367 10368 None. 10369 10370 vsyslog 10371 10372 Name 10373 10374 vsyslog -- log to system log 10375 10376 Synopsis 10377 10378 #include 10379 #include 10380 10381 void vsyslog(int priority, char *message, va_list arglist); 10382 10383 Description 10384 10385 The vsyslog function is identical to syslog as specified in ISO POSIX (2003), 10386 except that arglist (as defined by stdarg.h) replaces the variable number of 10387 arguments. 10388 10389 wait3 10390 10391 Name 10392 10393 wait3 -- wait for child process 10394 10395 Description 10396 10397 wait3 is as specified in the SUSv2 but with differences as listed below. 10398 10399 WCONTINUED and WIFCONTINUED optional 10400 10401 Implementations need not support the functionality of WCONTINUED or 10402 WIFCONTINUED. 10403 10404 wait4 10405 10406 Name 10407 10408 wait4 -- wait for process termination, BSD style 10409 10410 Synopsis 10411 10412 #include 10413 #include 10414 #include 10415 10416 pid_t wait4(pid_t pid, int *status, int options, (struct rusage *rusage)); 10417 10418 Description 10419 10420 wait4 suspends execution of the current process until a child (as specified by 10421 pid) has exited, or until a signal is delivered whose action is to terminate 10422 the current process or to call a signal handling function. If a child (as 10423 requested by pid) has already exited by the time of the call (a so-called 10424 "zombie" process), the function returns immediately. Any system resources used 10425 by the child are freed. 10426 10427 The value of pid can be one of: 10428 10429 < -1 10430 10431 wait for any child process whose process group ID is equal to the absolute 10432 value of pid. 10433 10434 -1 10435 10436 wait for any child process; this is equivalent to calling wait3. 10437 10438 0 10439 10440 wait for any child process whose process group ID is equal to that of the 10441 calling process. 10442 10443 > 0 10444 10445 wait for the child whose process ID is equal to the value of pid. 10446 10447 The value of options is a bitwise or of zero or more of the following 10448 constants: 10449 10450 WNOHANG 10451 10452 return immediately if no child is there to be waited for. 10453 10454 WUNTRACED 10455 10456 return for children that are stopped, and whose status has not been 10457 reported. 10458 10459 If status is not NULL, wait4 stores status information in the location status. 10460 This status can be evaluated with the following macros: 10461 10462 10463 Note: These macros take the status value (an int) as an argument -- not a 10464 pointer to the value! 10465 10466 WIFEXITED(status) 10467 10468 is nonzero if the child exited normally. 10469 10470 WEXITSTATUS(status) 10471 10472 evaluates to the least significant eight bits of the return code of the 10473 child that terminated, which may have been set as the argument to a call to 10474 exit or as the argument for a return statement in the main program. This 10475 macro can only be evaluated if WIFEXITED returned nonzero. 10476 10477 WIFSIGNALED(status) 10478 10479 returns true if the child process exited because of a signal that was not 10480 caught. 10481 10482 WTERMSIG(status) 10483 10484 returns the number of the signal that caused the child process to 10485 terminate. This macro can only be evaluated if WIFSIGNALED returned 10486 nonzero. 10487 10488 WIFSTOPPED(status) 10489 10490 returns true if the child process that caused the return is currently 10491 stopped; this is only possible if the call was done using WUNTRACED. 10492 10493 WSTOPSIG(status) 10494 10495 returns the number of the signal that caused the child to stop. This macro 10496 can only be evaluated if WIFSTOPPED returned nonzero. 10497 10498 If rusage is not NULL, the struct rusage (as defined in sys/resource.h) that it 10499 points to will be filled with accounting information. (See getrusage(2) for 10500 details. 10501 10502 Return Value 10503 10504 On success, the process ID of the child that exited is returned. On error, -1 10505 is returned (in particular, when no unwaited-for child processes of the 10506 specified kind exist), or 0 if WNOHANG was used and no child was available yet. 10507 In the latter two cases, the global variable errno is set appropriately. 10508 10509 Errors 10510 10511 ECHILD 10512 10513 No unwaited-for child process as specified does exist. 10514 10515 ERESTARTSYS 10516 10517 A WNOHANG was not set and an unblocked signal or a SIGCHILD was caught. 10518 This error is returned by the system call. The library interface is not 10519 allowed to return ERESTARTSYS, but will return EINTR. 10520 10521 waitpid 10522 10523 Name 10524 10525 waitpid -- wait for child process 10526 10527 Description 10528 10529 waitpid is as specified in ISO POSIX (2003), but with differences as listed 10530 below. 10531 10532 Need not support WCONTINUED or WIFCONTINUED 10533 10534 Implementations need not support the functionality of WCONTINUED or 10535 WIFCONTINUED. 10536 10537 warn 10538 10539 Name 10540 10541 warn -- formatted error messages 10542 10543 Synopsis 10544 10545 #include 10546 10547 void warn(const char *fmt ...); 10548 10549 Description 10550 10551 The warn function shall display a formatted error message on the standard error 10552 stream. The output shall consist of the last component of the program name, a 10553 colon character, and a space character. If fmt is non-NULL, it shall be used as 10554 a format string for the printf family of functions, and the formatted message, 10555 a colon character, and a space are written to stderr. Finally, the error 10556 message string affiliated with the current value of the global variable errno 10557 shall be written to stderr, followed by a newline character. 10558 10559 Return Value 10560 10561 None. 10562 10563 Errors 10564 10565 None. 10566 10567 warnx 10568 10569 Name 10570 10571 warnx -- formatted error messages 10572 10573 Synopsis 10574 10575 #include 10576 10577 void warnx(const char *fmt ...); 10578 10579 Description 10580 10581 The warnx function shall display a formatted error message on the standard 10582 error stream. The last component of the program name, a colon character, and a 10583 space shall be output. If fmt is non-NULL, it shall be used as the format 10584 string for the printf family of functions, and the formatted error message, a 10585 colon character, and a space shall be output. The output shall be followed by a 10586 newline character. 10587 10588 Return Value 10589 10590 None. 10591 10592 Errors 10593 10594 None. 10595 10596 wcpcpy 10597 10598 Name 10599 10600 wcpcpy -- copy a wide character string, returning a pointer to its end 10601 10602 Synopsis 10603 10604 #include 10605 10606 wchar_t *wcpcpy(wchar_t *dest, const wchar_t *src); 10607 10608 Description 10609 10610 wcpcpy is the wide-character equivalent of stpcpy. It copies the wide character 10611 string src, including the terminating L'\0' character, to the array dest. 10612 10613 The strings may not overlap. 10614 10615 The programmer shall ensure that there is room for at least wcslen(src)+1 wide 10616 characters at dest. 10617 10618 Return Value 10619 10620 wcpcpy returns a pointer to the end of the wide-character string dest, that is, 10621 a pointer to the terminating L'\0' character. 10622 10623 wcpncpy 10624 10625 Name 10626 10627 wcpncpy -- copy a fixed-size string of wide characters, returning a pointer to 10628 its end 10629 10630 Synopsis 10631 10632 #include 10633 10634 wchar_t *wcpncpy(wchar_t *dest, const wchar_t *src, size_t n); 10635 10636 Description 10637 10638 wcpncpy is the wide-character equivalent of stpncpy. It copies at most n wide 10639 characters from the wide-character string src, including the terminating L'\0' 10640 character, to the array dest. Exactly n wide characters are written at dest. If 10641 the length wcslen(src) is smaller than n, the remaining wide characters in the 10642 array dest are filled with L'\0' characters. If the length wcslen(src) is 10643 greater than or equal to n, the string dest will not be L'\0' terminated. 10644 10645 The strings may not overlap. 10646 10647 The programmer shall ensure that there is room for at least n wide characters 10648 at dest. 10649 10650 Return Value 10651 10652 wcpncpy returns a pointer to the wide character one past the last non-null wide 10653 character written. 10654 10655 wcscasecmp 10656 10657 Name 10658 10659 wcscasecmp -- compare two wide-character strings, ignoring case 10660 10661 Synopsis 10662 10663 #include 10664 10665 int wcscasecmp(const wchar_t *s1, const wchar_t *s2); 10666 10667 Description 10668 10669 wcscasecmp is the wide-character equivalent of strcasecmp. It compares the 10670 wide-character string s1 and the wide-character string s2, ignoring case 10671 differences (towupper, towlower). 10672 10673 Return Value 10674 10675 wcscasecmp returns 0 if the wide-character strings s1 and s2 are equal except 10676 for case distinctions. It returns a positive integer if s1 is greater than s2, 10677 ignoring case. It returns a negative integer if s1 is smaller than s2, ignoring 10678 case. 10679 10680 Notes 10681 10682 The behavior of wcscasecmp depends upon the LC_CTYPE category of the current 10683 locale. 10684 10685 wcsdup 10686 10687 Name 10688 10689 wcsdup -- duplicate a wide-character string 10690 10691 Synopsis 10692 10693 #include 10694 10695 wchar_t *wcsdup(const wchar_t *s); 10696 10697 Description 10698 10699 wcsdup is the wide-character equivalent of strdup. It allocates and returns a 10700 new wide-character string whose initial contents is a duplicate of the 10701 wide-character string s. 10702 10703 Memory for the new wide-character string is obtained with malloc(3), and can be 10704 freed with free(3). 10705 10706 Return Value 10707 10708 wcsdup returns a pointer to the new wide-character string, or NULL if 10709 sufficient memory was not available. 10710 10711 wcsncasecmp 10712 10713 Name 10714 10715 wcsncasecmp -- compare two fixed-size wide-character strings, ignoring case 10716 10717 Synopsis 10718 10719 #include 10720 10721 int wcsncasecmp(const wchar_t *s1, const wchar_t *s2, size_t n); 10722 10723 Description 10724 10725 wcsncasecmp is the wide-character equivalent of strncasecmp. It compares the 10726 wide-character string s1 and the wide-character string s2, but at most n wide 10727 characters from each string, ignoring case differences (towupper, towlower). 10728 10729 Return Value 10730 10731 wcscasecmp returns 0 if the wide-character strings s1 and s2, truncated to at 10732 most length n, are equal except for case distinctions. It returns a positive 10733 integer if truncated s1 is greater than truncated s2, ignoring case. It returns 10734 a negative integer if truncated s1 is smaller than truncated s2, ignoring case. 10735 10736 Notes 10737 10738 The behavior of wcsncasecmp depends upon the LC_CTYPE category of the current 10739 locale. 10740 10741 wcsnlen 10742 10743 Name 10744 10745 wcsnlen -- determine the length of a fixed-size wide-character string 10746 10747 Synopsis 10748 10749 #include 10750 10751 size_t wcsnlen(const wchar_t *s, size_t maxlen); 10752 10753 Description 10754 10755 wcsnlen is the wide-character equivalent of strnlen. It returns the number of 10756 wide-characters in the string s, not including the terminating L'\0' character, 10757 but at most maxlen. In doing this, wcsnlen looks only at the first maxlen 10758 wide-characters at s and never beyond s + maxlen. 10759 10760 Return Value 10761 10762 wcsnlen returns wcslen(s) if that is less than maxlen, or maxlen if there is no 10763 L'\0' character among the first maxlen wide characters pointed to by s. 10764 10765 Notes 10766 10767 The behavior of wcsncasecmp depends on the LC_CTYPE category of the current 10768 locale. 10769 10770 wcsnrtombs 10771 10772 Name 10773 10774 wcsnrtombs -- convert a wide character string to a multi-byte string 10775 10776 Synopsis 10777 10778 #include 10779 10780 size_t wcsnrtombs(char *dest, const wchar_t **src, size_t nwc, size_t len, 10781 mbstate_t *ps); 10782 10783 Description 10784 10785 wcsnrtombs is like wcsrtombs, except that the number of wide characters to be 10786 converted, starting at src, is limited to nwc. 10787 10788 If dest is not a NULL pointer, wcsnrtombs converts at most nwc wide characters 10789 from the wide-character string src to a multibyte string starting at dest. At 10790 most len bytes are written to dest. The state ps is updated. 10791 10792 The conversion is effectively performed by repeatedly calling: 10793 10794 wcrtomb(dest, *src, ps) 10795 10796 as long as this call succeeds, and then incrementing dest by the number of 10797 bytes written and src by 1. 10798 10799 The conversion can stop for three reasons: 10800 10801 * A wide character has been encountered that cannot be represented as a 10802 multibyte sequence (according to the current locale). In this case src is 10803 left pointing to the invalid wide character, (size_t)(-1) is returned, and 10804 errno is set to EILSEQ. 10805 10806 * nws wide characters have been converted without encountering a L'\0', or 10807 the length limit forces a stop. In this case, src is left pointing to the 10808 next wide character to be converted, and the number bytes written to dest 10809 is returned. 10810 10811 * The wide-character string has been completely converted, including the 10812 terminating L'\0' (which has the side effect of bringing back ps to the 10813 initial state). In this case, src is set to NULL, and the number of bytes 10814 written to dest, excluding the terminating L'\0' byte, is returned. 10815 10816 If dest is NULL, len is ignored, and the conversion proceeds as above, except 10817 that the converted bytes are not written out to memory, and that no destination 10818 length limit exists. 10819 10820 In both of the above cases, if ps is a NULL pointer, a static anonymous state 10821 only known to wcsnrtombs is used instead. 10822 10823 The programmer shall ensure that there is room for at least len bytes at dest. 10824 10825 Return Value 10826 10827 wcsnrtombs returns the number of bytes that make up the converted part of 10828 multibyte sequence, not including the terminating L'\0' byte. If a wide 10829 character was encountered which could not be converted, (size_t)(-1) is 10830 returned, and the global variable errno set to EILSEQ. 10831 10832 Notes 10833 10834 The behavior of wcsnrtombs depends on the LC_CTYPE category of the current 10835 locale. 10836 10837 Passing NULL as ps is not multi-thread safe. 10838 10839 wcstoq 10840 10841 Name 10842 10843 wcstoq -- convert wide string to long long int representation 10844 10845 Synopsis 10846 10847 #include 10848 10849 long long int wcstoq(const wchar_t * restrict nptr, wchar_t ** restrict endptr, 10850 int base); 10851 10852 Description 10853 10854 The wcstoq function shall convert the initial portion of the wide string nptr 10855 to long long int representation. It is identical to wcstoll. 10856 10857 Return Value 10858 10859 Refer to wcstoll. 10860 10861 Errors 10862 10863 Refer to wcstoll. 10864 10865 wcstouq 10866 10867 Name 10868 10869 wcstouq -- convert wide string to unsigned long long int representation 10870 10871 Synopsis 10872 10873 #include 10874 10875 unsigned long long int wcstouq(const wchar_t * restrict nptr, wchar_t ** 10876 restrict endptr, int base); 10877 10878 Description 10879 10880 The wcstouq function shall convert the initial portion of the wide string nptr 10881 to unsigned long long int representation. It is identical to wcstoull. 10882 10883 Return Value 10884 10885 Refer to wcstoull. 10886 10887 Errors 10888 10889 Refer to wcstoull. 10890 10891 xdr_u_int 10892 10893 Name 10894 10895 xdr_u_int -- library routines for external data representation 10896 10897 Synopsis 10898 10899 int xdr_u_int(XDR * xdrs, unsigned int * up); 10900 10901 Description 10902 10903 xdr_u_int is a filter primitive that translates between C unsigned integers and 10904 their external representations. 10905 10906 Return Value 10907 10908 On success, 1 is returned. On error, 0 is returned. 10909 10910 ------------------------------------------------------------------------------- 10911 10912 Interfaces for libm 10913 10914 Table 1-29 defines the library name and shared object name for the libm library 10915 10916 Table 1-29. libm Definition 10917 10918 +----------------------+ 10919 |Library:|libm | 10920 |--------+-------------| 10921 |SONAME: |See archLSB. | 10922 +----------------------+ 10923 10924 The behavior of the interfaces in this library is specified by the following 10925 specifications: 10926 10927 ISO C (1999) 10928 SUSv2 10929 ISO POSIX (2003) 10930 10931 ------------------------------------------------------------------------------- 10932 10933 Math 10934 10935 ------------------------------------------------------------------------------- 10936 10937 Interfaces for Math 10938 10939 An LSB conforming implementation shall provide the generic functions for Math 10940 specified in Table 1-30, with the full functionality as described in the 10941 referenced underlying specification. 10942 10943 Table 1-30. libm - Math Function Interfaces 10944 10945 +-----------------------------------------------------------------------------+ 10946 |acos [1] |cexp [1] |expf [1] |jnf [2] |remquof [1] | 10947 |-----------+-------------+------------------+---------------+----------------| 10948 |acosf [1] |cexpf [1] |expl [1] |jnl [2] |remquol [1] | 10949 |-----------+-------------+------------------+---------------+----------------| 10950 |acosh [1] |cexpl [1] |expm1 [1] |ldexp [1] |rint [1] | 10951 |-----------+-------------+------------------+---------------+----------------| 10952 |acoshf [1] |cimag [1] |fabs [1] |ldexpf [1] |rintf [1] | 10953 |-----------+-------------+------------------+---------------+----------------| 10954 |acoshl [1] |cimagf [1] |fabsf [1] |ldexpl [1] |rintl [1] | 10955 |-----------+-------------+------------------+---------------+----------------| 10956 |acosl [1] |cimagl [1] |fabsl [1] |lgamma [1] |round [1] | 10957 |-----------+-------------+------------------+---------------+----------------| 10958 |asin [1] |clog [1] |fdim [1] |lgamma_r [2] |roundf [1] | 10959 |-----------+-------------+------------------+---------------+----------------| 10960 |asinf [1] |clog10 [2] |fdimf [1] |lgammaf [1] |roundl [1] | 10961 |-----------+-------------+------------------+---------------+----------------| 10962 |asinh [1] |clog10f [2] |fdiml [1] |lgammaf_r [2] |scalb [1] | 10963 |-----------+-------------+------------------+---------------+----------------| 10964 |asinhf [1] |clog10l [2] |feclearexcept [1] |lgammal [1] |scalbf [2] | 10965 |-----------+-------------+------------------+---------------+----------------| 10966 |asinhl [1] |clogf [1] |fegetenv [1] |lgammal_r [2] |scalbl [2] | 10967 |-----------+-------------+------------------+---------------+----------------| 10968 |asinl [1] |clogl [1] |fegetexceptflag |llrint [1] |scalbln [1] | 10969 | | |[1] | | | 10970 |-----------+-------------+------------------+---------------+----------------| 10971 |atan [1] |conj [1] |fegetround [1] |llrintf [1] |scalblnf [1] | 10972 |-----------+-------------+------------------+---------------+----------------| 10973 |atan2 [1] |conjf [1] |feholdexcept [1] |llrintl [1] |scalblnl [1] | 10974 |-----------+-------------+------------------+---------------+----------------| 10975 |atan2f [1] |conjl [1] |feraiseexcept [1] |llround [1] |scalbn [1] | 10976 |-----------+-------------+------------------+---------------+----------------| 10977 |atan2l [1] |copysign [1] |fesetenv [1] |llroundf [1] |scalbnf [1] | 10978 |-----------+-------------+------------------+---------------+----------------| 10979 |atanf [1] |copysignf [1]|fesetexceptflag |llroundl [1] |scalbnl [1] | 10980 | | |[1] | | | 10981 |-----------+-------------+------------------+---------------+----------------| 10982 |atanh [1] |copysignl [1]|fesetround [1] |log [1] |significand [2] | 10983 |-----------+-------------+------------------+---------------+----------------| 10984 |atanhf [1] |cos [1] |fetestexcept [1] |log10 [1] |significandf [2]| 10985 |-----------+-------------+------------------+---------------+----------------| 10986 |atanhl [1] |cosf [1] |feupdateenv [1] |log10f [1] |significandl [2]| 10987 |-----------+-------------+------------------+---------------+----------------| 10988 |atanl [1] |cosh [1] |finite [3] |log10l [1] |sin [1] | 10989 |-----------+-------------+------------------+---------------+----------------| 10990 |cabs [1] |coshf [1] |finitef [2] |log1p [1] |sincos [2] | 10991 |-----------+-------------+------------------+---------------+----------------| 10992 |cabsf [1] |coshl [1] |finitel [2] |logb [1] |sincosf [2] | 10993 |-----------+-------------+------------------+---------------+----------------| 10994 |cabsl [1] |cosl [1] |floor [1] |logf [1] |sincosl [2] | 10995 |-----------+-------------+------------------+---------------+----------------| 10996 |cacos [1] |cpow [1] |floorf [1] |logl [1] |sinf [1] | 10997 |-----------+-------------+------------------+---------------+----------------| 10998 |cacosf [1] |cpowf [1] |floorl [1] |lrint [1] |sinh [1] | 10999 |-----------+-------------+------------------+---------------+----------------| 11000 |cacosh [1] |cpowl [1] |fma [1] |lrintf [1] |sinhf [1] | 11001 |-----------+-------------+------------------+---------------+----------------| 11002 |cacoshf [1]|cproj [1] |fmaf [1] |lrintl [1] |sinhl [1] | 11003 |-----------+-------------+------------------+---------------+----------------| 11004 |cacoshl [1]|cprojf [1] |fmal [1] |lround [1] |sinl [1] | 11005 |-----------+-------------+------------------+---------------+----------------| 11006 |cacosl [1] |cprojl [1] |fmax [1] |lroundf [1] |sqrt [1] | 11007 |-----------+-------------+------------------+---------------+----------------| 11008 |carg [1] |creal [1] |fmaxf [1] |lroundl [1] |sqrtf [1] | 11009 |-----------+-------------+------------------+---------------+----------------| 11010 |cargf [1] |crealf [1] |fmaxl [1] |matherr [2] |sqrtl [1] | 11011 |-----------+-------------+------------------+---------------+----------------| 11012 |cargl [1] |creall [1] |fmin [1] |modf [1] |tan [1] | 11013 |-----------+-------------+------------------+---------------+----------------| 11014 |casin [1] |csin [1] |fminf [1] |modff [1] |tanf [1] | 11015 |-----------+-------------+------------------+---------------+----------------| 11016 |casinf [1] |csinf [1] |fminl [1] |modfl [1] |tanh [1] | 11017 |-----------+-------------+------------------+---------------+----------------| 11018 |casinh [1] |csinh [1] |fmod [1] |nan [1] |tanhf [1] | 11019 |-----------+-------------+------------------+---------------+----------------| 11020 |casinhf [1]|csinhf [1] |fmodf [1] |nanf [1] |tanhl [1] | 11021 |-----------+-------------+------------------+---------------+----------------| 11022 |casinhl [1]|csinhl [1] |fmodl [1] |nanl [1] |tanl [1] | 11023 |-----------+-------------+------------------+---------------+----------------| 11024 |casinl [1] |csinl [1] |frexp [1] |nearbyint [1] |tgamma [1] | 11025 |-----------+-------------+------------------+---------------+----------------| 11026 |catan [1] |csqrt [1] |frexpf [1] |nearbyintf [1] |tgammaf [1] | 11027 |-----------+-------------+------------------+---------------+----------------| 11028 |catanf [1] |csqrtf [1] |frexpl [1] |nearbyintl [1] |tgammal [1] | 11029 |-----------+-------------+------------------+---------------+----------------| 11030 |catanh [1] |csqrtl [1] |gamma [3] |nextafter [1] |trunc [1] | 11031 |-----------+-------------+------------------+---------------+----------------| 11032 |catanhf [1]|ctan [1] |gammaf [2] |nextafterf [1] |truncf [1] | 11033 |-----------+-------------+------------------+---------------+----------------| 11034 |catanhl [1]|ctanf [1] |gammal [2] |nextafterl [1] |truncl [1] | 11035 |-----------+-------------+------------------+---------------+----------------| 11036 |catanl [1] |ctanh [1] |hypot [1] |nexttoward [1] |y0 [1] | 11037 |-----------+-------------+------------------+---------------+----------------| 11038 |cbrt [1] |ctanhf [1] |hypotf [1] |nexttowardf [1]|y0f [2] | 11039 |-----------+-------------+------------------+---------------+----------------| 11040 |cbrtf [1] |ctanhl [1] |hypotl [1] |nexttowardl [1]|y0l [2] | 11041 |-----------+-------------+------------------+---------------+----------------| 11042 |cbrtl [1] |ctanl [1] |ilogb [1] |pow [1] |y1 [1] | 11043 |-----------+-------------+------------------+---------------+----------------| 11044 |ccos [1] |dremf [2] |ilogbf [1] |pow10 [2] |y1f [2] | 11045 |-----------+-------------+------------------+---------------+----------------| 11046 |ccosf [1] |dreml [2] |ilogbl [1] |pow10f [2] |y1l [2] | 11047 |-----------+-------------+------------------+---------------+----------------| 11048 |ccosh [1] |erf [1] |j0 [1] |pow10l [2] |yn [1] | 11049 |-----------+-------------+------------------+---------------+----------------| 11050 |ccoshf [1] |erfc [1] |j0f [2] |powf [1] |ynf [2] | 11051 |-----------+-------------+------------------+---------------+----------------| 11052 |ccoshl [1] |erfcf [1] |j0l [2] |powl [1] |ynl [2] | 11053 |-----------+-------------+------------------+---------------+----------------| 11054 |ccosl [1] |erfcl [1] |j1 [1] |remainder [1] | | 11055 |-----------+-------------+------------------+---------------+----------------| 11056 |ceil [1] |erff [1] |j1f [2] |remainderf [1] | | 11057 |-----------+-------------+------------------+---------------+----------------| 11058 |ceilf [1] |erfl [1] |j1l [2] |remainderl [1] | | 11059 |-----------+-------------+------------------+---------------+----------------| 11060 |ceill [1] |exp [1] |jn [1] |remquo [1] | | 11061 +-----------------------------------------------------------------------------+ 11062 11063 Referenced Specification(s) 11064 11065 [1]. ISO POSIX (2003) 11066 11067 [2]. ISO C (1999) 11068 11069 [3]. SUSv2 11070 11071 An LSB conforming implementation shall provide the generic data interfaces for 11072 Math specified in Table 1-31, with the full functionality as described in the 11073 referenced underlying specification. 11074 11075 Table 1-31. libm - Math Data Interfaces 11076 11077 +--------------------+ 11078 |signgam [1] | | | | | 11079 +--------------------+ 11080 11081 Referenced Specification(s) 11082 11083 [1]. ISO POSIX (2003) 11084 11085 ------------------------------------------------------------------------------- 11086 11087 Data Definitions for libm 11088 11089 This section defines global identifiers and their values that are associated 11090 with interfaces contained in libm. These definitions are organized into groups 11091 that correspond to system headers. This convention is used as a convenience for 11092 the reader, and does not imply the existence of these headers, or their 11093 content. 11094 11095 These definitions are intended to supplement those provided in the referenced 11096 underlying specifications. 11097 11098 This specification uses ISO/IEC 9899 C Language as the reference programming 11099 language, and data definitions are specified in ISO C format. The C language is 11100 used here as a convenient notation. Using a C language description of these 11101 data objects does not preclude their use by other programming languages. 11102 11103 ------------------------------------------------------------------------------- 11104 11105 complex.h 11106 11107 #define complex _Complex 11108 11109 ------------------------------------------------------------------------------- 11110 11111 math.h 11112 11113 #define DOMAIN 1 11114 #define SING 2 11115 11116 struct exception 11117 { 11118 int type; 11119 char *name; 11120 double arg1; 11121 double arg2; 11122 double retval; 11123 } 11124 ; 11125 #define isinf(x) (sizeof (x) == sizeof (float) ? __isinff (x): sizeof (x) == sizeof (double) ? __isinf (x) : __isinfl (x)) 11126 #define isnan(x) (sizeof (x) == sizeof (float) ? __isnanf (x) : sizeof (x) == sizeof (double) ? __isnan (x) : __isnanl (x)) 11127 11128 #define HUGE_VAL 0x1.0p2047 11129 #define HUGE_VALF 0x1.0p255f 11130 #define HUGE_VALL 0x1.0p32767L 11131 11132 #define NAN ((float)0x7fc00000UL) 11133 #define M_1_PI 0.31830988618379067154 11134 #define M_LOG10E 0.43429448190325182765 11135 #define M_2_PI 0.63661977236758134308 11136 #define M_LN2 0.69314718055994530942 11137 #define M_SQRT1_2 0.70710678118654752440 11138 #define M_PI_4 0.78539816339744830962 11139 #define M_2_SQRTPI 1.12837916709551257390 11140 #define M_SQRT2 1.41421356237309504880 11141 #define M_LOG2E 1.4426950408889634074 11142 #define M_PI_2 1.57079632679489661923 11143 #define M_LN10 2.30258509299404568402 11144 #define M_E 2.7182818284590452354 11145 #define M_PI 3.14159265358979323846 11146 #define INFINITY HUGE_VALF 11147 11148 #define MATH_ERRNO 1 11149 #define MATH_ERREXCEPT 2 11150 11151 ------------------------------------------------------------------------------- 11152 11153 Interfaces for libpthread 11154 11155 Table 1-32 defines the library name and shared object name for the libpthread 11156 library 11157 11158 Table 1-32. libpthread Definition 11159 11160 +-------------------------+ 11161 |Library:|libpthread | 11162 |--------+----------------| 11163 |SONAME: |libpthread.so.0 | 11164 +-------------------------+ 11165 11166 The behavior of the interfaces in this library is specified by the following 11167 specifications: 11168 11169 Large File Support 11170 this specification 11171 ISO POSIX (2003) 11172 11173 ------------------------------------------------------------------------------- 11174 11175 Realtime Threads 11176 11177 ------------------------------------------------------------------------------- 11178 11179 Interfaces for Realtime Threads 11180 11181 No external functions are defined for libpthread - Realtime Threads 11182 11183 ------------------------------------------------------------------------------- 11184 11185 Advanced Realtime Threads 11186 11187 ------------------------------------------------------------------------------- 11188 11189 Interfaces for Advanced Realtime Threads 11190 11191 No external functions are defined for libpthread - Advanced Realtime Threads 11192 11193 ------------------------------------------------------------------------------- 11194 11195 Posix Threads 11196 11197 ------------------------------------------------------------------------------- 11198 11199 Interfaces for Posix Threads 11200 11201 An LSB conforming implementation shall provide the generic functions for Posix 11202 Threads specified in Table 1-33, with the full functionality as described in 11203 the referenced underlying specification. 11204 11205 Table 1-33. libpthread - Posix Threads Function Interfaces 11206 11207 +-----------------------------------------------------------------------------------------------------------------------------------------+ 11208 |_pthread_cleanup_pop [1] |pthread_cancel [2] |pthread_join [2] |pthread_rwlock_destroy [2] |pthread_setconcurrency| 11209 | | | | |[2] | 11210 |---------------------------+---------------------------+----------------------------+-----------------------------+----------------------| 11211 |_pthread_cleanup_push [1] |pthread_cond_broadcast [2] |pthread_key_create [2] |pthread_rwlock_init [2] |pthread_setspecific | 11212 | | | | |[2] | 11213 |---------------------------+---------------------------+----------------------------+-----------------------------+----------------------| 11214 |pread [2] |pthread_cond_destroy [2] |pthread_key_delete [2] |pthread_rwlock_rdlock [2] |pthread_sigmask [2] | 11215 |---------------------------+---------------------------+----------------------------+-----------------------------+----------------------| 11216 |pread64 [3] |pthread_cond_init [2] |pthread_kill [2] |pthread_rwlock_timedrdlock |pthread_testcancel [2]| 11217 | | | |[2] | | 11218 |---------------------------+---------------------------+----------------------------+-----------------------------+----------------------| 11219 |pthread_attr_destroy [2] |pthread_cond_signal [2] |pthread_mutex_destroy [2] |pthread_rwlock_timedwrlock |pwrite [2] | 11220 | | | |[2] | | 11221 |---------------------------+---------------------------+----------------------------+-----------------------------+----------------------| 11222 |pthread_attr_getdetachstate|pthread_cond_timedwait [2] |pthread_mutex_init [2] |pthread_rwlock_tryrdlock [2] |pwrite64 [3] | 11223 |[2] | | | | | 11224 |---------------------------+---------------------------+----------------------------+-----------------------------+----------------------| 11225 |pthread_attr_getguardsize |pthread_cond_wait [2] |pthread_mutex_lock [2] |pthread_rwlock_trywrlock [2] |sem_close [2] | 11226 |[2] | | | | | 11227 |---------------------------+---------------------------+----------------------------+-----------------------------+----------------------| 11228 |pthread_attr_getschedparam |pthread_condattr_destroy |pthread_mutex_trylock [2] |pthread_rwlock_unlock [2] |sem_destroy [2] | 11229 |[2] |[2] | | | | 11230 |---------------------------+---------------------------+----------------------------+-----------------------------+----------------------| 11231 |pthread_attr_getstackaddr |pthread_condattr_getpshared|pthread_mutex_unlock [2] |pthread_rwlock_wrlock [2] |sem_getvalue [2] | 11232 |[2] |[2] | | | | 11233 |---------------------------+---------------------------+----------------------------+-----------------------------+----------------------| 11234 |pthread_attr_getstacksize |pthread_condattr_init [2] |pthread_mutexattr_destroy |pthread_rwlockattr_destroy |sem_init [2] | 11235 |[2] | |[2] |[2] | | 11236 |---------------------------+---------------------------+----------------------------+-----------------------------+----------------------| 11237 |pthread_attr_init [2] |pthread_condattr_setpshared|pthread_mutexattr_getpshared|pthread_rwlockattr_getpshared|sem_open [2] | 11238 | |[2] |[2] |[2] | | 11239 |---------------------------+---------------------------+----------------------------+-----------------------------+----------------------| 11240 |pthread_attr_setdetachstate|pthread_create [2] |pthread_mutexattr_gettype |pthread_rwlockattr_init [2] |sem_post [2] | 11241 |[2] | |[2] | | | 11242 |---------------------------+---------------------------+----------------------------+-----------------------------+----------------------| 11243 |pthread_attr_setguardsize |pthread_detach [2] |pthread_mutexattr_init [2] |pthread_rwlockattr_setpshared|sem_timedwait [2] | 11244 |[2] | | |[2] | | 11245 |---------------------------+---------------------------+----------------------------+-----------------------------+----------------------| 11246 |pthread_attr_setschedparam |pthread_equal [2] |pthread_mutexattr_setpshared|pthread_self [2] |sem_trywait [2] | 11247 |[2] | |[2] | | | 11248 |---------------------------+---------------------------+----------------------------+-----------------------------+----------------------| 11249 |pthread_attr_setstackaddr |pthread_exit [2] |pthread_mutexattr_settype |pthread_setcancelstate [2] |sem_unlink [2] | 11250 |[2] | |[2] | | | 11251 |---------------------------+---------------------------+----------------------------+-----------------------------+----------------------| 11252 |pthread_attr_setstacksize |pthread_getspecific [2] |pthread_once [2] |pthread_setcanceltype [2] |sem_wait [2] | 11253 |[2] | | | | | 11254 +-----------------------------------------------------------------------------------------------------------------------------------------+ 11255 11256 Referenced Specification(s) 11257 11258 [1]. this specification 11259 11260 [2]. ISO POSIX (2003) 11261 11262 [3]. Large File Support 11263 11264 ------------------------------------------------------------------------------- 11265 11266 Data Definitions for libpthread 11267 11268 This section defines global identifiers and their values that are associated 11269 with interfaces contained in libpthread. These definitions are organized into 11270 groups that correspond to system headers. This convention is used as a 11271 convenience for the reader, and does not imply the existence of these headers, 11272 or their content. 11273 11274 These definitions are intended to supplement those provided in the referenced 11275 underlying specifications. 11276 11277 This specification uses ISO/IEC 9899 C Language as the reference programming 11278 language, and data definitions are specified in ISO C format. The C language is 11279 used here as a convenient notation. Using a C language description of these 11280 data objects does not preclude their use by other programming languages. 11281 11282 ------------------------------------------------------------------------------- 11283 11284 pthread.h 11285 11286 #define PTHREAD_MUTEX_DEFAULT 1 11287 #define PTHREAD_MUTEX_NORMAL 1 11288 #define PTHREAD_MUTEX_TIMED_NP 1 11289 #define PTHREAD_MUTEX_RECURSIVE 2 11290 #define PTHREAD_RWLOCK_DEFAULT_NP 2 11291 #define PTHREAD_MUTEX_ERRORCHECK 3 11292 #define pthread_cleanup_pop(execute) _pthread_cleanup_pop(& _buffer,(execute));} 11293 #define __LOCK_INITIALIZER { 0, 0 } 11294 #define PTHREAD_RWLOCK_INITIALIZER { __LOCK_INITIALIZER, 0, NULL, NULL, NULL,PTHREAD_RWLOCK_DEFAULT_NP, PTHREAD_PROCESS_PRIVATE } 11295 #define PTHREAD_MUTEX_INITIALIZER {0,0,0,PTHREAD_MUTEX_TIMED_NP,__LOCK_INITIALIZER} 11296 #define pthread_cleanup_push(routine,arg) {struct _pthread_cleanup_buffer _buffer;_pthread_cleanup_push(& _buffer,(routine),(arg)); 11297 #define PTHREAD_COND_INITIALIZER {__LOCK_INITIALIZER,0} 11298 11299 struct _pthread_cleanup_buffer 11300 { 11301 void (*__routine) (void *); 11302 void *__arg; 11303 int __canceltype; 11304 struct _pthread_cleanup_buffer *__prev; 11305 } 11306 ; 11307 typedef unsigned int pthread_key_t; 11308 typedef int pthread_once_t; 11309 typedef long long __pthread_cond_align_t; 11310 11311 typedef unsigned long pthread_t; 11312 struct _pthread_fastlock 11313 { 11314 long __status; 11315 int __spinlock; 11316 } 11317 ; 11318 11319 typedef struct _pthread_descr_struct *_pthread_descr; 11320 11321 typedef struct 11322 { 11323 int __m_reserved; 11324 int __m_count; 11325 _pthread_descr __m_owner; 11326 int __m_kind; 11327 struct _pthread_fastlock __m_lock; 11328 } 11329 pthread_mutex_t; 11330 typedef struct 11331 { 11332 int __mutexkind; 11333 } 11334 pthread_mutexattr_t; 11335 11336 typedef struct 11337 { 11338 int __detachstate; 11339 int __schedpolicy; 11340 struct sched_param __schedparam; 11341 int __inheritsched; 11342 int __scope; 11343 size_t __guardsize; 11344 int __stackaddr_set; 11345 void *__stackaddr; 11346 unsigned long __stacksize; 11347 } 11348 pthread_attr_t; 11349 11350 typedef struct 11351 { 11352 struct _pthread_fastlock __c_lock; 11353 _pthread_descr __c_waiting; 11354 char __padding[48 - sizeof (struct _pthread_fastlock) - 11355 sizeof (_pthread_descr) - sizeof (__pthread_cond_align_t)]; 11356 __pthread_cond_align_t __align; 11357 } 11358 pthread_cond_t; 11359 typedef struct 11360 { 11361 int __dummy; 11362 } 11363 pthread_condattr_t; 11364 11365 typedef struct _pthread_rwlock_t 11366 { 11367 struct _pthread_fastlock __rw_lock; 11368 int __rw_readers; 11369 _pthread_descr __rw_writer; 11370 _pthread_descr __rw_read_waiting; 11371 _pthread_descr __rw_write_waiting; 11372 int __rw_kind; 11373 int __rw_pshared; 11374 } 11375 pthread_rwlock_t; 11376 typedef struct 11377 { 11378 int __lockkind; 11379 int __pshared; 11380 } 11381 pthread_rwlockattr_t; 11382 11383 #define PTHREAD_CREATE_JOINABLE 0 11384 #define PTHREAD_INHERIT_SCHED 0 11385 #define PTHREAD_ONCE_INIT 0 11386 #define PTHREAD_PROCESS_PRIVATE 0 11387 #define PTHREAD_CREATE_DETACHED 1 11388 #define PTHREAD_EXPLICIT_SCHED 1 11389 #define PTHREAD_PROCESS_SHARED 1 11390 11391 #define PTHREAD_CANCELED ((void*)-1) 11392 #define PTHREAD_CANCEL_DEFERRED 0 11393 #define PTHREAD_CANCEL_ENABLE 0 11394 #define PTHREAD_CANCEL_ASYNCHRONOUS 1 11395 #define PTHREAD_CANCEL_DISABLE 1 11396 11397 ------------------------------------------------------------------------------- 11398 11399 semaphore.h 11400 11401 typedef struct 11402 { 11403 struct _pthread_fastlock __sem_lock; 11404 int __sem_value; 11405 _pthread_descr __sem_waiting; 11406 } 11407 sem_t; 11408 #define SEM_FAILED ((sem_t*)0) 11409 11410 #define SEM_VALUE_MAX ((int)((~0u)>>1)) 11411 11412 ------------------------------------------------------------------------------- 11413 11414 Interface Definitions for libpthread 11415 11416 Table of Contents 11417 _pthread_cleanup_pop -- establish cancellation handlers 11418 _pthread_cleanup_push -- establish cancellation handlers 11419 11420 The following interfaces are included in libpthread and are defined by this 11421 specification. Unless otherwise noted, these interfaces shall be included in 11422 the source standard. 11423 11424 Other interfaces listed above for libpthread shall behave as described in the 11425 referenced base document. 11426 11427 _pthread_cleanup_pop 11428 11429 Name 11430 11431 _pthread_cleanup_pop -- establish cancellation handlers 11432 11433 Synopsis 11434 11435 #include 11436 11437 void _pthread_cleanup_pop(struct _pthread_cleanup_buffer *, int); 11438 11439 Description 11440 11441 The _pthread_cleanup_pop function provides an implementation of the 11442 pthread_cleanup_pop macro described in ISO POSIX (2003). 11443 11444 The _pthread_cleanup_pop function is not in the source standard; it is only in 11445 the binary standard. 11446 11447 _pthread_cleanup_push 11448 11449 Name 11450 11451 _pthread_cleanup_push -- establish cancellation handlers 11452 11453 Synopsis 11454 11455 #include 11456 11457 void _pthread_cleanup_push(struct _pthread_cleanup_buffer *, void (*) (void *), 11458 void *); 11459 11460 Description 11461 11462 The _pthread_cleanup_push function provides an implementation of the 11463 pthread_cleanup_push macro described in ISO POSIX (2003). 11464 11465 The _pthread_cleanup_push function is not in the source standard; it is only in 11466 the binary standard. 11467 11468 ------------------------------------------------------------------------------- 11469 11470 Interfaces for libgcc_s 11471 11472 Table 1-34 defines the library name and shared object name for the libgcc_s 11473 library 11474 11475 Table 1-34. libgcc_s Definition 11476 11477 +-----------------------+ 11478 |Library:|libgcc_s | 11479 |--------+--------------| 11480 |SONAME: |libgcc_s.so.1 | 11481 +-----------------------+ 11482 11483 ------------------------------------------------------------------------------- 11484 11485 Unwind Library 11486 11487 ------------------------------------------------------------------------------- 11488 11489 Interfaces for Unwind Library 11490 11491 No external functions are defined for libgcc_s - Unwind Library 11492 11493 ------------------------------------------------------------------------------- 11494 11495 Data Definitions for libgcc_s 11496 11497 This section defines global identifiers and their values that are associated 11498 with interfaces contained in libgcc_s. These definitions are organized into 11499 groups that correspond to system headers. This convention is used as a 11500 convenience for the reader, and does not imply the existence of these headers, 11501 or their content. 11502 11503 These definitions are intended to supplement those provided in the referenced 11504 underlying specifications. 11505 11506 This specification uses ISO/IEC 9899 C Language as the reference programming 11507 language, and data definitions are specified in ISO C format. The C language is 11508 used here as a convenient notation. Using a C language description of these 11509 data objects does not preclude their use by other programming languages. 11510 11511 ------------------------------------------------------------------------------- 11512 11513 unwind.h 11514 11515 struct dwarf_eh_base 11516 { 11517 void *tbase; 11518 void *dbase; 11519 void *func; 11520 } 11521 ; 11522 struct _Unwind_Context; 11523 11524 typedef unsigned int _Unwind_Ptr; 11525 typedef unsigned int _Unwind_Word; 11526 11527 typedef enum 11528 { 11529 _URC_NO_REASON, _URC_FOREIGN_EXCEPTION_CAUGHT = 1, _URC_FATAL_PHASE2_ERROR = 11530 2, _URC_FATAL_PHASE1_ERROR = 3, _URC_NORMAL_STOP = 4, _URC_END_OF_STACK = 11531 5, _URC_HANDLER_FOUND = 6, _URC_INSTALL_CONTEXT = 11532 7, _URC_CONTINUE_UNWIND = 8 11533 } 11534 _Unwind_Reason_Code; 11535 11536 struct _Unwind_Exception 11537 { 11538 _Unwind_Exception_Class; 11539 _Unwind_Exception_Cleanup_Fn; 11540 _Unwind_Word; 11541 _Unwind_Word; 11542 } 11543 ; 11544 #define _UA_SEARCH_PHASE 1 11545 #define _UA_END_OF_STACK 16 11546 #define _UA_CLEANUP_PHASE 2 11547 #define _UA_HANDLER_FRAME 4 11548 #define _UA_FORCE_UNWIND 8 11549 11550 ------------------------------------------------------------------------------- 11551 11552 Interfaces for libdl 11553 11554 Table 1-35 defines the library name and shared object name for the libdl 11555 library 11556 11557 Table 1-35. libdl Definition 11558 11559 +--------------------+ 11560 |Library:|libdl | 11561 |--------+-----------| 11562 |SONAME: |libdl.so.2 | 11563 +--------------------+ 11564 11565 The behavior of the interfaces in this library is specified by the following 11566 specifications: 11567 11568 this specification 11569 ISO POSIX (2003) 11570 11571 ------------------------------------------------------------------------------- 11572 11573 Dynamic Loader 11574 11575 ------------------------------------------------------------------------------- 11576 11577 Interfaces for Dynamic Loader 11578 11579 An LSB conforming implementation shall provide the generic functions for 11580 Dynamic Loader specified in Table 1-36, with the full functionality as 11581 described in the referenced underlying specification. 11582 11583 Table 1-36. libdl - Dynamic Loader Function Interfaces 11584 11585 +-------------------------------------------------------+ 11586 |dladdr [1]|dlclose [2]|dlerror [2]|dlopen [1]|dlsym [1]| 11587 +-------------------------------------------------------+ 11588 11589 Referenced Specification(s) 11590 11591 [1]. this specification 11592 11593 [2]. ISO POSIX (2003) 11594 11595 ------------------------------------------------------------------------------- 11596 11597 Data Definitions for libdl 11598 11599 This section defines global identifiers and their values that are associated 11600 with interfaces contained in libdl. These definitions are organized into groups 11601 that correspond to system headers. This convention is used as a convenience for 11602 the reader, and does not imply the existence of these headers, or their 11603 content. 11604 11605 These definitions are intended to supplement those provided in the referenced 11606 underlying specifications. 11607 11608 This specification uses ISO/IEC 9899 C Language as the reference programming 11609 language, and data definitions are specified in ISO C format. The C language is 11610 used here as a convenient notation. Using a C language description of these 11611 data objects does not preclude their use by other programming languages. 11612 11613 ------------------------------------------------------------------------------- 11614 11615 dlfcn.h 11616 11617 #define RTLD_NEXT ((void *) -1l) 11618 #define RTLD_LOCAL 0 11619 #define RTLD_LAZY 0x00001 11620 #define RTLD_NOW 0x00002 11621 #define RTLD_GLOBAL 0x00100 11622 11623 typedef struct 11624 { 11625 char *dli_fname; 11626 void *dli_fbase; 11627 char *dli_sname; 11628 void *dli_saddr; 11629 } 11630 Dl_info; 11631 11632 ------------------------------------------------------------------------------- 11633 11634 Interface Definitions for libdl 11635 11636 Table of Contents 11637 dladdr -- find the shared object containing a given address 11638 dlopen -- open dynamic object 11639 dlsym -- obtain the address of a symbol from a dlopen object 11640 11641 The following interfaces are included in libdl and are defined by this 11642 specification. Unless otherwise noted, these interfaces shall be included in 11643 the source standard. 11644 11645 Other interfaces listed above for libdl shall behave as described in the 11646 referenced base document. 11647 11648 dladdr 11649 11650 Name 11651 11652 dladdr -- find the shared object containing a given address 11653 11654 Synopsis 11655 11656 #include 11657 11658 typedef struct { 11659 const char *dli_fname; 11660 void *dli_fbase; 11661 const char *dli_sname; 11662 void *dli_saddr; 11663 } Dl_info; 11664 11665 int dladdr(void *addr, Dl_info *dlip); 11666 11667 Description 11668 11669 The dladdr function shall query the dynamic linker for information about the 11670 shared object containing the address addr. The information shall be returned in 11671 the user supplied data structure referenced by dlip. 11672 11673 The structure shall contain at least the following members: 11674 11675 dli_fname 11676 11677 The pathname of the shared object containing the address 11678 11679 dli_fbase 11680 11681 The base address at which the shared object is mapped into the address 11682 space of the calling process. 11683 11684 dli_sname 11685 11686 The name of the nearest runtime symbol with value less than or equal to 11687 addr. Where possible, the symbol name shall be returned as it would appear 11688 in C source code. 11689 11690 If no symbol with a suitable value is found, both this field and dli_saddr 11691 shall be set to NULL. 11692 11693 dli_saddr 11694 11695 The address of the symbol returned in dli_sname. 11696 11697 The behavior of dladdr is only specified in dynamically linked programs. 11698 11699 Return Value 11700 11701 On success, dladdr shall return non-zero, and the structure referenced by dlip 11702 shall be filled in as described. Otherwise, dladdr shall return zero, and the 11703 cause of the error can be fetched with dlerr. 11704 11705 Errors 11706 11707 See dlerr. 11708 11709 Environment 11710 11711 LD_LIBRARY_PATH 11712 11713 directory search-path for object files 11714 11715 dlopen 11716 11717 Name 11718 11719 dlopen -- open dynamic object 11720 11721 Synopsis 11722 11723 #include 11724 11725 void * dlopen(const char *filename, int flag); 11726 11727 Description 11728 11729 dlopen shall behave as specified in ISO POSIX (2003), but with additional 11730 behaviors listed below. 11731 11732 If the file argument does not contain a slash character, then the system shall 11733 look for a library of that name in at least the following directories, and use 11734 the first one which is found: 11735 11736 * The directories specified by the DT_RPATH dynamic entry. 11737 11738 * The directories specified in the LD_LIBRARY_PATH environment variable 11739 (which is a colon separated list of pathnames). This step shall be skipped 11740 for setuid and setgid executables. 11741 11742 * A set of directories sufficient to contain the libraries specified in this 11743 standard. 11744 11745 11746 Note: Traditionally, /lib and /usr/lib. This case would also cover 11747 cases in which the system used the mechanism of /etc/ld.so.conf and / 11748 etc/ld.so.cache to provide access. 11749 11750 Example: An application which is not linked against libm may choose to 11751 dlopen libm. 11752 11753 11754 11755 11756 11757 dlsym 11758 11759 Name 11760 11761 dlsym -- obtain the address of a symbol from a dlopen object 11762 11763 Description 11764 11765 dlsym is as specified in the ISO POSIX (2003), but with differences as listed 11766 below. 11767 11768 The special purpose value for handle RTLD_NEXT 11769 11770 The value RTLD_NEXT, which is reserved for future use shall be available, with 11771 the behavior as described in ISO POSIX (2003). 11772 11773 ------------------------------------------------------------------------------- 11774 11775 Interfaces for libcrypt 11776 11777 Table 1-37 defines the library name and shared object name for the libcrypt 11778 library 11779 11780 Table 1-37. libcrypt Definition 11781 11782 +-----------------------+ 11783 |Library:|libcrypt | 11784 |--------+--------------| 11785 |SONAME: |libcrypt.so.1 | 11786 +-----------------------+ 11787 11788 The behavior of the interfaces in this library is specified by the following 11789 specifications: 11790 11791 ISO POSIX (2003) 11792 11793 ------------------------------------------------------------------------------- 11794 11795 Encryption 11796 11797 ------------------------------------------------------------------------------- 11798 11799 Interfaces for Encryption 11800 11801 An LSB conforming implementation shall provide the generic functions for 11802 Encryption specified in Table 1-38, with the full functionality as described in 11803 the referenced underlying specification. 11804 11805 Table 1-38. libcrypt - Encryption Function Interfaces 11806 11807 +------------------------------------+ 11808 |crypt [1]|encrypt [1]|setkey [1]| | | 11809 +------------------------------------+ 11810 11811 Referenced Specification(s) 11812 11813 [1]. ISO POSIX (2003) 11814 11815 ------------------------------------------------------------------------------- 11816 11817 Interfaces for libpam 11818 11819 Table 1-39 defines the library name and shared object name for the libpam 11820 library 11821 11822 Table 1-39. libpam Definition 11823 11824 +---------------------+ 11825 |Library:|libpam | 11826 |--------+------------| 11827 |SONAME: |libpam.so.0 | 11828 +---------------------+ 11829 11830 A single service name, other, shall always be present. The behavior of this 11831 service shall be determined by the system administrator. Additional service 11832 names may also exist. [1] 11833 11834 The behavior of the interfaces in this library is specified by the following 11835 specifications: 11836 11837 this specification 11838 11839 ------------------------------------------------------------------------------- 11840 11841 Pluggable Authentication API 11842 11843 ------------------------------------------------------------------------------- 11844 11845 Interfaces for Pluggable Authentication API 11846 11847 An LSB conforming implementation shall provide the generic functions for 11848 Pluggable Authentication API specified in Table 1-40, with the full 11849 functionality as described in the referenced underlying specification. 11850 11851 Table 1-40. libpam - Pluggable Authentication API Function Interfaces 11852 11853 +-----------------------------------------------------------------------------+ 11854 |pam_acct_mgmt |pam_close_session|pam_get_item [1]|pam_set_item|pam_strerror| 11855 |[1] |[1] | |[1] |[1] | 11856 |----------------+-----------------+----------------+------------+------------| 11857 |pam_authenticate|pam_end [1] |pam_getenvlist |pam_setcred | | 11858 |[1] | |[1] |[1] | | 11859 |----------------+-----------------+----------------+------------+------------| 11860 |pam_chauthtok |pam_fail_delay |pam_open_session|pam_start | | 11861 |[1] |[1] |[1] |[1] | | 11862 +-----------------------------------------------------------------------------+ 11863 11864 Referenced Specification(s) 11865 11866 [1]. this specification 11867 11868 ------------------------------------------------------------------------------- 11869 11870 Data Definitions for libpam 11871 11872 This section defines global identifiers and their values that are associated 11873 with interfaces contained in libpam. These definitions are organized into 11874 groups that correspond to system headers. This convention is used as a 11875 convenience for the reader, and does not imply the existence of these headers, 11876 or their content. 11877 11878 These definitions are intended to supplement those provided in the referenced 11879 underlying specifications. 11880 11881 This specification uses ISO/IEC 9899 C Language as the reference programming 11882 language, and data definitions are specified in ISO C format. The C language is 11883 used here as a convenient notation. Using a C language description of these 11884 data objects does not preclude their use by other programming languages. 11885 11886 ------------------------------------------------------------------------------- 11887 11888 security/pam_appl.h 11889 11890 typedef struct pam_handle pam_handle_t; 11891 struct pam_message 11892 { 11893 int msg_style; 11894 const char *msg; 11895 } 11896 ; 11897 struct pam_response 11898 { 11899 char *resp; 11900 int resp_retcode; 11901 } 11902 ; 11903 11904 struct pam_conv 11905 { 11906 int (*conv) (int num_msg, const struct pam_message * *msg, 11907 struct pam_response * *resp, void *appdata_ptr); 11908 void *appdata_ptr; 11909 } 11910 ; 11911 #define PAM_PROMPT_ECHO_OFF 1 11912 #define PAM_PROMPT_ECHO_ON 2 11913 #define PAM_ERROR_MSG 3 11914 #define PAM_TEXT_INFO 4 11915 11916 #define PAM_SERVICE 1 11917 #define PAM_USER 2 11918 #define PAM_TTY 3 11919 #define PAM_RHOST 4 11920 #define PAM_CONV 5 11921 #define PAM_RUSER 8 11922 #define PAM_USER_PROMPT 9 11923 11924 #define PAM_SUCCESS 0 11925 #define PAM_OPEN_ERR 1 11926 #define PAM_USER_UNKNOWN 10 11927 #define PAM_MAXTRIES 11 11928 #define PAM_NEW_AUTHTOK_REQD 12 11929 #define PAM_ACCT_EXPIRED 13 11930 #define PAM_SESSION_ERR 14 11931 #define PAM_CRED_UNAVAIL 15 11932 #define PAM_CRED_EXPIRED 16 11933 #define PAM_CRED_ERR 17 11934 #define PAM_CONV_ERR 19 11935 #define PAM_SYMBOL_ERR 2 11936 #define PAM_AUTHTOK_ERR 20 11937 #define PAM_AUTHTOK_RECOVER_ERR 21 11938 #define PAM_AUTHTOK_LOCK_BUSY 22 11939 #define PAM_AUTHTOK_DISABLE_AGING 23 11940 #define PAM_TRY_AGAIN 24 11941 #define PAM_ABORT 26 11942 #define PAM_AUTHTOK_EXPIRED 27 11943 #define PAM_BAD_ITEM 29 11944 #define PAM_SERVICE_ERR 3 11945 #define PAM_SYSTEM_ERR 4 11946 #define PAM_BUF_ERR 5 11947 #define PAM_PERM_DENIED 6 11948 #define PAM_AUTH_ERR 7 11949 #define PAM_CRED_INSUFFICIENT 8 11950 #define PAM_AUTHINFO_UNAVAIL 9 11951 11952 #define PAM_DISALLOW_NULL_AUTHTOK 0x0001U 11953 #define PAM_ESTABLISH_CRED 0x0002U 11954 #define PAM_DELETE_CRED 0x0004U 11955 #define PAM_REINITIALIZE_CRED 0x0008U 11956 #define PAM_REFRESH_CRED 0x0010U 11957 #define PAM_CHANGE_EXPIRED_AUTHTOK 0x0020U 11958 #define PAM_SILENT 0x8000U 11959 11960 ------------------------------------------------------------------------------- 11961 11962 Interface Definitions for libpam 11963 11964 Table of Contents 11965 pam_acct_mgmt -- establish the status of a user's account 11966 pam_authenticate -- authenticate the user 11967 pam_chauthtok -- change the authentication token for a given user 11968 pam_close_session -- indicate that an authenticated session has ended 11969 pam_end -- terminate the use of the PAM library 11970 pam_fail_delay -- specify delay time to use on authentication error 11971 pam_get_item -- obtain the value of the indicated item. 11972 pam_getenvlist -- returns a pointer to the complete PAM environment. 11973 pam_open_session -- used to indicate that an authenticated session has been 11974 initiated 11975 pam_set_item -- (re)set the value of an item. 11976 pam_setcred -- set the module-specific credentials of the user 11977 pam_start -- initialize the PAM library 11978 pam_strerror -- returns a string describing the PAM error 11979 11980 The following interfaces are included in libpam and are defined by this 11981 specification. Unless otherwise noted, these interfaces shall be included in 11982 the source standard. 11983 11984 Other interfaces listed above for libpam shall behave as described in the 11985 referenced base document. 11986 11987 pam_acct_mgmt 11988 11989 Name 11990 11991 pam_acct_mgmt -- establish the status of a user's account 11992 11993 Synopsis 11994 11995 #include 11996 11997 int pam_acct_mgmt(pam_handle_t *pamh, int flags); 11998 11999 Description 12000 12001 pam_acct_mgmt establishes the account's usability and the user's accessibility 12002 to the system. It is typically called after the user has been authenticated. 12003 12004 flags may be specified as any valid flag (namely, one of those applicable to 12005 the flags argument of pam_authenticate). Additionally, the value of flags may 12006 be logically or'd with PAM_SILENT. 12007 12008 Return Value 12009 12010 PAM_SUCCESS 12011 12012 Success. 12013 12014 PAM_NEW_AUTHTOK_REQD 12015 12016 User is valid, but user's authentication token has expired. The correct 12017 response to this return-value is to require that the user satisfy the 12018 pam_chauthtok function before obtaining service. It may not be possible for 12019 an application to do this. In such a case, the user should be denied access 12020 until the account password is updated. 12021 12022 PAM_ACCT_EXPIRED 12023 12024 User is no longer permitted access to the system. 12025 12026 PAM_AUTH_ERR 12027 12028 Authentication error. 12029 12030 PAM_PERM_DENIED 12031 12032 User is not permitted to gain access at this time. 12033 12034 PAM_USER_UNKNOWN 12035 12036 User is not known to a module's account management component. 12037 12038 Errors 12039 12040 May be translated to text with pam_strerror. 12041 12042 pam_authenticate 12043 12044 Name 12045 12046 pam_authenticate -- authenticate the user 12047 12048 Synopsis 12049 12050 #include 12051 12052 int pam_authenticate(pam_handle_t *pamh, int flags); 12053 12054 Description 12055 12056 pam_authenticate serves as an interface to the authentication mechanisms of the 12057 loaded modules. 12058 12059 flags is an optional parameter that may be specified by the following value: 12060 12061 PAM_DISALLOW_NULL_AUTHTOK 12062 12063 Instruct the authentication modules to return PAM_AUTH_ERR if the user does 12064 not have a registered authorization token. 12065 12066 Additionally, the value of flags may be logically or'd with PAM_SILENT. 12067 12068 The process may need to be privileged in order to successfully call this 12069 function. 12070 12071 Return Value 12072 12073 PAM_SUCCESS 12074 12075 Success. 12076 12077 PAM_AUTH_ERR 12078 12079 User was not authenticated or process did not have sufficient privileges to 12080 perform authentication. 12081 12082 PAM_CRED_INSUFFICIENT 12083 12084 Application does not have sufficient credentials to authenticate the user. 12085 12086 PAM_AUTHINFO_UNAVAIL 12087 12088 Modules were not able to access the authentication information. This might 12089 be due to a network or hardware failure, etc. 12090 12091 PAM_USER_UNKNOWN 12092 12093 Supplied username is not known to the authentication service. 12094 12095 PAM_MAXTRIES 12096 12097 One or more authentication modules has reached its limit of tries 12098 authenticating the user. Do not try again. 12099 12100 PAM_ABORT 12101 12102 One or more authentication modules failed to load. 12103 12104 Errors 12105 12106 May be translated to text with pam_strerror. 12107 12108 pam_chauthtok 12109 12110 Name 12111 12112 pam_chauthtok -- change the authentication token for a given user 12113 12114 Synopsis 12115 12116 #include 12117 12118 int pam_chauthtok(pam_handle_t *pamh, const int flags); 12119 12120 Description 12121 12122 pam_chauthtok is used to change the authentication token for a given user as 12123 indicated by the state associated with the handle pamh. 12124 12125 flags is an optional parameter that may be specified by the following value: 12126 12127 PAM_CHANGE_EXPIRED_AUTHTOK 12128 12129 User's authentication token should only be changed if it has expired. 12130 12131 Additionally, the value of flags may be logically or'd with PAM_SILENT. 12132 12133 RETURN VALUE 12134 12135 PAM_SUCCESS 12136 12137 Success. 12138 12139 PAM_AUTHTOK_ERR 12140 12141 A module was unable to obtain the new authentication token. 12142 12143 PAM_AUTHTOK_RECOVER_ERR 12144 12145 A module was unable to obtain the old authentication token. 12146 12147 PAM_AUTHTOK_LOCK_BUSY 12148 12149 One or more modules were unable to change the authentication token since it 12150 is currently locked. 12151 12152 PAM_AUTHTOK_DISABLE_AGING 12153 12154 Authentication token aging has been disabled for at least one of the 12155 modules. 12156 12157 PAM_PERM_DENIED 12158 12159 Permission denied. 12160 12161 PAM_TRY_AGAIN 12162 12163 Not all modules were in a position to update the authentication token(s). 12164 In such a case, none of the user's authentication tokens are updated. 12165 12166 PAM_USER_UNKNOWN 12167 12168 User is not known to the authentication token changing service. 12169 12170 ERRORS 12171 12172 May be translated to text with pam_strerror. 12173 12174 pam_close_session 12175 12176 Name 12177 12178 pam_close_session -- indicate that an authenticated session has ended 12179 12180 Synopsis 12181 12182 #include 12183 12184 int pam_close_session(pam_handle_t *pamh, int flags); 12185 12186 Description 12187 12188 pam_close_session is used to indicate that an authenticated session has ended. 12189 It is used to inform the module that the user is exiting a session. It should 12190 be possible for the PAM library to open a session and close the same session 12191 from different applications. 12192 12193 flags may have the value PAM_SILENT to indicate that no output should be 12194 generated as a result of this function call. 12195 12196 Return Value 12197 12198 PAM_SUCCESS 12199 12200 Success. 12201 12202 PAM_SESSION_ERR 12203 12204 One of the required loaded modules was unable to close a session for the 12205 user. 12206 12207 Errors 12208 12209 May be translated to text with pam_strerror. 12210 12211 pam_end 12212 12213 Name 12214 12215 pam_end -- terminate the use of the PAM library 12216 12217 Synopsis 12218 12219 #include 12220 12221 int pam_end(pam_handle_t *pamh, int pam_status); 12222 12223 Description 12224 12225 pam_end terminates use of the PAM library. On success, the contents of *pamh 12226 are no longer valid, and all memory associated with it is invalid. 12227 12228 Normally, pam_status is passed the value PAM_SUCCESS, but in the event of an 12229 unsuccessful service application, the appropriate PAM error return value should 12230 be used. 12231 12232 Return Value 12233 12234 PAM_SUCCESS 12235 12236 Success. 12237 12238 Errors 12239 12240 May be translated to text with pam_strerror. 12241 12242 pam_fail_delay 12243 12244 Name 12245 12246 pam_fail_delay -- specify delay time to use on authentication error 12247 12248 Synopsis 12249 12250 #include 12251 12252 int pam_fail_delay(pam_handle_t *pamh, unsigned int micro_sec); 12253 12254 Description 12255 12256 pam_fail_delay specifies the minimum delay for the PAM library to use when an 12257 authentication error occurs. The actual delay can vary by as much at 25%. If 12258 this function is called multiple times, the longest time specified by any of 12259 the call will be used. 12260 12261 The delay is invoked if an authentication error occurs during the 12262 pam_authenticate or pam_chauthtok function calls. 12263 12264 Independent of the success of pam_authenticate or pam_chauthtok, the delay time 12265 is reset to its default value of 0 when the PAM library returns control to the 12266 application from these two functions. 12267 12268 Return Value 12269 12270 PAM_SUCCESS 12271 12272 Success. 12273 12274 Errors 12275 12276 May be translated to text with pam_strerror. 12277 12278 pam_get_item 12279 12280 Name 12281 12282 pam_get_item -- obtain the value of the indicated item. 12283 12284 Synopsis 12285 12286 #include 12287 12288 int pam_get_item(const pam_handle_t *pamh, int item_type, const void **item); 12289 12290 Description 12291 12292 pam_get_item obtains the value of the indicated item_type. The possible values 12293 of item_type are the same as listed for pam_set_item. 12294 12295 On success, item contains a pointer to the value of the corresponding item. 12296 Note that this is a pointer to the actual data and should not be free'd or 12297 over-written. 12298 12299 Return Value 12300 12301 PAM_SUCCESS 12302 12303 Success. 12304 12305 PAM_PERM_DENIED 12306 12307 Application passed a NULL pointer for item. 12308 12309 PAM_BAD_ITEM 12310 12311 Application attempted to get an undefined item. 12312 12313 Errors 12314 12315 May be translated to text with pam_strerror. 12316 12317 pam_getenvlist 12318 12319 Name 12320 12321 pam_getenvlist -- returns a pointer to the complete PAM environment. 12322 12323 Synopsis 12324 12325 #include 12326 12327 char * const *pam_getenvlist(pam_handle_t *pamh); 12328 12329 Description 12330 12331 pam_getenvlist returns a pointer to the complete PAM environment. This pointer 12332 points to an array of pointers to NUL-terminated strings and must be terminated 12333 by a NULL pointer. Each string has the form "name=value". 12334 12335 The PAM library module allocates memory for the returned value and the 12336 associated strings. The calling application is responsible for freeing this 12337 memory. 12338 12339 Return Value 12340 12341 pam_getenvlist returns an array of string pointers containing the PAM 12342 environment. On error, NULL is returned. 12343 12344 pam_open_session 12345 12346 Name 12347 12348 pam_open_session -- used to indicate that an authenticated session has been 12349 initiated 12350 12351 Synopsis 12352 12353 #include 12354 12355 int pam_open_session(pam_handle_t *pamh, int flags); 12356 12357 Description 12358 12359 pam_handle_t is used to indicate that an authenticated session has begun. It is 12360 used to inform the module that the user is currently in a session. It should be 12361 possible for the PAM library to open a session and close the same session from 12362 different applications. 12363 12364 flags may have the value PAM_SILENT to indicate that no output be generated as 12365 a rsult of this function call. 12366 12367 Return Value 12368 12369 PAM_SUCCESS 12370 12371 Success. 12372 12373 PAM_SESSION_ERR 12374 12375 One of the loaded modules was unable to open a session for the user. 12376 12377 ERRORS 12378 12379 May be translated to text with pam_strerror. 12380 12381 pam_set_item 12382 12383 Name 12384 12385 pam_set_item -- (re)set the value of an item. 12386 12387 Synopsis 12388 12389 #include 12390 12391 int pam_set_item(pam_handle_t *pamh, int item_type, const void *item); 12392 12393 Description 12394 12395 pam_set_item (re)sets the value of one of the following item_types: 12396 12397 PAM_SERVICE 12398 12399 service name 12400 12401 PAM_USER 12402 12403 user name 12404 12405 PAM_TTY 12406 12407 terminal name 12408 12409 The value for a device file should include the /dev/ prefix. The value for 12410 graphical, X-based, applications should be the $DISPLAY variable. 12411 12412 PAM_RHOST 12413 12414 remote host name 12415 12416 PAM_CONV 12417 12418 conversation structure 12419 12420 PAM_RUSER 12421 12422 remote user name 12423 12424 PAM_USER_PROMPT 12425 12426 string to be used when prompting for a user's name 12427 12428 The default value for this string is Please enter username: . 12429 12430 For all item_types other than PAM_CONV, item is a pointer to a NULL-terminated 12431 character string. In the case of PAM_CONV, item points to an initialized 12432 pam_conv structure. 12433 12434 Return Value 12435 12436 PAM_SUCCESS 12437 12438 Success. 12439 12440 PAM_PERM_DENIED 12441 12442 An attempt was made to replace the conversation structure with a NULL 12443 value. 12444 12445 PAM_BUF_ERR 12446 12447 Function ran out of memory making a copy of the item. 12448 12449 PAM_BAD_ITEM 12450 12451 Application attempted to set an undefined item. 12452 12453 Errors 12454 12455 May be translated to text with pam_strerror. 12456 12457 pam_setcred 12458 12459 Name 12460 12461 pam_setcred -- set the module-specific credentials of the user 12462 12463 Synopsis 12464 12465 #include 12466 12467 extern int pam_setcred(pam_handle_t *pamh, int flags); 12468 12469 Description 12470 12471 pam_setcred sets the module-specific credentials of the user. It is usually 12472 called after the user has been authenticated, after the account management 12473 function has been called and after a session has been opened for the user. 12474 12475 flags maybe specified from among the following values: 12476 12477 PAM_ESTABLISH_CRED 12478 12479 set credentials for the authentication service 12480 12481 PAM_DELETE_CRED 12482 12483 delete credentials associated with the authentication service 12484 12485 PAM_REINITIALIZE_CRED 12486 12487 reinitialize the user credentials 12488 12489 PAM_REFRESH_CRED 12490 12491 extend lifetime of the user credentials 12492 12493 Additionally, the value of flags may be logically or'd with PAM_SILENT. 12494 12495 Return Value 12496 12497 PAM_SUCCESS 12498 12499 Success. 12500 12501 PAM_CRED_UNAVAIL 12502 12503 Module cannot retrieve the user's credentials. 12504 12505 PAM_CRED_EXPIRED 12506 12507 User's credentials have expired. 12508 12509 PAM_USER_UNKNOWN 12510 12511 User is not known to an authentication module. 12512 12513 PAM_CRED_ERR 12514 12515 Module was unable to set the credentials of the user. 12516 12517 Errors 12518 12519 May be translated to text with pam_strerror. 12520 12521 pam_start 12522 12523 Name 12524 12525 pam_start -- initialize the PAM library 12526 12527 Synopsis 12528 12529 #include 12530 12531 int pam_start(const char *service_name, const char *user, const (struct 12532 pam_conv *pam_conversation), pam_handle_t **pamh); 12533 12534 Description 12535 12536 pam_start is used to initialize the PAM library. It must be called prior to any 12537 other usage of the PAM library. On success, *pamh becomes a handle that 12538 provides continuity for successive calls to the PAM library. pam_start expects 12539 arguments as follows: the service_name of the program, the username of the 12540 individual to be authenticated, a pointer to an application-supplied pam_conv 12541 structure, and a pointer to a pam_handle_t pointer. 12542 12543 An application must provide the conversation function used for direct 12544 communication between a loaded module and the application. The application also 12545 typically provides a means for the module to prompt the user for a password, 12546 etc. 12547 12548 The structure, pam_conv, is defined to be, 12549 12550 struct pam_conv { 12551 int (*conv) (int num_msg, 12552 const struct pam_message * *msg, 12553 struct pam_response * *resp, 12554 void *appdata_ptr); 12555 void *appdata_ptr; 12556 }; 12557 12558 It is initialized by the application before it is passed to the library. The 12559 contents of this structure are attached to the *pamh handle. The point of this 12560 argument is to provide a mechanism for any loaded module to interact directly 12561 with the application program; this is why it is called a conversation 12562 structure. 12563 12564 When a module calls the referenced conv function, appdata_ptr is set to the 12565 second element of this structure. 12566 12567 The other arguments of a call to conv concern the information exchanged by 12568 module and application. num_msg holds the length of the array of pointers 12569 passed via msg. On success, the pointer resp points to an array of num_msg 12570 pam_response structures, holding the application-supplied text. Note that resp 12571 is a struct pam_response array and not an array of pointers. 12572 12573 Return Value 12574 12575 PAM_SUCCESS 12576 12577 Success. 12578 12579 PAM_BUF_ERR 12580 12581 Memory allocation error. 12582 12583 PAM_ABORT 12584 12585 Internal failure. 12586 12587 ERRORS 12588 12589 May be translated to text with pam_strerror. 12590 12591 pam_strerror 12592 12593 Name 12594 12595 pam_strerror -- returns a string describing the PAM error 12596 12597 Synopsis 12598 12599 #include 12600 12601 const char * pam_strerror(pam_handle_t *pamh, int errnum); 12602 12603 Description 12604 12605 pam_strerror returns a string describing the PAM error associated with errnum. 12606 12607 Return Value 12608 12609 On success, this function returns a description of the indicated error. The 12610 application should not free or modify this string. This returned string will 12611 not be translated. 12612 12613 II. Utility Libraries 12614 12615 Table of Contents 12616 2. utility Libraries 12617 12618 ------------------------------------------------------------------------------- 12619 12620 Chapter 2. utility Libraries 12621 12622 An LSB-conforming implementation shall also support some utility libraries 12623 which are built on top of the interfaces provided by the base libraries. These 12624 libraries implement common functionality, and hide additional system dependent 12625 information such as file formats and device names. 12626 12627 ------------------------------------------------------------------------------- 12628 12629 Interfaces for libz 12630 12631 Table 2-1 defines the library name and shared object name for the libz library 12632 12633 Table 2-1. libz Definition 12634 12635 +-------------------+ 12636 |Library:|libz | 12637 |--------+----------| 12638 |SONAME: |libz.so.1 | 12639 +-------------------+ 12640 12641 The behavior of the interfaces in this library is specified by the following 12642 specifications: 12643 12644 zlib Manual 12645 12646 ------------------------------------------------------------------------------- 12647 12648 Compression Library 12649 12650 ------------------------------------------------------------------------------- 12651 12652 Interfaces for Compression Library 12653 12654 An LSB conforming implementation shall provide the generic functions for 12655 Compression Library specified in Table 2-2, with the full functionality as 12656 described in the referenced underlying specification. 12657 12658 Table 2-2. libz - Compression Library Function Interfaces 12659 12660 +-----------------------------------------------------------------------------+ 12661 |adler32 [1] |deflateInit_ [1] |gzerror |gzread [1] |inflateInit2_ [1] | 12662 | | |[1] | | | 12663 |-------------+--------------------+---------+-----------+--------------------| 12664 |compress [1] |deflateParams [1] |gzflush |gzrewind |inflateInit_ [1] | 12665 | | |[1] |[1] | | 12666 |-------------+--------------------+---------+-----------+--------------------| 12667 |compress2 [1]|deflateReset [1] |gzgetc |gzseek [1] |inflateReset [1] | 12668 | | |[1] | | | 12669 |-------------+--------------------+---------+-----------+--------------------| 12670 |crc32 [1] |deflateSetDictionary|gzgets |gzsetparams|inflateSetDictionary| 12671 | |[1] |[1] |[1] |[1] | 12672 |-------------+--------------------+---------+-----------+--------------------| 12673 |deflate [1] |get_crc_table [1] |gzopen |gztell [1] |inflateSync [1] | 12674 | | |[1] | | | 12675 |-------------+--------------------+---------+-----------+--------------------| 12676 |deflateCopy |gzclose [1] |gzprintf |gzwrite [1]|inflateSyncPoint [1]| 12677 |[1] | |[1] | | | 12678 |-------------+--------------------+---------+-----------+--------------------| 12679 |deflateEnd |gzdopen [1] |gzputc |inflate [1]|uncompress [1] | 12680 |[1] | |[1] | | | 12681 |-------------+--------------------+---------+-----------+--------------------| 12682 |deflateInit2_|gzeof [1] |gzputs |inflateEnd |zError [1] | 12683 |[1] | |[1] |[1] | | 12684 +-----------------------------------------------------------------------------+ 12685 12686 Referenced Specification(s) 12687 12688 [1]. zlib Manual 12689 12690 ------------------------------------------------------------------------------- 12691 12692 Data Definitions for libz 12693 12694 This section defines global identifiers and their values that are associated 12695 with interfaces contained in libz. These definitions are organized into groups 12696 that correspond to system headers. This convention is used as a convenience for 12697 the reader, and does not imply the existence of these headers, or their 12698 content. 12699 12700 These definitions are intended to supplement those provided in the referenced 12701 underlying specifications. 12702 12703 This specification uses ISO/IEC 9899 C Language as the reference programming 12704 language, and data definitions are specified in ISO C format. The C language is 12705 used here as a convenient notation. Using a C language description of these 12706 data objects does not preclude their use by other programming languages. 12707 12708 ------------------------------------------------------------------------------- 12709 12710 zlib.h 12711 12712 #define Z_NULL 0 12713 #define MAX_WBITS 15 12714 #define MAX_MEM_LEVEL 9 12715 #define deflateInit2(strm,level,method,windowBits,memLevel,strategy) deflateInit2_((strm),(level),(method),(windowBits),(memLevel),(strategy),ZLIB_VERSION,sizeof(z_stream)) 12716 #define deflateInit(strm,level) deflateInit_((strm), (level), ZLIB_VERSION, sizeof(z_stream)) 12717 #define inflateInit2(strm,windowBits) inflateInit2_((strm), (windowBits), ZLIB_VERSION, sizeof(z_stream)) 12718 #define inflateInit(strm) inflateInit_((strm), ZLIB_VERSION, sizeof(z_stream)) 12719 12720 typedef int intf; 12721 12722 typedef void *voidpf; 12723 typedef unsigned int uInt; 12724 typedef unsigned long uLong; 12725 typedef uLong uLongf; 12726 typedef void *voidp; 12727 typedef unsigned char Byte; 12728 typedef off_t z_off_t; 12729 typedef void *const voidpc; 12730 12731 typedef voidpf (*alloc_func) (voidpf opaque, uInt items, uInt size); 12732 typedef void (*free_func) (voidpf opaque, voidpf address); 12733 struct internal_state 12734 { 12735 int dummy; 12736 } 12737 ; 12738 typedef Byte Bytef; 12739 typedef uInt uIntf; 12740 12741 typedef struct z_stream_s 12742 { 12743 Bytef *next_in; 12744 uInt avail_in; 12745 uLong total_in; 12746 Bytef *next_out; 12747 uInt avail_out; 12748 uLong total_out; 12749 char *msg; 12750 struct internal_state *state; 12751 alloc_func zalloc; 12752 free_func zfree; 12753 voidpf opaque; 12754 int data_type; 12755 uLong adler; 12756 uLong reserved; 12757 } 12758 z_stream; 12759 12760 typedef z_stream *z_streamp; 12761 typedef voidp gzFile; 12762 #define Z_NO_FLUSH 0 12763 #define Z_PARTIAL_FLUSH 1 12764 #define Z_SYNC_FLUSH 2 12765 #define Z_FULL_FLUSH 3 12766 #define Z_FINISH 4 12767 12768 #define Z_ERRNO (-1) 12769 #define Z_STREAM_ERROR (-2) 12770 #define Z_DATA_ERROR (-3) 12771 #define Z_MEM_ERROR (-4) 12772 #define Z_BUF_ERROR (-5) 12773 #define Z_OK 0 12774 #define Z_STREAM_END 1 12775 #define Z_NEED_DICT 2 12776 12777 #define Z_DEFAULT_COMPRESSION (-1) 12778 #define Z_NO_COMPRESSION 0 12779 #define Z_BEST_SPEED 1 12780 #define Z_BEST_COMPRESSION 9 12781 12782 #define Z_DEFAULT_STRATEGY 0 12783 #define Z_FILTERED 1 12784 #define Z_HUFFMAN_ONLY 2 12785 12786 #define Z_BINARY 0 12787 #define Z_ASCII 1 12788 #define Z_UNKNOWN 2 12789 12790 #define Z_DEFLATED 8 12791 12792 ------------------------------------------------------------------------------- 12793 12794 Interfaces for libncurses 12795 12796 Table 2-3 defines the library name and shared object name for the libncurses 12797 library 12798 12799 Table 2-3. libncurses Definition 12800 12801 +-------------------------+ 12802 |Library:|libncurses | 12803 |--------+----------------| 12804 |SONAME: |libncurses.so.5 | 12805 +-------------------------+ 12806 12807 The behavior of the interfaces in this library is specified by the following 12808 specifications: 12809 12810 X/Open Curses 12811 12812 ------------------------------------------------------------------------------- 12813 12814 Curses 12815 12816 ------------------------------------------------------------------------------- 12817 12818 Interfaces for Curses 12819 12820 An LSB conforming implementation shall provide the generic functions for Curses 12821 specified in Table 2-4, with the full functionality as described in the 12822 referenced underlying specification. 12823 12824 Table 2-4. libncurses - Curses Function Interfaces 12825 12826 +-----------------------------------------------------------------------------+ 12827 |addch [1] |has_ic [1] |mvwaddchnstr [1]|scr_init [1] |vwscanw [1] | 12828 |----------------+--------------+----------------+---------------+------------| 12829 |addchnstr [1] |has_il [1] |mvwaddchstr [1] |scr_restore [1]|waddch [1] | 12830 |----------------+--------------+----------------+---------------+------------| 12831 |addchstr [1] |hline [1] |mvwaddnstr [1] |scr_set [1] |waddchnstr | 12832 | | | | |[1] | 12833 |----------------+--------------+----------------+---------------+------------| 12834 |addnstr [1] |idcok [1] |mvwaddstr [1] |scrl [1] |waddchstr | 12835 | | | | |[1] | 12836 |----------------+--------------+----------------+---------------+------------| 12837 |addstr [1] |idlok [1] |mvwchgat [1] |scroll [1] |waddnstr [1]| 12838 |----------------+--------------+----------------+---------------+------------| 12839 |attr_get [1] |immedok [1] |mvwdelch [1] |scrollok [1] |waddstr [1] | 12840 |----------------+--------------+----------------+---------------+------------| 12841 |attr_off [1] |inch [1] |mvwgetch [1] |set_curterm [1]|wattr_get | 12842 | | | | |[1] | 12843 |----------------+--------------+----------------+---------------+------------| 12844 |attr_on [1] |inchnstr [1] |mvwgetnstr [1] |set_term [1] |wattr_off | 12845 | | | | |[1] | 12846 |----------------+--------------+----------------+---------------+------------| 12847 |attr_set [1] |inchstr [1] |mvwgetstr [1] |setscrreg [1] |wattr_on [1]| 12848 |----------------+--------------+----------------+---------------+------------| 12849 |attroff [1] |init_color [1]|mvwhline [1] |setupterm [1] |wattr_set | 12850 | | | | |[1] | 12851 |----------------+--------------+----------------+---------------+------------| 12852 |attron [1] |init_pair [1] |mvwin [1] |slk_attr_set |wattroff [1]| 12853 | | | |[1] | | 12854 |----------------+--------------+----------------+---------------+------------| 12855 |attrset [1] |initscr [1] |mvwinch [1] |slk_attroff [1]|wattron [1] | 12856 |----------------+--------------+----------------+---------------+------------| 12857 |baudrate [1] |innstr [1] |mvwinchnstr [1] |slk_attron [1] |wattrset [1]| 12858 |----------------+--------------+----------------+---------------+------------| 12859 |beep [1] |insch [1] |mvwinchstr [1] |slk_attrset [1]|wbkgd [1] | 12860 |----------------+--------------+----------------+---------------+------------| 12861 |bkgd [1] |insdelln [1] |mvwinnstr [1] |slk_clear [1] |wbkgdset [1]| 12862 |----------------+--------------+----------------+---------------+------------| 12863 |bkgdset [1] |insertln [1] |mvwinsch [1] |slk_color [1] |wborder [1] | 12864 |----------------+--------------+----------------+---------------+------------| 12865 |border [1] |insnstr [1] |mvwinsnstr [1] |slk_init [1] |wchgat [1] | 12866 |----------------+--------------+----------------+---------------+------------| 12867 |box [1] |insstr [1] |mvwinsstr [1] |slk_label [1] |wclear [1] | 12868 |----------------+--------------+----------------+---------------+------------| 12869 |can_change_color|instr [1] |mvwinstr [1] |slk_noutrefresh|wclrtobot | 12870 |[1] | | |[1] |[1] | 12871 |----------------+--------------+----------------+---------------+------------| 12872 |cbreak [1] |intrflush [1] |mvwprintw [1] |slk_refresh [1]|wclrtoeol | 12873 | | | | |[1] | 12874 |----------------+--------------+----------------+---------------+------------| 12875 |chgat [1] |is_linetouched|mvwscanw [1] |slk_restore [1]|wcolor_set | 12876 | |[1] | | |[1] | 12877 |----------------+--------------+----------------+---------------+------------| 12878 |clear [1] |is_wintouched |mvwvline [1] |slk_set [1] |wcursyncup | 12879 | |[1] | | |[1] | 12880 |----------------+--------------+----------------+---------------+------------| 12881 |clearok [1] |isendwin [1] |napms [1] |slk_touch [1] |wdelch [1] | 12882 |----------------+--------------+----------------+---------------+------------| 12883 |clrtobot [1] |keyname [1] |newpad [1] |standend [1] |wdeleteln | 12884 | | | | |[1] | 12885 |----------------+--------------+----------------+---------------+------------| 12886 |clrtoeol [1] |keypad [1] |newterm [1] |standout [1] |wechochar | 12887 | | | | |[1] | 12888 |----------------+--------------+----------------+---------------+------------| 12889 |color_content |killchar [1] |newwin [1] |start_color [1]|werase [1] | 12890 |[1] | | | | | 12891 |----------------+--------------+----------------+---------------+------------| 12892 |color_set [1] |leaveok [1] |nl [1] |subpad [1] |wgetch [1] | 12893 |----------------+--------------+----------------+---------------+------------| 12894 |copywin [1] |longname [1] |nocbreak [1] |subwin [1] |wgetnstr [1]| 12895 |----------------+--------------+----------------+---------------+------------| 12896 |curs_set [1] |meta [1] |nodelay [1] |syncok [1] |wgetstr [1] | 12897 |----------------+--------------+----------------+---------------+------------| 12898 |def_prog_mode |move [1] |noecho [1] |termattrs [1] |whline [1] | 12899 |[1] | | | | | 12900 |----------------+--------------+----------------+---------------+------------| 12901 |def_shell_mode |mvaddch [1] |nonl [1] |termname [1] |winch [1] | 12902 |[1] | | | | | 12903 |----------------+--------------+----------------+---------------+------------| 12904 |del_curterm [1] |mvaddchnstr |noqiflush [1] |tgetent [1] |winchnstr | 12905 | |[1] | | |[1] | 12906 |----------------+--------------+----------------+---------------+------------| 12907 |delay_output [1]|mvaddchstr [1]|noraw [1] |tgetflag [1] |winchstr [1]| 12908 |----------------+--------------+----------------+---------------+------------| 12909 |delch [1] |mvaddnstr [1] |notimeout [1] |tgetnum [1] |winnstr [1] | 12910 |----------------+--------------+----------------+---------------+------------| 12911 |deleteln [1] |mvaddstr [1] |overlay [1] |tgetstr [1] |winsch [1] | 12912 |----------------+--------------+----------------+---------------+------------| 12913 |delscreen [1] |mvchgat [1] |overwrite [1] |tgoto [1] |winsdelln | 12914 | | | | |[1] | 12915 |----------------+--------------+----------------+---------------+------------| 12916 |delwin [1] |mvcur [1] |pair_content [1]|tigetflag [1] |winsertln | 12917 | | | | |[1] | 12918 |----------------+--------------+----------------+---------------+------------| 12919 |derwin [1] |mvdelch [1] |pechochar [1] |tigetnum [1] |winsnstr [1]| 12920 |----------------+--------------+----------------+---------------+------------| 12921 |doupdate [1] |mvderwin [1] |pnoutrefresh [1]|tigetstr [1] |winsstr [1] | 12922 |----------------+--------------+----------------+---------------+------------| 12923 |dupwin [1] |mvgetch [1] |prefresh [1] |timeout [1] |winstr [1] | 12924 |----------------+--------------+----------------+---------------+------------| 12925 |echo [1] |mvgetnstr [1] |printw [1] |touchline [1] |wmove [1] | 12926 |----------------+--------------+----------------+---------------+------------| 12927 |echochar [1] |mvgetstr [1] |putp [1] |touchwin [1] |wnoutrefresh| 12928 | | | | |[1] | 12929 |----------------+--------------+----------------+---------------+------------| 12930 |endwin [1] |mvhline [1] |putwin [1] |tparm [1] |wprintw [1] | 12931 |----------------+--------------+----------------+---------------+------------| 12932 |erase [1] |mvinch [1] |qiflush [1] |tputs [1] |wredrawln | 12933 | | | | |[1] | 12934 |----------------+--------------+----------------+---------------+------------| 12935 |erasechar [1] |mvinchnstr [1]|raw [1] |typeahead [1] |wrefresh [1]| 12936 |----------------+--------------+----------------+---------------+------------| 12937 |filter [1] |mvinchstr [1] |redrawwin [1] |unctrl [1] |wscanw [1] | 12938 |----------------+--------------+----------------+---------------+------------| 12939 |flash [1] |mvinnstr [1] |refresh [1] |ungetch [1] |wscrl [1] | 12940 |----------------+--------------+----------------+---------------+------------| 12941 |flushinp [1] |mvinsch [1] |reset_prog_mode |untouchwin [1] |wsetscrreg | 12942 | | |[1] | |[1] | 12943 |----------------+--------------+----------------+---------------+------------| 12944 |getbkgd [1] |mvinsnstr [1] |reset_shell_mode|use_env [1] |wstandend | 12945 | | |[1] | |[1] | 12946 |----------------+--------------+----------------+---------------+------------| 12947 |getch [1] |mvinsstr [1] |resetty [1] |vidattr [1] |wstandout | 12948 | | | | |[1] | 12949 |----------------+--------------+----------------+---------------+------------| 12950 |getnstr [1] |mvinstr [1] |restartterm [1] |vidputs [1] |wsyncdown | 12951 | | | | |[1] | 12952 |----------------+--------------+----------------+---------------+------------| 12953 |getstr [1] |mvprintw [1] |ripoffline [1] |vline [1] |wsyncup [1] | 12954 |----------------+--------------+----------------+---------------+------------| 12955 |getwin [1] |mvscanw [1] |savetty [1] |vw_printw [1] |wtimeout [1]| 12956 |----------------+--------------+----------------+---------------+------------| 12957 |halfdelay [1] |mvvline [1] |scanw [1] |vw_scanw [1] |wtouchln [1]| 12958 |----------------+--------------+----------------+---------------+------------| 12959 |has_colors [1] |mvwaddch [1] |scr_dump [1] |vwprintw [1] |wvline [1] | 12960 +-----------------------------------------------------------------------------+ 12961 12962 Referenced Specification(s) 12963 12964 [1]. X/Open Curses 12965 12966 An LSB conforming implementation shall provide the generic data interfaces for 12967 Curses specified in Table 2-5, with the full functionality as described in the 12968 referenced underlying specification. 12969 12970 Table 2-5. libncurses - Curses Data Interfaces 12971 12972 +---------------------------------------------------+ 12973 |COLORS [1] |COLS [1] |acs_map [1] |curscr [1]| | 12974 |---------------+---------+------------+----------+-| 12975 |COLOR_PAIRS [1]|LINES [1]|cur_term [1]|stdscr [1]| | 12976 +---------------------------------------------------+ 12977 12978 Referenced Specification(s) 12979 12980 [1]. X/Open Curses 12981 12982 ------------------------------------------------------------------------------- 12983 12984 Data Definitions for libncurses 12985 12986 This section defines global identifiers and their values that are associated 12987 with interfaces contained in libncurses. These definitions are organized into 12988 groups that correspond to system headers. This convention is used as a 12989 convenience for the reader, and does not imply the existence of these headers, 12990 or their content. 12991 12992 These definitions are intended to supplement those provided in the referenced 12993 underlying specifications. 12994 12995 This specification uses ISO/IEC 9899 C Language as the reference programming 12996 language, and data definitions are specified in ISO C format. The C language is 12997 used here as a convenient notation. Using a C language description of these 12998 data objects does not preclude their use by other programming languages. 12999 13000 ------------------------------------------------------------------------------- 13001 13002 curses.h 13003 13004 #define ERR (-1) 13005 #define OK (0) 13006 #define ACS_RARROW (acs_map['+']) 13007 #define ACS_LARROW (acs_map[',']) 13008 #define ACS_UARROW (acs_map['-']) 13009 #define ACS_DARROW (acs_map['.']) 13010 #define ACS_BLOCK (acs_map['0']) 13011 #define ACS_CKBOARD (acs_map['a']) 13012 #define ACS_DEGREE (acs_map['f']) 13013 #define ACS_PLMINUS (acs_map['g']) 13014 #define ACS_BOARD (acs_map['h']) 13015 #define ACS_LANTERN (acs_map['i']) 13016 #define ACS_LRCORNER (acs_map['j']) 13017 #define ACS_URCORNER (acs_map['k']) 13018 #define ACS_ULCORNER (acs_map['l']) 13019 #define ACS_LLCORNER (acs_map['m']) 13020 #define ACS_PLUS (acs_map['n']) 13021 #define ACS_S1 (acs_map['o']) 13022 #define ACS_HLINE (acs_map['q']) 13023 #define ACS_S9 (acs_map['s']) 13024 #define ACS_LTEE (acs_map['t']) 13025 #define ACS_RTEE (acs_map['u']) 13026 #define ACS_BTEE (acs_map['v']) 13027 #define ACS_TTEE (acs_map['w']) 13028 #define ACS_VLINE (acs_map['x']) 13029 #define ACS_DIAMOND (acs_map['`']) 13030 #define ACS_BULLET (acs_map['~']) 13031 #define getmaxyx(win,y,x) (y=(win)?((win)->_maxy+1):ERR,x=(win)?((win)->_maxx+1):ERR) 13032 #define getbegyx(win,y,x) (y=(win)?(win)->_begy:ERR,x=(win)?(win)->_begx:ERR) 13033 #define getyx(win,y,x) (y=(win)?(win)->_cury:ERR,x=(win)?(win)->_curx:ERR) 13034 #define getparyx(win,y,x) (y=(win)?(win)->_pary:ERR,x=(win)?(win)->_parx:ERR) 13035 13036 #define WA_ALTCHARSET A_ALTCHARSET 13037 #define WA_ATTRIBUTES A_ATTRIBUTES 13038 #define WA_BLINK A_BLINK 13039 #define WA_BOLD A_BOLD 13040 #define WA_DIM A_DIM 13041 #define WA_HORIZONTAL A_HORIZONTAL 13042 #define WA_INVIS A_INVIS 13043 #define WA_LEFT A_LEFT 13044 #define WA_LOW A_LOW 13045 #define WA_NORMAL A_NORMAL 13046 #define WA_PROTECT A_PROTECT 13047 #define WA_REVERSE A_REVERSE 13048 #define WA_RIGHT A_RIGHT 13049 #define WA_STANDOUT A_STANDOUT 13050 #define WA_TOP A_TOP 13051 #define WA_UNDERLINE A_UNDERLINE 13052 #define WA_VERTICAL A_VERTICAL 13053 #define A_REVERSE NCURSES_BITS(1UL,10) 13054 13055 #define COLOR_BLACK 0 13056 #define COLOR_RED 1 13057 #define COLOR_GREEN 2 13058 #define COLOR_YELLOW 3 13059 #define COLOR_BLUE 4 13060 #define COLOR_MAGENTA 5 13061 #define COLOR_CYAN 6 13062 #define COLOR_WHITE 7 13063 13064 #define _SUBWIN 0x01 13065 #define _ENDLINE 0x02 13066 #define _FULLWIN 0x04 13067 #define _ISPAD 0x10 13068 #define _HASMOVED 0x20 13069 13070 typedef unsigned char bool; 13071 13072 typedef unsigned long chtype; 13073 typedef struct screen SCREEN; 13074 typedef struct _win_st WINDOW; 13075 typedef chtype attr_t; 13076 typedef struct 13077 { 13078 attr_t attr; 13079 wchar_t chars[5]; 13080 } 13081 cchar_t; 13082 struct pdat 13083 { 13084 short _pad_y; 13085 short _pad_x; 13086 short _pad_top; 13087 short _pad_left; 13088 short _pad_bottom; 13089 short _pad_right; 13090 } 13091 ; 13092 13093 struct _win_st 13094 { 13095 short _cury; 13096 short _curx; 13097 short _maxy; 13098 short _maxx; 13099 short _begy; 13100 short _begx; 13101 short _flags; 13102 attr_t _attrs; 13103 chtype _bkgd; 13104 bool _notimeout; 13105 bool _clear; 13106 bool _leaveok; 13107 bool _scroll; 13108 bool _idlok; 13109 bool _idcok; 13110 bool _immed; 13111 bool _sync; 13112 bool _use_keypad; 13113 int _delay; 13114 struct ldat *_line; 13115 short _regtop; 13116 short _regbottom; 13117 int _parx; 13118 int _pary; 13119 WINDOW *_parent; 13120 struct pdat _pad; 13121 short _yoffset; 13122 cchar_t _bkgrnd; 13123 } 13124 ; 13125 #define KEY_CODE_YES 0400 13126 #define KEY_BREAK 0401 13127 #define KEY_MIN 0401 13128 #define KEY_DOWN 0402 13129 #define KEY_UP 0403 13130 #define KEY_LEFT 0404 13131 #define KEY_RIGHT 0405 13132 #define KEY_HOME 0406 13133 #define KEY_BACKSPACE 0407 13134 #define KEY_F0 0410 13135 #define KEY_DL 0510 13136 #define KEY_IL 0511 13137 #define KEY_DC 0512 13138 #define KEY_IC 0513 13139 #define KEY_EIC 0514 13140 #define KEY_CLEAR 0515 13141 #define KEY_EOS 0516 13142 #define KEY_EOL 0517 13143 #define KEY_SF 0520 13144 #define KEY_SR 0521 13145 #define KEY_NPAGE 0522 13146 #define KEY_PPAGE 0523 13147 #define KEY_STAB 0524 13148 #define KEY_CTAB 0525 13149 #define KEY_CATAB 0526 13150 #define KEY_ENTER 0527 13151 #define KEY_SRESET 0530 13152 #define KEY_RESET 0531 13153 #define KEY_PRINT 0532 13154 #define KEY_LL 0533 13155 #define KEY_A1 0534 13156 #define KEY_A3 0535 13157 #define KEY_B2 0536 13158 #define KEY_C1 0537 13159 #define KEY_C3 0540 13160 #define KEY_BTAB 0541 13161 #define KEY_BEG 0542 13162 #define KEY_CANCEL 0543 13163 #define KEY_CLOSE 0544 13164 #define KEY_COMMAND 0545 13165 #define KEY_COPY 0546 13166 #define KEY_CREATE 0547 13167 #define KEY_END 0550 13168 #define KEY_EXIT 0551 13169 #define KEY_FIND 0552 13170 #define KEY_HELP 0553 13171 #define KEY_MARK 0554 13172 #define KEY_MESSAGE 0555 13173 #define KEY_MOVE 0556 13174 #define KEY_NEXT 0557 13175 #define KEY_OPEN 0560 13176 #define KEY_OPTIONS 0561 13177 #define KEY_PREVIOUS 0562 13178 #define KEY_REDO 0563 13179 #define KEY_REFERENCE 0564 13180 #define KEY_REFRESH 0565 13181 #define KEY_REPLACE 0566 13182 #define KEY_RESTART 0567 13183 #define KEY_RESUME 0570 13184 #define KEY_SAVE 0571 13185 #define KEY_SBEG 0572 13186 #define KEY_SCANCEL 0573 13187 #define KEY_SCOMMAND 0574 13188 #define KEY_SCOPY 0575 13189 #define KEY_SCREATE 0576 13190 #define KEY_SDC 0577 13191 #define KEY_SDL 0600 13192 #define KEY_SELECT 0601 13193 #define KEY_SEND 0602 13194 #define KEY_SEOL 0603 13195 #define KEY_SEXIT 0604 13196 #define KEY_SFIND 0605 13197 #define KEY_SHELP 0606 13198 #define KEY_SHOME 0607 13199 #define KEY_SIC 0610 13200 #define KEY_SLEFT 0611 13201 #define KEY_SMESSAGE 0612 13202 #define KEY_SMOVE 0613 13203 #define KEY_SNEXT 0614 13204 #define KEY_SOPTIONS 0615 13205 #define KEY_SPREVIOUS 0616 13206 #define KEY_SPRINT 0617 13207 #define KEY_SREDO 0620 13208 #define KEY_SREPLACE 0621 13209 #define KEY_SRIGHT 0622 13210 #define KEY_SRSUME 0623 13211 #define KEY_SSAVE 0624 13212 #define KEY_SSUSPEND 0625 13213 #define KEY_SUNDO 0626 13214 #define KEY_SUSPEND 0627 13215 #define KEY_UNDO 0630 13216 #define KEY_MOUSE 0631 13217 #define KEY_RESIZE 0632 13218 #define KEY_MAX 0777 13219 13220 #define PAIR_NUMBER(a) (((a)& A_COLOR)>>8) 13221 #define NCURSES_BITS(mask,shift) ((mask)<<((shift)+8)) 13222 #define A_CHARTEXT (NCURSES_BITS(1UL,0)-1UL) 13223 #define A_NORMAL 0L 13224 #define NCURSES_ATTR_SHIFT 8 13225 #define A_COLOR NCURSES_BITS(((1UL)<<8)-1UL,0) 13226 #define A_BLINK NCURSES_BITS(1UL,11) 13227 #define A_DIM NCURSES_BITS(1UL,12) 13228 #define A_BOLD NCURSES_BITS(1UL,13) 13229 #define A_ALTCHARSET NCURSES_BITS(1UL,14) 13230 #define A_INVIS NCURSES_BITS(1UL,15) 13231 #define A_PROTECT NCURSES_BITS(1UL,16) 13232 #define A_HORIZONTAL NCURSES_BITS(1UL,17) 13233 #define A_LEFT NCURSES_BITS(1UL,18) 13234 #define A_LOW NCURSES_BITS(1UL,19) 13235 #define A_RIGHT NCURSES_BITS(1UL,20) 13236 #define A_TOP NCURSES_BITS(1UL,21) 13237 #define A_VERTICAL NCURSES_BITS(1UL,22) 13238 #define A_STANDOUT NCURSES_BITS(1UL,8) 13239 #define A_UNDERLINE NCURSES_BITS(1UL,9) 13240 #define COLOR_PAIR(n) NCURSES_BITS(n,0) 13241 #define A_ATTRIBUTES NCURSES_BITS(~(1UL-1UL),0) 13242 13243 ------------------------------------------------------------------------------- 13244 13245 Interfaces for libutil 13246 13247 Table 2-6 defines the library name and shared object name for the libutil 13248 library 13249 13250 Table 2-6. libutil Definition 13251 13252 +----------------------+ 13253 |Library:|libutil | 13254 |--------+-------------| 13255 |SONAME: |libutil.so.1 | 13256 +----------------------+ 13257 13258 The behavior of the interfaces in this library is specified by the following 13259 specifications: 13260 13261 this specification 13262 13263 ------------------------------------------------------------------------------- 13264 13265 Utility Functions 13266 13267 ------------------------------------------------------------------------------- 13268 13269 Interfaces for Utility Functions 13270 13271 An LSB conforming implementation shall provide the generic functions for 13272 Utility Functions specified in Table 2-7, with the full functionality as 13273 described in the referenced underlying specification. 13274 13275 Table 2-7. libutil - Utility Functions Function Interfaces 13276 13277 +-----------------------------------------+ 13278 |forkpty [1]|login_tty [1]|logwtmp [1]| | | 13279 |-----------+-------------+-----------+-+-| 13280 |login [1] |logout [1] |openpty [1]| | | 13281 +-----------------------------------------+ 13282 13283 Referenced Specification(s) 13284 13285 [1]. this specification 13286 13287 ------------------------------------------------------------------------------- 13288 13289 Interface Definitions for libutil 13290 13291 Table of Contents 13292 forkpty -- Create a new process attached to an available pseudo-terminal 13293 login -- login utility function 13294 login_tty -- Prepare a terminal for login 13295 logout -- logout utility function 13296 logwtmp -- append an entry to the wtmp file 13297 openpty -- find and open an available pseudo-terminal 13298 13299 The following interfaces are included in libutil and are defined by this 13300 specification. Unless otherwise noted, these interfaces shall be included in 13301 the source standard. 13302 13303 Other interfaces listed above for libutil shall behave as described in the 13304 referenced base document. 13305 13306 forkpty 13307 13308 Name 13309 13310 forkpty -- Create a new process attached to an available pseudo-terminal 13311 13312 Synopsis 13313 13314 #include 13315 13316 int forkpty(int * amaster, char * name, struct termios * termp, struct winsize 13317 * winp); 13318 13319 Description 13320 13321 The forkpty() function shall find and open a pseudo-terminal device pair in the 13322 same manner as the openpty() function. If a pseudo-terminal is available, 13323 forkpty shall create a new process in the same manner as the fork() function, 13324 and prepares the new process for login in the same manner as login_tty(). 13325 13326 If termp is not null, it shall refer to a termios structure that shall be used 13327 to initialize the characteristics of the slave device. If winp is not null, it 13328 shall refer to a winsize structure used to initialize the window size of the 13329 slave device. 13330 13331 Return Value 13332 13333 On success, the parent process shall return the process id of the child, and 13334 the child shall return 0. On error, no new process shall be created, -1 shall 13335 be returned, and errno shall be set appropriately. On success, the parent 13336 process shall receive the file descriptor of the master side of the 13337 pseudo-terminal in the location referenced by amaster, and, if name is not 13338 NULL, the filename of the slave device in name. 13339 13340 Errors 13341 13342 EAGAIN 13343 13344 Unable to create a new process. 13345 13346 ENOENT 13347 13348 There are no available pseudo-terminals. 13349 13350 ENOMEM 13351 13352 Insufficient memory was available. 13353 13354 login 13355 13356 Name 13357 13358 login -- login utility function 13359 13360 Synopsis 13361 13362 #include 13363 13364 void login (struct utmp * ut ); 13365 13366 Description 13367 13368 The login function shall update the user accounting databases. The ut parameter 13369 shall reference a utmp structure for all fields except the following: 13370 13371 1. The ut_type field shall be set to USER_PROCESS. 13372 13373 2. The ut_pid field shall be set to the process identifier for the current 13374 process. 13375 13376 3. The ut_line field shall be set to the name of the controlling terminal 13377 device. The name shall be found by examaning the device associated with the 13378 standard input, output and error streams in sequence, until one associated 13379 with a terminal device is found. If none of these streams refers to a 13380 terminal device, the ut_line field shall be set to "???". If the terminal 13381 device is in the /dev directory hierarchy, the ut_line field shall not 13382 contain the leading "/dev/", otherwise it shall be set to the final 13383 component of the pathname of the device. If the user accounting database 13384 imposes a limit on the size of the ut_line field, it shall truncate the 13385 name, but any such limit shall not be smaller than UT_LINESIZE (including a 13386 terminating null character). 13387 13388 Return Value 13389 13390 None 13391 13392 Errors 13393 13394 None 13395 13396 login_tty 13397 13398 Name 13399 13400 login_tty -- Prepare a terminal for login 13401 13402 Synopsis 13403 13404 #include 13405 13406 int login_tty (int fdr); 13407 13408 Description 13409 13410 The login_tty() function shall prepare the terminal device referenced by the 13411 file descriptor fdr. This function shall create a new session, make the 13412 terminal the controlling terminal for the current process, and set the standard 13413 input, output, and error streams of the current process to the terminal. If fdr 13414 is not the standard input, output or error stream, then login_tty() shall close 13415 fdr. 13416 13417 Return Value 13418 13419 On success, login_tty() shall return zero; otherwise -1 is returned, and errno 13420 shall be set appropriately. 13421 13422 Errors 13423 13424 ENOTTY 13425 13426 fdr does not refer to a terminal device. 13427 13428 logout 13429 13430 Name 13431 13432 logout -- logout utility function 13433 13434 Synopsis 13435 13436 #include 13437 13438 int logout (const char * line ); 13439 13440 Description 13441 13442 Given the device line, the logout function shall search the user accounting 13443 database which is read by getutent for an entry with the corresponding line, 13444 and with the type of USER_PROCESS. If a corresponding entry is located, it 13445 shall be updated as follows: 13446 13447 1. The ut_name field shall be set to zeroes (UT_NAMESIZE NUL bytes). 13448 13449 2. The ut_host field shall be set to zeroes (UT_HOSTSIZE NUL bytes). 13450 13451 3. The ut_tv shall be set to the current time of day. 13452 13453 4. The ut_type field shall be set to DEAD_PROCESS. 13454 13455 Return Value 13456 13457 On success, the logout() function shall return non-zero. Zero is returned if 13458 there was no entry to remove, or if the utmp file could not be opened or 13459 updated. 13460 13461 logwtmp 13462 13463 Name 13464 13465 logwtmp -- append an entry to the wtmp file 13466 13467 Synopsis 13468 13469 #include 13470 13471 void logwtmp (const char * line , const char * name , const char * host ); 13472 13473 Description 13474 13475 If the process has permission to update the user accounting databases, the 13476 logwtmp function shall append a record to the user accounting database that 13477 records all logins and logouts. The record to be appended shall be constructed 13478 as follows: 13479 13480 1. The ut_line field shall be intitialized from line. If the user accounting 13481 database imposes a limit on the size of the ut_line field, it shall 13482 truncate the value, but any such limit shall not be smaller than 13483 UT_LINESIZE (including a terminating null character). 13484 13485 2. The ut_name field shall be intitialized from name. If the user accounting 13486 database imposes a limit on the size of the ut_name field, it shall 13487 truncate the value, but any such limit shall not be smaller than 13488 UT_NAMESIZE (including a terminating null character). 13489 13490 3. The ut_host field shall be intitialized from host. If the user accounting 13491 database imposes a limit on the size of the ut_host field, it shall 13492 truncate the value, but any such limit shall not be smaller than 13493 UT_HOSTSIZE (including a terminating null character). 13494 13495 4. If the name parameter does not refer to an empty string (i.e. ""), the 13496 ut_type field shall be set to USER_PROCESS; otherwise the ut_type 13497 fieldshall be set to DEAD_PROCESS. 13498 13499 5. The ut_id field shall be set to the process identifier for the current 13500 process. 13501 13502 6. The ut_tv field shall be set to the current time of day. 13503 13504 Note: If a process does not have write access to the the user accounting 13505 database, the logwtmp function will not update it. Since the function does 13506 not return any value, an application has no way of knowing whether it 13507 succeeded or failed. 13508 13509 Return Value 13510 13511 None. 13512 13513 openpty 13514 13515 Name 13516 13517 openpty -- find and open an available pseudo-terminal 13518 13519 Synopsis 13520 13521 #include 13522 13523 int openpty(int *amaster, int *aslave, char *name, struct termios *termp, 13524 struct winsize *winp); 13525 13526 Description 13527 13528 The openpty() function shall find an available pseudo-terminal and return file 13529 descriptors for the master and slave devices in the locations referenced by 13530 amaster and aslave respectively. If name is not NULL, the filename of the slave 13531 shall be placed in the user supplied buffer referenced by name. If termp is not 13532 NULL, it shall point to a termios structure used to initialize the terminal 13533 parameters of the slave pseudo-terminal device. If winp is not NULL, it shall 13534 point to a winsize structure used to initialize the window size parameters of 13535 the slave pseudo-terminal device. 13536 13537 Return Value 13538 13539 On success, zero is returned. On error, -1 is returned, and errno is set 13540 appropriately. 13541 13542 Errors 13543 13544 ENOENT 13545 13546 There are no available pseudo-terminals. 13547 13548 III. Commands and Utilities 13549 13550 Table of Contents 13551 3. Commands and Utilities 13552 13553 ------------------------------------------------------------------------------- 13554 13555 Chapter 3. Commands and Utilities 13556 13557 Commands and Utilities 13558 13559 Table 3-1 lists the Commands and Utilities required to be present on a 13560 conforming system. These commands and utilities shall behave as described in 13561 the relevant underlying specification, with the following exceptions: 13562 13563 1. If any operand (except one which follows --) starts with a hyphen, the 13564 behavior is unspecified. 13565 13566 13567 Rationale (Informative): Applications should place options before 13568 operands, or use --, as needed. This text is needed because GNU option 13569 parsing differs from POSIX. For example, ls . -a in GNU ls means to 13570 list the current directory, showing all files (that is, "." is an 13571 operand and -a is an option). In POSIX, "." and -a are both operands, 13572 and the command means to list the current directory, and also the file 13573 named -a. Suggesting that applications rely on the setting of the 13574 POSIXLY_CORRECT environment variable, or try to set it, seems worse 13575 than just asking the applictions to invoke commands in ways which work 13576 with either the POSIX or GNU behaviors. 13577 13578 The behavior of the interfaces described in this section is specified by the 13579 following standards. 13580 13581 this specification 13582 ISO POSIX (2003) 13583 13584 Table 3-1. Commands and Utilities 13585 13586 +-----------------------------------------------------------------------------+ 13587 |[ [1] |ar [2] |at [2] |awk [2] |basename [1] | 13588 |-----------------+------------+---------------+-------------+----------------| 13589 |batch [2] |bc [2] |cat [1] |chfn [2] |chgrp [2] | 13590 |-----------------+------------+---------------+-------------+----------------| 13591 |chmod [1] |chown [2] |chsh [2] |cksum [1] |cmp [1] | 13592 |-----------------+------------+---------------+-------------+----------------| 13593 |col [2] |comm [1] |cp [1] |cpio [2] |crontab [2] | 13594 |-----------------+------------+---------------+-------------+----------------| 13595 |csplit [1] |cut [2] |date [1] |dd [1] |df [2] | 13596 |-----------------+------------+---------------+-------------+----------------| 13597 |diff [1] |dirname [1] |dmesg [2] |du [2] |echo [2] | 13598 |-----------------+------------+---------------+-------------+----------------| 13599 |egrep [2] |env [1] |expand [1] |expr [1] |false [1] | 13600 |-----------------+------------+---------------+-------------+----------------| 13601 |fgrep [2] |file [2] |find [2] |fold [1] |fuser [2] | 13602 |-----------------+------------+---------------+-------------+----------------| 13603 |gencat [1] |getconf [1] |gettext [2] |grep [2] |groupadd [2] | 13604 |-----------------+------------+---------------+-------------+----------------| 13605 |groupdel [2] |groupmod [2]|groups [2] |gunzip [2] |gzip [2] | 13606 |-----------------+------------+---------------+-------------+----------------| 13607 |head [1] |hostname [2]|iconv [1] |id [1] |install [2] | 13608 |-----------------+------------+---------------+-------------+----------------| 13609 |install_initd [2]|ipcrm [2] |ipcs [2] |join [1] |kill [1] | 13610 |-----------------+------------+---------------+-------------+----------------| 13611 |killall [2] |ln [1] |locale [1] |localedef [1]|logname [1] | 13612 |-----------------+------------+---------------+-------------+----------------| 13613 |lpr [2] |ls [2] |lsb_release [2]|m4 [2] |make [1] | 13614 |-----------------+------------+---------------+-------------+----------------| 13615 |man [1] |md5sum [2] |mkdir [1] |mkfifo [1] |mknod [2] | 13616 |-----------------+------------+---------------+-------------+----------------| 13617 |mktemp [2] |more [2] |mount [2] |msgfmt [2] |mv [1] | 13618 |-----------------+------------+---------------+-------------+----------------| 13619 |newgrp [2] |nice [1] |nl [1] |nohup [1] |od [2] | 13620 |-----------------+------------+---------------+-------------+----------------| 13621 |passwd [2] |paste [1] |patch [2] |pathchk [1] |pidof [2] | 13622 |-----------------+------------+---------------+-------------+----------------| 13623 |pr [1] |printf [1] |ps [1] |pwd [1] |remove_initd [2]| 13624 |-----------------+------------+---------------+-------------+----------------| 13625 |renice [2] |rm [1] |rmdir [1] |sed [2] |sendmail [2] | 13626 |-----------------+------------+---------------+-------------+----------------| 13627 |sh [1] |shutdown [2]|sleep [1] |sort [1] |split [1] | 13628 |-----------------+------------+---------------+-------------+----------------| 13629 |strip [1] |stty [1] |su [2] |sync [2] |tail [1] | 13630 |-----------------+------------+---------------+-------------+----------------| 13631 |tar [2] |tee [1] |test [1] |time [1] |touch [1] | 13632 |-----------------+------------+---------------+-------------+----------------| 13633 |tr [1] |true [1] |tsort [1] |tty [1] |umount [2] | 13634 |-----------------+------------+---------------+-------------+----------------| 13635 |uname [1] |unexpand [1]|uniq [1] |useradd [2] |userdel [2] | 13636 |-----------------+------------+---------------+-------------+----------------| 13637 |usermod [2] |wc [1] |xargs [2] | | | 13638 +-----------------------------------------------------------------------------+ 13639 13640 Referenced Specification(s) 13641 13642 [1]. ISO POSIX (2003) 13643 13644 [2]. this specification 13645 13646 ------------------------------------------------------------------------------- 13647 13648 Command Behavior 13649 13650 Table of Contents 13651 ar -- create and maintain library archives (LSB DEPRECATED) 13652 at -- examine or delete jobs for later execution 13653 awk -- pattern scanning and processing language 13654 batch -- schedule commands to be executed in a batch queue 13655 bc -- An arbitrary precision calculator language 13656 chfn -- change user name and information 13657 chgrp -- change file group 13658 chown -- change file owner and group 13659 chsh -- change login shell 13660 col -- filter reverse line feeds from input 13661 cpio -- copy file archives in and out 13662 crontab -- maintain crontab files for individual users 13663 cut -- split a file into sections determined by context lines 13664 df -- report filesystem disk space usage 13665 dmesg -- print or control the system message buffer 13666 du -- estimate file space usage 13667 echo -- display a line of text 13668 egrep -- search a file with an ERE pattern 13669 fgrep -- search a file with a fixed pattern 13670 file -- determine file type 13671 find -- search for files in a directory hierarchy 13672 fuser -- identify processes using files or sockets 13673 gettext -- retrieve text string from message catalog 13674 grep -- print lines matching a pattern 13675 groupadd -- create a new group 13676 groupdel -- delete a group 13677 groupmod -- modify a group 13678 groups -- display a group 13679 gunzip -- uncompress files 13680 gzip -- compress or expand files 13681 hostname -- show or set the system's host name 13682 install -- copy files and set attributes 13683 install_initd -- install an init.d file 13684 ipcrm -- Remove IPC Resources 13685 ipcs -- provide information on ipc facilities 13686 killall -- kill processes by name 13687 lpr -- off line print 13688 ls -- list directory contents 13689 lsb_release -- print distribution specific information 13690 m4 -- macro processor 13691 md5sum -- generate or check MD5 message digests 13692 mknod -- make special files 13693 mktemp -- make temporary file name (unique) 13694 more -- display files on a page-by-page basis 13695 mount -- mount a file system 13696 msgfmt -- create a message object from a message file 13697 newgrp -- change group ID 13698 od -- dump files in octal and other formats 13699 passwd -- change user password 13700 patch -- apply a diff file to an original 13701 pidof -- find the process ID of a running program 13702 remove_initd -- clean up boot script system modifications introduced by 13703 install_initd 13704 renice -- alter priority of running processes 13705 sed -- stream editor 13706 sendmail -- an electronic mail transport agent 13707 shutdown -- bring the system down 13708 su -- change user ID or become super-user 13709 sync -- flush filesystem buffers 13710 tar -- file archiver 13711 umount -- unmount file systems 13712 useradd -- create a new user or update default new user information 13713 userdel -- delete a user account and related files 13714 usermod -- modify a user account 13715 xargs -- build and execute command lines from standard input 13716 13717 This section contains descriptions for commands and utilities whose specified 13718 behavior in the LSB contradicts or extends the standards referenced. It also 13719 contains commands and utilities only required by the LSB and not specified by 13720 other standards. 13721 13722 ar 13723 13724 Name 13725 13726 ar -- create and maintain library archives (LSB DEPRECATED) 13727 13728 Description 13729 13730 ar is deprecated from the LSB and is expected to disappear from a future 13731 version of the LSB. 13732 13733 13734 Rationale: The LSB generally does not include software development 13735 utilities nor does it specify .o and .a file formats. 13736 13737 ar is as specified in ISO POSIX (2003) but with differences as listed below. 13738 13739 Differences 13740 13741 -T, -C 13742 13743 need not be accepted. 13744 13745 -l 13746 13747 has unspecified behavior. 13748 13749 -q 13750 13751 has unspecified behavior; using -r is suggested. 13752 13753 at 13754 13755 Name 13756 13757 at -- examine or delete jobs for later execution 13758 13759 Description 13760 13761 at is as specified in ISO POSIX (2003) but with differences as listed below. 13762 13763 Differences 13764 13765 -d 13766 13767 is functionally equivalent to the -r option specified in ISO POSIX (2003). 13768 13769 -r 13770 13771 need not be supported, but the '-d' option is equivalent. 13772 13773 -t time 13774 13775 need not be supported. 13776 13777 Files 13778 13779 The files at.allow and at.deny reside in /etc rather than /usr/lib/cron. 13780 13781 awk 13782 13783 Name 13784 13785 awk -- pattern scanning and processing language 13786 13787 Description 13788 13789 awk is as specified in ISO POSIX (2003) but with differences as listed below. 13790 13791 Differences 13792 13793 Certain aspects of internationalized regular expressions are optional; see 13794 Internationalization and Regular Expressions>. 13795 13796 batch 13797 13798 Name 13799 13800 batch -- schedule commands to be executed in a batch queue 13801 13802 Description 13803 13804 The specification for batch is as specified in ISO POSIX (2003), but with the 13805 following differences as listed below. 13806 13807 Files 13808 13809 The files at.allow and at.deny reside in /etc rather than /usr/lib/cron. 13810 13811 bc 13812 13813 Name 13814 13815 bc -- An arbitrary precision calculator language 13816 13817 Description 13818 13819 bc is as specified in ISO POSIX (2003) but with differences as listed below. 13820 13821 Differences 13822 13823 The bc language may be extended in an implementation defined manner. If an 13824 implementation supports extensions, it shall also support the additional 13825 options: 13826 13827 -s|--standard 13828 13829 processes exactly the POSIX bc language. 13830 13831 -w|--warn 13832 13833 gives warnings for extensions to POSIX bc. 13834 13835 chfn 13836 13837 Name 13838 13839 chfn -- change user name and information 13840 13841 Synopsis 13842 13843 chfn [-f full_name] [-h home_phone] [user] 13844 13845 Description 13846 13847 chfn shall update the user database. An unprivileged user may only change the 13848 fields for their own account, a user with appropriate privileges may change the 13849 fields for any account. 13850 13851 The fields full_name and home_phone may contain any character except: 13852 13853 any control character 13854 comma 13855 colon 13856 equal sign 13857 13858 If none of the options are selected, chfn operates in an interactive fashion. 13859 The prompts and expected input in interactive mode are unspecified and should 13860 not be relied upon. 13861 13862 As it is possible for the system to be configured to restrict which fields a 13863 non-privileged user is permitted to change, applications should be written to 13864 gracefully handle these situations. 13865 13866 Standard Options 13867 13868 -f full_name 13869 13870 sets the user's full name. 13871 13872 -h home_phone 13873 13874 sets the user's home phone number. 13875 13876 Future Directions 13877 13878 The following two options are expected to be added in a future version of the 13879 LSB: 13880 13881 -o office 13882 13883 sets the user's office room number. 13884 13885 -p office_phone 13886 13887 sets the user's office phone number. 13888 13889 Note that some implementations contain a "-o other" option which specifies an 13890 additional field called "other". Traditionally, this field is not subject to 13891 the constraints about legitimate characters in fields. Also, one traditionally 13892 shall have appropriate privileges to change the other field. At this point 13893 there is no consensus about whether it is desirable to specify the other field; 13894 applications may wish to avoid using it. 13895 13896 The "-w work_phone" field found in some implementations should be replaced by 13897 the "-p office_phone" field. The "-r room_number" field found in some 13898 implementations is the equivalent of the "-o office" option mentioned above; 13899 which one of these two options to specify will depend on implementation 13900 experience and the decision regarding the other field. 13901 13902 chgrp 13903 13904 Name 13905 13906 chgrp -- change file group 13907 13908 Description 13909 13910 chgrp is as specified in ISO POSIX (2003) but with differences as listed below. 13911 13912 Differences 13913 13914 The -L, -H, and -P options need not be supported. 13915 13916 chown 13917 13918 Name 13919 13920 chown -- change file owner and group 13921 13922 Description 13923 13924 chown is as specified in ISO POSIX (2003) but with differences as listed below. 13925 13926 Differences 13927 13928 The -L, -H, and -P options need not be supported. 13929 13930 chsh 13931 13932 Name 13933 13934 chsh -- change login shell 13935 13936 Synopsis 13937 13938 chsh [-s login_shell] [user] 13939 13940 Description 13941 13942 chsh changes the user login shell. This determines the name of the user's 13943 initial login command. An unprivileged user may only change the login shell for 13944 their own account, a user with appropriate privilege may change the login shell 13945 for any account specified by user. 13946 13947 Unless the user has appropriate privilege, the initial login command name shall 13948 be one of those listed in /etc/shells. The login_shell shall be the absolute 13949 path (i.e. it must start with '/') to an executable file. Accounts which are 13950 restricted (in an implementation-defined manner) may not change their login 13951 shell. 13952 13953 If the -s option is not selected, chsh operates in an interactive mode. The 13954 prompts and expected input in this mode are unspecified. 13955 13956 Standard Options 13957 13958 -s login_shell 13959 13960 sets the login shell. 13961 13962 col 13963 13964 Name 13965 13966 col -- filter reverse line feeds from input 13967 13968 Description 13969 13970 col is as specified in the SUSv2 with the difference that the -p option has 13971 unspecified behavior. 13972 13973 Although col is shown as legacy in SUSv2, Version 2, it is not (yet) deprecated 13974 in the LSB. 13975 13976 cpio 13977 13978 Name 13979 13980 cpio -- copy file archives in and out 13981 13982 Description 13983 13984 cpio is as specified in ISO POSIX (2003), but with differences as listed below. 13985 13986 Differences 13987 13988 Some elements of the Pattern Matching Notation are optional; see 13989 Internationalization and Pattern Matching Notation. 13990 13991 crontab 13992 13993 Name 13994 13995 crontab -- maintain crontab files for individual users 13996 13997 Synopsis 13998 13999 crontab [-u user] file 14000 14001 crontab [-u user] {-l | -r | -e} 14002 14003 Description 14004 14005 crontab is as specified in ISO POSIX (2003), but with differences as listed 14006 below. 14007 14008 Files 14009 14010 The files cron.allow and cron.deny reside in /etc rather than /usr/lib/cron. 14011 14012 cut 14013 14014 Name 14015 14016 cut -- split a file into sections determined by context lines 14017 14018 Description 14019 14020 cut is as specified in ISO POSIX (2003), but with differences as listed below. 14021 14022 Differences 14023 14024 -n 14025 14026 has unspecified behavior. 14027 14028 df 14029 14030 Name 14031 14032 df -- report filesystem disk space usage 14033 14034 Description 14035 14036 df is as specified in ISO POSIX (2003), but with the following differences. 14037 14038 If the -k option is not specified, disk space is shown in unspecified units. 14039 Applications should specify -k. 14040 14041 If an argument is the absolute file name of a disk device node containing a 14042 mounted filesystem, df shows the space available on that filesystem rather than 14043 on the filesystem containing the device node (which is always the root 14044 filesystem). 14045 14046 dmesg 14047 14048 Name 14049 14050 dmesg -- print or control the system message buffer 14051 14052 Synopsis 14053 14054 dmesg [-c | -n level | -s bufsize] 14055 14056 Description 14057 14058 dmesg examines or controls the system message buffer. Only a user with 14059 appropriate privileges may modify the system message buffer parameters or 14060 contents. 14061 14062 Standard Options 14063 14064 -c 14065 14066 If the user has appropriate privilege, clears the system message buffer 14067 contents after printing. 14068 14069 -n level 14070 14071 If the user has appropriate privilege, sets the level at which logging of 14072 messages is done to the console. 14073 14074 -s bufsize 14075 14076 uses a buffer of bufsize to query the system message buffer. This is 16392 14077 by default (this matches the default kernel syslog buffer size since 14078 2.1.113). If you have set the kernel buffer to larger than the default then 14079 this option can be used to view the entire buffer. 14080 14081 du 14082 14083 Name 14084 14085 du -- estimate file space usage 14086 14087 Description 14088 14089 du is as specified in ISO POSIX (2003), but with differences as listed below. 14090 14091 Differences 14092 14093 If the -k option is not specified, disk space is shown in unspecified units. 14094 Applications should specify -k. 14095 14096 echo 14097 14098 Name 14099 14100 echo -- display a line of text 14101 14102 Synopsis 14103 14104 echo [STRING...] 14105 14106 Description 14107 14108 The echo command is as specified in ISO POSIX (2003), but with the following 14109 differences. 14110 14111 Unlike the behavior specified in ISO POSIX (2003), whether echo supports 14112 options is implementation defined. The behavior of echo if any arguments 14113 contain backslashes is also implementation defined. Conforming applications 14114 shall not run echo with a first argument starting with a hyphen, or with any 14115 arguments containing backslashes; they shall use printf in those cases. 14116 14117 14118 Note: The behavior specified here is similar to that specified by ISO POSIX 14119 (2003) without the XSI option. However, the LSB forbids all options and the 14120 latter forbids only -n. 14121 14122 egrep 14123 14124 Name 14125 14126 egrep -- search a file with an ERE pattern 14127 14128 Description 14129 14130 egrep is equivalent to grep -E. For further details, see the specification for 14131 grep. 14132 14133 fgrep 14134 14135 Name 14136 14137 fgrep -- search a file with a fixed pattern 14138 14139 Description 14140 14141 fgrep is equivalent to grep -F. For further details, see the specification for 14142 grep. 14143 14144 file 14145 14146 Name 14147 14148 file -- determine file type 14149 14150 Description 14151 14152 file is as specified in ISO POSIX (2003), but with differences as listed below. 14153 14154 Differences 14155 14156 The -M, -h, -d, and -i options need not be supported. 14157 14158 find 14159 14160 Name 14161 14162 find -- search for files in a directory hierarchy 14163 14164 Description 14165 14166 find is as specified in ISO POSIX (2003), but with additional options as 14167 specified below. 14168 14169 Differences 14170 14171 Some elements of the Pattern Matching Notation are optional; see 14172 Internationalization and Pattern Matching Notation. 14173 14174 fuser 14175 14176 Name 14177 14178 fuser -- identify processes using files or sockets 14179 14180 Description 14181 14182 fuser is as specified in ISO POSIX (2003), but with differences as listed 14183 below. 14184 14185 Differences 14186 14187 -c 14188 14189 has unspecified behavior. 14190 14191 -f 14192 14193 has unspecified behavior. 14194 14195 gettext 14196 14197 Name 14198 14199 gettext -- retrieve text string from message catalog 14200 14201 Synopsis 14202 14203 gettext [options] [textdomain] msgid 14204 14205 gettext -s [options] msgid... 14206 14207 Description 14208 14209 The gettext utility retrieves a translated text string corresponding to string 14210 msgid from a message object generated with msgfmt utility. 14211 14212 The message object name is derived from the optional argument textdomain if 14213 present, otherwise from the TEXTDOMAIN environment variable. If no domain is 14214 specified, or if a corresponding string cannot be found, gettext prints msgid. 14215 14216 Ordinarily gettext looks for its message object in dirname/lang/LC_MESSAGES 14217 where dirname is the implementation-defined default directory and lang is the 14218 locale name. If present, the TEXTDOMAINDIR environment variable replaces the 14219 dirname. 14220 14221 This utility interprets C escape sequences such as \t for tab. Use \\ to print 14222 a backslash. To produce a message on a line of its own, either put a \n at the 14223 end of msgid, or use this command in conjunction with the printf utility. 14224 14225 When used with the -s option the gettext utility behaves like the echo utility, 14226 except that the message corresponding to msgid in the selected catalog provides 14227 the arguments. 14228 14229 Options 14230 14231 -d domainname, --domain=domainname 14232 14233 PARAMETER translated messages from domainname. 14234 14235 -e 14236 14237 Enable expansion of some escape sequences. 14238 14239 -n 14240 14241 Suppress trailing newline. 14242 14243 Operands 14244 14245 The following operands are supported: 14246 14247 textdomain 14248 14249 A domain name used to retrieve the messages. 14250 14251 msgid 14252 14253 A key to retrieve the localized message. 14254 14255 Environment Variables 14256 14257 LANGUAGE 14258 14259 Specifies one or more locale names. 14260 14261 LANG 14262 14263 Specifies locale name. 14264 14265 LC_MESSAGES 14266 14267 Specifies messaging locale, and if present overrides LANG for messages. 14268 14269 TEXTDOMAIN 14270 14271 Specifies the text domain name, which is identical to the message object 14272 filename without .mo suffix. 14273 14274 TEXTDOMAINDIR 14275 14276 Specifies the pathname to the message catalog, and if present replaces the 14277 implementation-defined default directory. 14278 14279 Exit Status 14280 14281 The following exit values are returned: 14282 14283 0 14284 14285 Successful completion. 14286 14287 >0 14288 14289 An error occurred. 14290 14291 grep 14292 14293 Name 14294 14295 grep -- print lines matching a pattern 14296 14297 Description 14298 14299 grep is as specified in ISO POSIX (2003), but with differences as listed below. 14300 14301 LSB Differences 14302 14303 Some elements of the Pattern Matching Notation are optional; see 14304 Internationalization and Pattern Matching Notation. 14305 14306 groupadd 14307 14308 Name 14309 14310 groupadd -- create a new group 14311 14312 Synopsis 14313 14314 groupadd [-g gid [-o]] group 14315 14316 Description 14317 14318 If the caller has appropriate privilege, the groupadd command shall create a 14319 new group named group. The group name shall be unique in the group database. If 14320 no gid is specified, groupadd shall create the new group with a unique group 14321 ID. 14322 14323 Options 14324 14325 -g gid [-o] 14326 14327 The new group shall have group ID gid. If the -o option is not used, no 14328 other group shall have this group ID. The value of gidshall be 14329 non-negative. 14330 14331 groupdel 14332 14333 Name 14334 14335 groupdel -- delete a group 14336 14337 Synopsis 14338 14339 groupdel group 14340 14341 Description 14342 14343 If the caller has sufficient privilege, the groupdel command shall modify the 14344 system group database, deleting the group named group. If the group named group 14345 does not exist, groupdel shall issue a diagnostic message and exit with a 14346 non-zero exit status. 14347 14348 groupmod 14349 14350 Name 14351 14352 groupmod -- modify a group 14353 14354 Synopsis 14355 14356 groupmod [-g gid [-o]] [-n group_name] group 14357 14358 Description 14359 14360 If the caller has appropriate privilege, the groupmod command shall modify the 14361 entry in the system group database corresponding to a group named group. 14362 14363 Options 14364 14365 -g gid [-o] 14366 14367 Modify the group's group ID, setting it to gid. If the -o option is not 14368 used, no other group shall have this group ID. The value of gidshall be 14369 non-negative. 14370 14371 14372 Note: Only the group ID in the database is altered; any files with 14373 group ownership set to the original group ID are unchanged by this 14374 modification. 14375 14376 -n group_name 14377 14378 changes the name of the group from group to group_name. 14379 14380 groups 14381 14382 Name 14383 14384 groups -- display a group 14385 14386 Synopsis 14387 14388 groups [user] 14389 14390 Description 14391 14392 The groups command shall behave as id -Gn [user], as specified in ISO POSIX 14393 (2003). The optional user parameter will display the groups for the named user. 14394 14395 gunzip 14396 14397 Name 14398 14399 gunzip -- uncompress files 14400 14401 Description 14402 14403 gunzip is equivalent to gzip -d. See the specification for gzip for further 14404 details. 14405 14406 gzip 14407 14408 Name 14409 14410 gzip -- compress or expand files 14411 14412 Synopsis 14413 14414 gzip [-acdfhlLnNrtvV19] [-S suffix] [name...] 14415 14416 Description 14417 14418 The gzip command shall attempt to reduce the size of the named files. Whenever 14419 possible, each file is replaced by one with the extension .gz, while keeping 14420 the same ownership modes, access and modification times. If no files are 14421 specified, or if a file name is -, the standard input is compressed to the 14422 standard output. gzip shall only attempt to compress regular files. In 14423 particular, it will ignore symbolic links. 14424 14425 When compressing, gzip uses the deflate algorithm specified in RFC 1951: 14426 DEFLATE Compressed Data Format Specification and stores the result in a file 14427 using the gzip file format specified in RFC 1952: GZIP File Format 14428 Specification. 14429 14430 Options 14431 14432 -a, --ascii 14433 14434 does nothing on LSB conforming systems. 14435 14436 14437 Note: This option may be deprecated in a future verion of this 14438 specification. 14439 14440 -c, --stdout, --to-stdout 14441 14442 writes output on standard output, leaving the original files unchanged. If 14443 there are several input files, the output consists of a sequence of 14444 independently compressed members. To obtain better compression, concatenate 14445 all input files before compressing them. 14446 14447 -d, --decompress, --uncompress 14448 14449 the name operands are compressed files, and gzip shall decompress them. 14450 14451 -f, --force 14452 14453 forces compression or decompression even if the file has multiple links or 14454 the corresponding file already exists, or if the compressed data is read 14455 from or written to a terminal. If the input data is not in a format 14456 recognized by gzip, and if the option --stdout is also given, copy the 14457 input data without change to the standard ouput: let gzip behave as cat. If 14458 -f is not given, and when not running in the background, gzip prompts to 14459 verify whether an existing file should be overwritten. 14460 14461 -l, --list 14462 14463 lists the compressed size, uncompressed size, ration and uncompressed name 14464 for each compressed file. Gives the uncompressed size as -1 for files not 14465 in gzip format. Additionally displays method, crc and timestamp for the 14466 uncompress file when used in combination with --verbose. 14467 14468 For decompression, gzip shall support at least the following compression 14469 methods: 14470 14471 + deflate (RFC 1951: DEFLATE Compressed Data Format Specification) 14472 14473 + compress (ISO POSIX (2003)) 14474 14475 + lzh (SCO compress -H) 14476 14477 + pack (Huffman encoding) 14478 14479 The crc shall be given as ffffffff for a file not in gzip format. 14480 14481 With --name, the uncompressed name, date and time are those stored within 14482 the compress file, if present. 14483 14484 With --verbose, the size totals and compression ratio for all files is also 14485 displayed, unless some sizes are unknown. With --quiet, the title and 14486 totals lines are not displayed. 14487 14488 -L, --license 14489 14490 displays the gzip license and quit. 14491 14492 -n, --no-name 14493 14494 does not save the original file name and time stamp by default when 14495 compressing. (The original name is always saved if the name had to be 14496 truncated.) When decompressing, do not restore the original file name if 14497 present (remove only the gzip suffix from the compressed file name) and do 14498 not restore the original time stamp if present (copy it from the compressed 14499 file). This option is the default when decompressing. 14500 14501 -N, --name 14502 14503 always saves the original file name and time stamp when compressing; this 14504 is the default. When decompressing, restore the original file name and time 14505 stamp if present. This option is useful on systems which have a limit on 14506 file name length or when the time stamp has been lost after a file 14507 transfer. 14508 14509 -q, --quiet 14510 14511 suppresses all warnings. 14512 14513 -r, --recursive 14514 14515 travels the directory structure recursively. If any of the file names 14516 specified on the command line are directories, gzip will descend into the 14517 directory and compress all the files it finds there (or decompress them in 14518 the case of gunzip). 14519 14520 -S .suf, --sufix .suf 14521 14522 uses suffix .suf instead of .gz. 14523 14524 -t, --test 14525 14526 checks the compressed file integrity. 14527 14528 -v, --verbose 14529 14530 displays the name and percentage reduction for each file compressed or 14531 decompressed. 14532 14533 -#, --fast, --best 14534 14535 regulates the speed of compression using the specified digit #, where -1 or 14536 --fast indicates the fastest compression method (less compression) and -9 14537 or --best indicates the slowest compression method (best compression). The 14538 default compression level is -6 (that is, biased towards high compression 14539 at expense of speed). 14540 14541 LSB Deprecated Options 14542 14543 The behaviors specified in this section are expected to disappear from a future 14544 version of the LSB; applications should only use the non-LSB-deprecated 14545 behaviors. 14546 14547 -V, --version 14548 14549 displays the version number and compilation options, then quits. 14550 14551 hostname 14552 14553 Name 14554 14555 hostname -- show or set the system's host name 14556 14557 Synopsis 14558 14559 hostname [name] 14560 14561 Description 14562 14563 hostname is used to either display or, with appropriate privileges, set the 14564 current host name of the system. The host name is used by many applications to 14565 identify the machine. 14566 14567 When called without any arguments, the program displays the name of the system 14568 as returned by the gethostname function. 14569 14570 When called with a name argument, and the user has appropriate privilege, the 14571 command sets the host name. 14572 14573 Note: It is not specified if the hostname displayed will be a fully 14574 qualified domain name. Applications requiring a particular format of 14575 hostname should check the output and take appropriate action. 14576 14577 install 14578 14579 Name 14580 14581 install -- copy files and set attributes 14582 14583 Synopsis 14584 14585 install [option...] SOURCE DEST 14586 14587 install [option...] SOURCE... DEST 14588 14589 install [-d | --directory] [option...] DIRECTORY... 14590 14591 Description 14592 14593 In the first two formats, copy SOURCE to DEST or multiple SOURCE(s) to the 14594 existing DIRECTORY, optionally setting permission modes and file ownership. In 14595 the third format, each DIRECTORY and any missing parent directories shall be 14596 created. 14597 14598 Standard Options 14599 14600 --backup[=METHOD] 14601 14602 makes a backup of each existing destination file. METHOD may be one of the 14603 following: 14604 14605 + none or off never make backups. 14606 14607 + numbered or t make numbered backups. A numbered backup has the form 14608 "%s.~%d~", target_name, version_number. Each backup shall increment the 14609 version number by 1. 14610 14611 + existing or nil numbered if numbered backups exist, or simple 14612 otherwise. 14613 14614 + simple or never append a suffix to the name. The default suffix is '~', 14615 but can be overriden by setting SIMPLE_BACKUP_SUFFIX in the 14616 environment, or via the -S or --suffix option. 14617 14618 If no METHOD is specified, the environment variable VERSION_CONTROL shall 14619 be examined for one of the above. Unambiguous abbreviations of METHOD shall 14620 be accepted. If no METHOD is specified, or if METHOD is empty, the backup 14621 method shall default to existing. 14622 14623 If METHOD is invalid or ambiguous, install shall fail and issue a 14624 diagnostic message. 14625 14626 -b 14627 14628 is equivalent to --backup=existing. 14629 14630 -d, --directory 14631 14632 treats all arguments as directory names; creates all components of the 14633 specified directories. 14634 14635 -D 14636 14637 creates all leading components of DEST except the last, then copies SOURCE 14638 to DEST; useful in the 1st format. 14639 14640 -g GROUP, --group=GROUP 14641 14642 if the user has appropriate privilege, sets group ownership, instead of 14643 process' current group. GROUP is either a name in the user group database, 14644 or a positive integer, which shall be used as a group-id. 14645 14646 -m MODE, --mode=MODE 14647 14648 sets permission mode (specified as in chmod), instead of the default 14649 rwxr-xr-x. 14650 14651 -o OWNER, --owner=OWNER 14652 14653 if the user has appropriate privilege, sets ownership. OWNER is either a 14654 name in the user login database, or a positive integer, which shall be used 14655 as a user-id. 14656 14657 -p, --preserve-timestamps 14658 14659 copies the access and modification times of SOURCE files to corresponding 14660 destination files. 14661 14662 -s, --strip 14663 14664 strips symbol tables, only for 1st and 2nd formats. 14665 14666 -S SUFFIX, --suffix=SUFFIX 14667 14668 equivalent to --backup=existing, except if a simple suffix is required, use 14669 SUFFIX. 14670 14671 --verbose 14672 14673 prints the name of each directory as it is created. 14674 14675 -v, --verbose 14676 14677 print the name of each file before copying it to stdout. 14678 14679 install_initd 14680 14681 Name 14682 14683 install_initd -- install an init.d file 14684 14685 Synopsis 14686 14687 /usr/lib/lsb/install_initd initd_file 14688 14689 Description 14690 14691 install_initd shall install a system initialization file that has been copied 14692 to the /etc/init.d location such that this file shall be run at the appropriate 14693 point during system initialization. The install_initrd command is typically 14694 called in the postinstall script of a package. See also the Section called 14695 Installation and Removal of init.d Files in Chapter 8. 14696 14697 ipcrm 14698 14699 Name 14700 14701 ipcrm -- Remove IPC Resources 14702 14703 Synopsis 14704 14705 ipcrm [-q msgid | -Q msgkey | -s semid | -S semkey | -m shmid | -M shmkey]... 14706 14707 ipcrm [shm | msg | msg] id... 14708 14709 Description 14710 14711 If any of the -q, -Q, -s, -S, -m, or -M arguments are given, the ipcrm shall 14712 behave as described in ISO POSIX (2003). 14713 14714 Otherwise, ipcrm shall remove the resource of the specified type identified by 14715 id. 14716 14717 Future Directions 14718 14719 A future revision of this specification may deprecate the second synopsis form. 14720 14721 14722 Rationale: In its first Linux implementation, ipcrm used the second syntax 14723 shown in the SYNOPSIS. Functionality present in other implementations of 14724 ipcrm has since been added, namely the ability to delete resources by key 14725 (not just identifier), and to respect the same command line syntax. The 14726 previous syntax is still supported for backwards compatibility only. 14727 14728 ipcs 14729 14730 Name 14731 14732 ipcs -- provide information on ipc facilities 14733 14734 Synopsis 14735 14736 ipcs [-smq] [-tcp] 14737 14738 Description 14739 14740 ipcs provides information on the ipc facilities for which the calling process 14741 has read access. 14742 14743 Resource display options 14744 14745 -m 14746 14747 shared memory segments. 14748 14749 -q 14750 14751 message queues. 14752 14753 -s 14754 14755 semaphore arrays. 14756 14757 Output format options 14758 14759 -t 14760 14761 time. 14762 14763 -p 14764 14765 pid. 14766 14767 -c 14768 14769 creator. 14770 14771 Application Usage 14772 14773 In some implementations of ipcs the -a option will print all information 14774 available. In other implementations the -a option will print all resource 14775 types. Therefore, applications shall not use the -a option. 14776 14777 Some implements of ipcs implement more output formats than are specified here. 14778 These options are not consistent between differing implementations of ipcs. 14779 Therefore, only the -t -c and -p option flags may be used. At least one of the 14780 -t -c and -p options shall be specified. 14781 14782 killall 14783 14784 Name 14785 14786 killall -- kill processes by name 14787 14788 Synopsis 14789 14790 killall [-egiqvw] [-signal] name... 14791 14792 killall -l 14793 14794 killall -V 14795 14796 Description 14797 14798 killall sends a signal to all processes running any of the specified commands. 14799 If no signal name is specified, SIGTERM is sent. 14800 14801 Signals can be specified either by name (e.g. -HUP) or by number (e.g. -1). 14802 Signal 0 (check if a process exists) can only be specified by number. 14803 14804 If the command name contains a slash (/), processes executing that particular 14805 file will be selected for killing, independent of their name. 14806 14807 killall returns a non-zero return code if no process has been killed for any of 14808 the listed commands. If at least one process has been killed for each command, 14809 killall returns zero. 14810 14811 A killall process never kills itself (but may kill other killall processes). 14812 14813 Standard Options 14814 14815 -e 14816 14817 requires an exact match for very long names. If a command name is longer 14818 than 15 characters, the full name may be unavailable (i.e. it is swapped 14819 out). In this case, killall will kill everything that matches within the 14820 first 15 characters. With -e, such entries are skipped. killall prints a 14821 message for each skipped entry if -v is specified in addition to -e. 14822 14823 -g 14824 14825 kills the process group to which the process belongs. The kill signal is 14826 only sent once per group, even if multiple processes belonging to the same 14827 process group were found. 14828 14829 -i 14830 14831 asks interactively for confirmation before killing. 14832 14833 -l 14834 14835 lists all known signal names. 14836 14837 -q 14838 14839 does not complain if no processes were killed. 14840 14841 -v 14842 14843 reports if the signal was successfully sent. 14844 14845 LSB Deprecated Options 14846 14847 The behaviors specified in this section are expected to disappear from a future 14848 version of the LSB; applications should only use the non-LSB-deprecated 14849 behaviors. 14850 14851 -V 14852 14853 displays version information. 14854 14855 lpr 14856 14857 Name 14858 14859 lpr -- off line print 14860 14861 Synopsis 14862 14863 lpr [-l] [-p] [-Pprinter] [-h] [-s] [-#copies] [-J name] [-T title] [name 14864 ......] 14865 14866 Description 14867 14868 lpr uses a spooling daemon to print the named files when facilities become 14869 available. If no names appear, the standard input is assumed. 14870 14871 Standard Options 14872 14873 -l 14874 14875 identifies binary data that is not to be filtered but sent as raw input to 14876 printer. 14877 14878 -p 14879 14880 formats with "pr" before sending to printer. 14881 14882 -Pprinter 14883 14884 sends output to the printer named printer instead of the default printer. 14885 14886 -h 14887 14888 suppresses header page. 14889 14890 -s 14891 14892 uses symbolic links. 14893 14894 -#copies 14895 14896 specifies copies as the number of copies to print. 14897 14898 -J name 14899 14900 specifies name as the job name for the header page. 14901 14902 -T title 14903 14904 specifies title as the title used for "pr". 14905 14906 ls 14907 14908 Name 14909 14910 ls -- list directory contents 14911 14912 Description 14913 14914 ls is as specified in ISO POSIX (2003), but with differences listed below. 14915 14916 Differences 14917 14918 -l 14919 14920 If the file is a character special or block special file, the size of the 14921 file shall be replaced with two unsigned numbers in the format "%u, %u", 14922 representing the major and minor device numbers associated with the special 14923 file. 14924 14925 14926 Note: The LSB does not specify the meaning of the major and minor 14927 devices numbers. 14928 14929 -p 14930 14931 in addition to ISO POSIX (2003) behavior of printing a slash for a 14932 directory, ls -p may display other characters for other file types. 14933 14934 Certain aspects of the pattern matching notation are optional; see 14935 Internationalization and Pattern Matching Notation. 14936 14937 lsb_release 14938 14939 Name 14940 14941 lsb_release -- print distribution specific information 14942 14943 Synopsis 14944 14945 lsb_release [OPTION...] 14946 14947 Description 14948 14949 The lsb_release command prints certain LSB (Linux Standard Base) and 14950 Distribution information. 14951 14952 If no options are given, the -v option is assumed. 14953 14954 Options 14955 14956 -v, --version 14957 14958 displays version of LSB against which distribution is compliant. The 14959 version is expressed as a colon seperated list of LSB module descriptions. 14960 LSB module descriptions are dash seperated tuples containing the module 14961 name, version, and architecture name. The output is a single line of text 14962 of the following format: 14963 14964 LSB Version:\t 14965 14966 -i, --id 14967 14968 displays string id of distributor. The output is a single line of text of 14969 the following format: 14970 14971 Distributor ID:\t 14972 14973 -d, --description 14974 14975 displays single line text description of distribution. The output is of the 14976 following format: 14977 14978 Description:\t 14979 14980 -r, --release 14981 14982 displays release number of distribution. The output is a single line of 14983 text of the following format: 14984 14985 Release:\t 14986 14987 -c, --codename 14988 14989 displays codename according to distribution release. The output is a single 14990 line of text of the following format. 14991 14992 Codename:\t 14993 14994 -a, --all 14995 14996 displays all of the above information. 14997 14998 -s, --short 14999 15000 displays all of the above information in short output format. 15001 15002 -h, --help 15003 15004 displays a human-readable help message. 15005 15006 Examples 15007 15008 The following command will list the LSB Profiles which are currently supported 15009 on this platform. 15010 15011 example% lsb_release -v 15012 LSB Version: core-2.0-ia32:core-2.0-noarch:graphics-2.0-ia32:graphics-2.0-noarch 15013 15014 m4 15015 15016 Name 15017 15018 m4 -- macro processor 15019 15020 Description 15021 15022 m4 is as specified in ISO POSIX (2003), but with extensions as listed below. 15023 15024 Extensions 15025 15026 -P 15027 15028 forces all builtins to be prefixed with m4_. For example, define becomes 15029 m4_define. 15030 15031 -I directory 15032 15033 Add directory to the end of the search path for includes. 15034 15035 md5sum 15036 15037 Name 15038 15039 md5sum -- generate or check MD5 message digests 15040 15041 Synopsis 15042 15043 md5sum [-c [file] | file] 15044 15045 Description 15046 15047 For each file, write to standard output a line containing the MD5 message 15048 digest of that file, followed by one or more blank characters, followed by the 15049 name of the file. The MD5 message digest shall be calculated according to RFC 15050 1321: The MD5 Message-Digest Algorithm and output as 32 hexadecimal digits. 15051 15052 If no file names are specified as operands, read from standard input and use 15053 "-" as the file name in the output. 15054 15055 Options 15056 15057 -c [file] 15058 15059 checks the MD5 message digest of all files named in file against the 15060 message digest listed in the same file. The actual format of file is the 15061 same as the output of md5sum. That is, each line in the file describes a 15062 file. If file is not specified, read message digests from stdin. 15063 15064 Exit Status 15065 15066 md5sum shall exit with status 0 if the sum was generated successfully, or, in 15067 check mode, if the check matched. Otherwise, md5sum shall exit with a non-zero 15068 status. 15069 15070 mknod 15071 15072 Name 15073 15074 mknod -- make special files 15075 15076 Synopsis 15077 15078 mknod [-m mode | --mode=mode] name type [major minor] 15079 15080 mknod [--version] 15081 15082 Description 15083 15084 The mknod command shall create a special file named name of the given type. 15085 15086 The type shall be one of the following: 15087 15088 b 15089 15090 creates a block (buffered) special file with the specified major and minor 15091 device numbers. 15092 15093 c, u 15094 15095 creates a character (unbuffered) special file with the specified major and 15096 minor device numbers. 15097 15098 p 15099 15100 creates a FIFO. 15101 15102 Options 15103 15104 -m mode, --mode=mode 15105 15106 create the special file with file access permissions set as described in 15107 mode. The permissions may be any absolute value (i.e. one not containing 15108 '+' or '-') acceptable to the chmod command. 15109 15110 --version 15111 15112 output version information and exit. 15113 15114 15115 Note: This option may be deprecated in a future release of this 15116 specification. 15117 15118 If type is pparameter, major and minor shall not be specified. Otherwise, these 15119 parameters are mandatory. 15120 15121 Future Directions 15122 15123 This command may be deprecated in a future version of this specification. The 15124 major and minor operands are insufficently portable to be specified usefully 15125 here. Only a FIFO can be portably created by this command, and the mkfifo 15126 command is a simpler interface for that purpose. 15127 15128 mktemp 15129 15130 Name 15131 15132 mktemp -- make temporary file name (unique) 15133 15134 Synopsis 15135 15136 mktemp [-q] [-u] template 15137 15138 Description 15139 15140 The mktemp command takes the given file name template and overwrites a portion 15141 of it to create a file name. This file name shall be unique and suitable for 15142 use by the application. 15143 15144 The template should have at least six trailing 'X' characters. These characters 15145 are replaced with characters from the portable filename character set in order 15146 to generate a unique name. 15147 15148 If mktemp can successfully generate a unique file name, and the -u option is 15149 not present, the file shall be created with read and write permission only for 15150 the current user. The mktemp command shall write the filename generated to the 15151 standard output. 15152 15153 Options 15154 15155 -q 15156 15157 fail silently if an error occurs. Diagnostic messages to stderr are 15158 suppressed, but the command shall still exit with a non-zero exit status if 15159 an error occurs. 15160 15161 -u 15162 15163 operates in `unsafe' mode. A unique name is generated, but the temporary 15164 file shall be unlinked before mktemp exits. Use of this option is not 15165 encouraged. 15166 15167 more 15168 15169 Name 15170 15171 more -- display files on a page-by-page basis 15172 15173 Description 15174 15175 more is as specified in ISO POSIX (2003), but with differences as listed below. 15176 15177 Differences 15178 15179 The more command need not respect the LINES and COLUMNS environment variables. 15180 15181 The following additional options may be supported: 15182 15183 -num 15184 15185 specifies an integer which is the screen size (in lines). 15186 15187 +num 15188 15189 starts at line number num. 15190 15191 +/pattern 15192 15193 Start at the first line matching the pattern, equivalent to executing the 15194 search forward (/) command with the given pattern immediately after opening 15195 each file. 15196 15197 The following options from ISO POSIX (2003) may behave differently: 15198 15199 -e 15200 15201 has unspecified behavior. 15202 15203 -i 15204 15205 has unspecified behavior. 15206 15207 -n 15208 15209 has unspecified behavior. 15210 15211 -p 15212 15213 Either clear the whole screen before displaying any text (instead of the 15214 usual scrolling behavior), or provide the behavior specified by ISO POSIX 15215 (2003). In the latter case, the syntax is "-p command". 15216 15217 -t 15218 15219 has unspecified behavior. 15220 15221 The more command need not support the following interactive commands: 15222 15223 g 15224 G 15225 u 15226 control u 15227 control f 15228 newline 15229 j 15230 k 15231 r 15232 R 15233 m 15234 ' (return to mark) 15235 /! 15236 ? 15237 N 15238 :e 15239 :t 15240 control g 15241 ZZ 15242 15243 Rationale 15244 15245 The +num and +/string options are deprecated in SUSv2, and have been removed in 15246 ISO POSIX (2003); however this specification continues to specify them because 15247 the publicly available util-linux package does not support the replacement (-p 15248 command). The +command option as found in SUSv2 is more general than is 15249 specified here, but the util-linux package appears to only support the more 15250 specific +num and +/string forms. 15251 15252 mount 15253 15254 Name 15255 15256 mount -- mount a file system 15257 15258 Synopsis 15259 15260 mount [-hV] 15261 15262 mount [-a] [-fFnrsvw] [-t vfstype] 15263 15264 mount [-fnrsvw] [-o options [,...]] [device | dir] 15265 15266 mount [-fnrsvw] [-t vfstype] [-o options] device dir 15267 15268 Description 15269 15270 As described in ISO POSIX (2003), all files in the system are organized in a 15271 directed graph, known as the file hierarchy, rooted at /. These files can be 15272 spread out over several underlying devices. The mount command shall attach the 15273 file system found on some underlying device to the file hierarchy. 15274 15275 Options 15276 15277 -v 15278 15279 invoke verbose mode. The mount command shall provide diagnostic messages on 15280 stdout. 15281 15282 -a 15283 15284 mount all filesystems (of the given types) mentioned in /etc/fstab. 15285 15286 -F 15287 15288 If the -a option is also present, fork a new incarnation of mount for each 15289 device to be mounted. This will do the mounts on different devices or 15290 different NFS servers in parallel. 15291 15292 -f 15293 15294 cause everything to be done except for the actual system call; if it's not 15295 obvious, this `fakes' mounting the file system. 15296 15297 -n 15298 15299 mount without writing in /etc/mtab. This is necessary for example when /etc 15300 is on a read-only file system. 15301 15302 -s 15303 15304 ignore mount options not supported by a filesystem type. Not all 15305 filesystems support this option. 15306 15307 -r 15308 15309 mount the file system read-only. A synonym is -o ro. 15310 15311 -w 15312 15313 mount the file system read/write. (default) A synonym is -o rw. 15314 15315 -L label 15316 15317 If the file /proc/partitions is supported, mount the partition that has the 15318 specified label. 15319 15320 -U uuid 15321 15322 If the file /proc/partitions is supported, mount the partition that has the 15323 specified uuid. 15324 15325 -t vfstype 15326 15327 indicate a file system type of vfstype. 15328 15329 More than one type may be specified in a comma separated list. The list of 15330 file system types can be prefixed with no to specify the file system types 15331 on which no action should be taken. 15332 15333 -o 15334 15335 options are specified with a -o flag followed by a comma-separated string 15336 of options. Some of these options are only useful when they appear in the / 15337 etc/fstab file. The following options apply to any file system that is 15338 being mounted: 15339 15340 async 15341 15342 perform all I/O to the file system asynchronously. 15343 15344 atime 15345 15346 update inode access time for each access. (default) 15347 15348 auto 15349 15350 in /etc/fstab, indicate the device is mountable with -a. 15351 15352 defaults 15353 15354 use default options: rw, suid, dev, exec, auto, nouser, async. 15355 15356 dev 15357 15358 interpret character or block special devices on the file system. 15359 15360 exec 15361 15362 permit execution of binaries. 15363 15364 noatime 15365 15366 do not update file access times on this file system. 15367 15368 noauto 15369 15370 in /etc/fstab, indicates the device is only explicitly mountable. 15371 15372 nodev 15373 15374 do not interpret character or block special devices on the file system. 15375 15376 noexec 15377 15378 do not allow execution of any binaries on the mounted file system. 15379 15380 nosuid 15381 15382 do not allow set-user-identifier or set-group-identifier bits to take 15383 effect. 15384 15385 nouser 15386 15387 forbid an unprivileged user to mount the file system. (default) 15388 15389 remount 15390 15391 remount an already-mounted file system. This is commonly used to change 15392 the mount options for a file system, especially to make a read-only 15393 file system writable. 15394 15395 ro 15396 15397 mount the file system read-only. 15398 15399 rw 15400 15401 mount the file system read-write. 15402 15403 suid 15404 15405 allow set-user-identifier or set-group-identifier bits to take effect. 15406 15407 sync 15408 15409 do all I/O to the file system synchronously. 15410 15411 user 15412 15413 allow an unprivilieged user to mount the file system. This option 15414 implies the options noexec, nosuid, nodev unless overridden by 15415 subsequent options. 15416 15417 LSB Deprecated Options 15418 15419 The behaviors specified in this section are expected to disappear from a future 15420 version of the LSB; applications should only use the non-LSB-deprecated 15421 behaviors. 15422 15423 -V 15424 15425 output version and exit. 15426 15427 msgfmt 15428 15429 Name 15430 15431 msgfmt -- create a message object from a message file 15432 15433 Synopsis 15434 15435 msgfmt [options...] filename... 15436 15437 Description 15438 15439 The msgfmt command generates a binary message catalog from a textual 15440 translation description. Message catalogs, or message object files, are stored 15441 in files with a .mo extension. 15442 15443 15444 Note: The format of message object files is not guaranteed to be portable. 15445 Message catalogs should always be generated on the target architecture 15446 using the msgfmt command. 15447 15448 The source message files, otherwise known as portable object files, have a .po 15449 extension. 15450 15451 The filename operands shall be portable object files. The .po file contains 15452 messages to be displayed to users by system utilities or by application 15453 programs. The portable object files are text files, and the messages in them 15454 can be rewritten in any language supported by the system. 15455 15456 If any filename is -, a portable object file shall be read from the standard 15457 input. 15458 15459 The msgfmt command interprets data as characters according to the current 15460 setting of the LC_CTYPE locale category. 15461 15462 Options 15463 15464 -c, --check 15465 15466 Detect and diagnose input file anomalies which might represent translation 15467 errors. The msgid and msgstr strings are studied and compared. It is 15468 considered abnormal that one string starts or ends with a newline while the 15469 other does not. 15470 15471 If the message is flagged as c-format (see Comment Handling), check that 15472 the msgid string and the msgstr translation have the same number of % 15473 format specifiers, with matching types. 15474 15475 -D directory, --directory=directory 15476 15477 Add directory to list for input files search. If filename is not an 15478 absolute pathname and filename cannot be opened, search for it in 15479 directory. This option may be repeated. Directories shall be searched in 15480 order, with the leftmost directory searched first. 15481 15482 -f, --use-fuzzy 15483 15484 Use entries marked as fuzzy in output. If this option is not specified, 15485 such entries are not included into the output. See Comment Handling below. 15486 15487 -o output-file, --output-file=output-file 15488 15489 Specify the output file name as output-file. If multiple domains or 15490 duplicate msgids in the .po file are present, the behavior is unspecified. 15491 If output-file is -, output is written to standard output. 15492 15493 -S, --strict 15494 15495 Ensure that all output files have a .mo extension. Output files are named 15496 either by the -o (or --output-file) option, or by domains found in the 15497 input files. 15498 15499 -v, --verbose 15500 15501 Print additional information to the standard error, including the number of 15502 translated strings processed. 15503 15504 Operands 15505 15506 The filename operands are treated as portable object files. The format of 15507 portable object files is defined in EXTENDED DESCRIPTION. 15508 15509 Standard Input 15510 15511 The standard input is not used unless a filename operand is specified as "-". 15512 15513 Environment Variables 15514 15515 LANGUAGE 15516 15517 Specifies one or more locale names. 15518 15519 LANG 15520 15521 Specifies locale name. 15522 15523 LC_ALL 15524 15525 Specifies locale name for all categories. If defined, overrides LANG, 15526 LC_CTYPE and LC_MESSAGES. 15527 15528 LC_CTYPE 15529 15530 Determine the locale for the interpretation of sequences of bytes of text 15531 data as characters (for example, single-byte as opposed to multi-byte 15532 characters in arguments and input files). 15533 15534 LC_MESSAGES 15535 15536 Specifies messaging locale, and if present overrides LANG for messages. 15537 15538 Standard Output 15539 15540 The standard output is not used unless the option-argument of the -o option is 15541 specified as -. 15542 15543 Extended Description 15544 15545 The format of portable object files (.po files) is defined as follows. Each .po 15546 file contains one or more lines, with each line containing either a comment or 15547 a statement. Comments start the line with a hash mark (#) and end with the 15548 newline character. Empty lines, or lines containing only white-space, shall be 15549 ignored. Comments can in certain circumstances alter the behavior of msgfmt. 15550 See Comment Handling below for details on comment processing. The format of a 15551 statement is: 15552 15553 directive value 15554 15555 Each directive starts at the beginning of the line and is separated from value 15556 by white space (such as one or more space or tab characters). The value 15557 consists of one or more quoted strings separated by white space. If two or more 15558 strings are specified as value, they are normalized into single string using 15559 the string normalization syntax specified in ISO C (1999). The following 15560 directives are supported: 15561 15562 domain domainname 15563 15564 msgid message_identifier 15565 15566 msgid_plural untranslated_string_plural 15567 15568 msgstr message_string 15569 15570 msgstr[n] message_string 15571 15572 The behavior of the domain directive is affected by the options used. See 15573 OPTIONS for the behavior when the -o option is specified. If the -o option is 15574 not specified, the behavior of the domain directive is as follows: 15575 15576 1. All msgids from the beginning of each .po file to the first domain 15577 directive are put into a default message object file, messages (or 15578 messages.mo if the --strict option is specified). 15579 15580 2. When msgfmt encounters a domain domainname directive in the .po file, all 15581 following msgids until the next domain directive are put into the message 15582 object file domainname (or domainname.mo if --strict option is specified). 15583 15584 3. Duplicate msgids are defined in the scope of each domain. That is, a msgid 15585 is considered a duplicate only if the identical msgid exists in the same 15586 domain. 15587 15588 4. All duplicate msgids are ignored. 15589 15590 15591 15592 The msgid directive specifies the value of a message identifier associated with 15593 the directive that follows it. The msgid_plural directive specifies the plural 15594 form message specified to the plural message handling functions ngettext, 15595 dngettext or dcngettext. The message_identifier string identifies a target 15596 string to be used at retrieval time. Each statement containing a msgid 15597 directive shall be followed by a statement containing a msgstr directive or 15598 msgstr[n] directives. 15599 15600 The msgstr directive specifies the target string associated with the 15601 message_identifier string declared in the immediately preceding msgid 15602 directive. 15603 15604 The msgstr[n] (where n = 0, 1, 2, ...) directive specifies the target string to 15605 be used with plural form handling functions ngettext, dngettext and dcngettext. 15606 15607 Message strings can contain the following escape sequences: 15608 15609 Table 3-1. Escape Sequences 15610 15611 +-----------------------------+ 15612 |\n |newline | 15613 |----+------------------------| 15614 |\t |tab | 15615 |----+------------------------| 15616 |\v |vertical tab | 15617 |----+------------------------| 15618 |\b |backspace | 15619 |----+------------------------| 15620 |\r |carriage return | 15621 |----+------------------------| 15622 |\f |formfeed | 15623 |----+------------------------| 15624 |\\ |backslash | 15625 |----+------------------------| 15626 |\" |double quote | 15627 |----+------------------------| 15628 |\ddd|octal bit pattern | 15629 |----+------------------------| 15630 |\xHH|hexadecimal bit pattern | 15631 +-----------------------------+ 15632 15633 Comment Handling 15634 15635 Comments are introduced by a #, and continue to the end of the line. The second 15636 character (i.e. the character following the #) has special meaning. Regular 15637 comments should follow a space character. Other comment types include: 15638 15639 # normal-comments 15640 15641 #. automatic-comments 15642 15643 #: reference... 15644 15645 #, flag 15646 15647 Automatic and reference comments are typically generated by external utilities, 15648 and are not specified by the LSB. The msgfmt command shall ignore such 15649 comments. 15650 15651 15652 Note: Portable object files may be produced by unspecified tools. Some of 15653 the comment types described here may arise from the use of such tools. It 15654 is beyond the scope of this specification to describe these tools. 15655 15656 The #, comments require one or more flags separated by the comma (,) character. 15657 The following flags can be specified: 15658 15659 fuzzy 15660 15661 This flag shows that the following msgstr string might not be a correct 15662 translation. Only the translator (i.e. the individual undertaking the 15663 translation) can judge if the translation requires further modification, or 15664 is acceptable as is. Once satisfied with the translation, the translator 15665 then removes this fuzzy flag. 15666 15667 If this flag is specified, the msgfmt utility will not generate the entry 15668 for the immediately following msgid in the output message catalog, unless 15669 the --use-fuzzy is specified. 15670 15671 c-format, no-c-format 15672 15673 The c-format flag indicates that the msgid string is used as format string 15674 by printf-like functions. If the c-format flag is given for a string the 15675 msgfmt utility may perform additional tests to check to validity of the 15676 translation. 15677 15678 Plurals 15679 15680 The msgid entry with empty string ("") is called the header entry and is 15681 treated specially. If the message string for the header entry contains nplurals 15682 =value, the value indicates the number of plural forms. For example, if 15683 nplurals=4, there are 4 plural forms. If nplurals is defined, there should be a 15684 plural=expression on the same line, separated by a semicolon (;) character. The 15685 expression is a C language expression to determine which version of msgstr[n] 15686 to be used based on the value of n, the last argument of ngettext, dngettext or 15687 dcngettext. For example: 15688 15689 nplurals=2; plural=n == 1 ? 0 : 1 15690 15691 indicates that there are 2 plural forms in the language; msgstr[0] is used if n 15692 == 1, otherwise msgstr[1] is used. Another example: 15693 15694 nplurals=3; plural=n==1 ? 0 : n==2 ? 1 : 2 15695 15696 indicates that there are 3 plural forms in the language; msgstr[0] is used if n 15697 == 1, msgstr[1] is used if n == 2, otherwise msgstr[2] is used. 15698 15699 If the header entry contains charset=codeset string, the codeset is used to 15700 indicate the codeset to be used to encode the message strings. If the output 15701 string's codeset is different from the message string's codeset, codeset 15702 conversion from the message strings's codeset to the output string's codeset 15703 will be performed upon the call of gettext, dgettext, dcgettext, ngettext, 15704 dngettext, and dcngettext. The output string's codeset is determined by the 15705 current locale's codeset (the return value of nl_langinfo(CODESET)) by default, 15706 and can be changed by the call of bind_textdomain_codeset. 15707 15708 Exit Status 15709 15710 The following exit values are returned: 15711 15712 0 15713 15714 Successful completion. 15715 15716 >0 15717 15718 An error occurred. 15719 15720 Application Usage 15721 15722 Neither msgfmt nor any gettext function imposes a limit on the total length of 15723 a message. Installing message catalogs under the C locale is pointless, since 15724 they are ignored for the sake of efficiency. 15725 15726 Examples 15727 15728 Example 1: Examples of creating message objects from message files. 15729 15730 In this example module1.po, module2.po and module3.po are portable message 15731 object files. 15732 15733 example% cat module1.po 15734 15735 # default domain "messages" 15736 15737 msgid "message one" 15738 15739 msgstr "mensaje n?mero uno" 15740 15741 # 15742 15743 domain "help_domain" 15744 15745 msgid "help two" 15746 15747 msgstr "ayuda n?mero dos" 15748 15749 # 15750 15751 domain "error_domain" 15752 15753 msgid "error three" 15754 15755 msgstr "error n?mero tres" 15756 15757 example% cat module2.po 15758 15759 # default domain "messages" 15760 15761 msgid "message four" 15762 15763 msgstr "mensaje n?mero cuatro" 15764 15765 # 15766 15767 domain "error_domain" 15768 15769 msgid "error five" 15770 15771 msgstr "error n?mero cinco" 15772 15773 # 15774 15775 domain "window_domain" 15776 15777 msgid "window six" 15778 15779 msgstr "ventana n?mero seises" 15780 15781 example% cat module3.po 15782 15783 # default domain "messages" 15784 15785 msgid "message seven" 15786 15787 msgstr "mensaje n?mero siete" 15788 15789 The following command will produce the output files messages, help_domain, and 15790 error_domain. 15791 15792 example% msgfmt module1.po 15793 15794 The following command will produce the output files messages, help_domain, 15795 error_domain, and window_domain. 15796 15797 example% msgfmt module1.po module2.po 15798 15799 The following example will produce the output file hello.mo. 15800 15801 example% msgfmt -o hello.mo module3.po 15802 15803 newgrp 15804 15805 Name 15806 15807 newgrp -- change group ID 15808 15809 Synopsis 15810 15811 newgrp [group] 15812 15813 Description 15814 15815 The newgrp command is as specified in ISO POSIX (2003), but with differences as 15816 listed below. 15817 15818 Differences 15819 15820 The -l option specified in ISO POSIX (2003) need not be supported. 15821 15822 od 15823 15824 Name 15825 15826 od -- dump files in octal and other formats 15827 15828 Synopsis 15829 15830 od [-abcdfilox] [-w width | --width-width] [-v] [-A address_base] [-j skip] [-n 15831 count] [-t type_string] [file...] 15832 15833 od --traditional [options] [file] [[+]offset [.] [b]] [[+]label [.] [b]] 15834 15835 Description 15836 15837 od is as specified in ISO POSIX (2003), but with differences as listed below. 15838 15839 Differences 15840 15841 -wwidth, --width[=width] 15842 15843 each output line is limited to width bytes from the input. 15844 15845 --traditional 15846 15847 accepts arguments in traditional form. 15848 15849 15850 Note: The XSI optional behavior described in ISO POSIX (2003) is not 15851 supported unless the --traditional option is also specified. 15852 15853 Pre-POSIX and XSI Specifications 15854 15855 The LSB supports option intermixtures with the following pre-POSIX and XSI 15856 options: 15857 15858 -a 15859 15860 is equivalent to -t a, selects named characters. 15861 15862 -b 15863 15864 is equivalent to -t o1, selects octal bytes. 15865 15866 -c 15867 15868 is equivalent to -t c, selects characters. 15869 15870 -d 15871 15872 is equivalent to -t u2, selects unsigned decimal two byte units. 15873 15874 -f 15875 15876 is equivalent to -t fF, selects floats. 15877 15878 -i 15879 15880 is equivalent to -t d2, selects decimal two byte units. 15881 15882 15883 Note: This usage may change in future releases; portable applications 15884 should use -t d2. 15885 15886 -l 15887 15888 is equivalent to -t d4, selects decimal longs. 15889 15890 -o 15891 15892 is equivalent to -t o2, selects octal two byte units. 15893 15894 -x 15895 15896 is equivalent to -t x2, selects hexadecimal two byte units. 15897 15898 Note that the XSI option -s need not be supported. 15899 15900 Traditional Usage 15901 15902 If the --traditional is specified, there may be between zero and three operands 15903 specified. 15904 15905 If no operands are specified, then od shall read the standard input. 15906 15907 If there is exactly one operand, and it is an offset of the form [+]offset[.] 15908 [b], then it shall be interpreted as specified in ISO POSIX (2003). The file to 15909 be dumped shall be the standard input. 15910 15911 If there are exactly two operands, and they are both of the form [+]offset[.] 15912 [b], then the first shall be an treated as an offset (as above), and the second 15913 shall be a label, in the same format as the offset. If a label is specified, 15914 then the first output line produced for each input block shall be preceded by 15915 the input offset, cumulative across input files, of the next byte to be 15916 written, followed by the label, in parentheses. The label shall increment in 15917 the same manner as the offset. 15918 15919 If there are three operands, then the first shall be the file to dump, the 15920 second the offset, and the third the label. 15921 15922 passwd 15923 15924 Name 15925 15926 passwd -- change user password 15927 15928 Synopsis 15929 15930 passwd [-x max] [-n min] [-w warn] [-i inact] name 15931 15932 passwd {-l | -u} name 15933 15934 Description 15935 15936 passwd changes passwords for user and group accounts. A normal user may only 15937 change the password for their own account, the super user may change the 15938 password for any account. passwd also changes password expiry dates and 15939 intervals. Applications may not assume the format of prompts and anticipated 15940 input for user interaction, because they are unspecified. 15941 15942 Options 15943 15944 -x max 15945 15946 sets the maximum number of days a password remains valid. 15947 15948 -n min 15949 15950 sets the minimum number of days before a password may be changed. 15951 15952 -w warn 15953 15954 sets the number of days warning the user will receive before their password 15955 will expire. 15956 15957 -i inactive 15958 15959 disables an account after the password has been expired for the given 15960 number of days. 15961 15962 -l 15963 15964 disables an account by changing the password to a value which matches no 15965 possible encrypted value. 15966 15967 -u 15968 15969 re-enables an account by changing the password back to its previous value. 15970 15971 patch 15972 15973 Name 15974 15975 patch -- apply a diff file to an original 15976 15977 Description 15978 15979 patch is as specified in ISO POSIX (2003), but with extensions as listed below. 15980 15981 Extensions 15982 15983 --binary 15984 15985 reads and write all files in binary mode, except for standard output and / 15986 dev/tty. This option has no effect on POSIX-compliant systems. 15987 15988 -u, --unified 15989 15990 interprets the patch file as a unified context diff. 15991 15992 pidof 15993 15994 Name 15995 15996 pidof -- find the process ID of a running program 15997 15998 Synopsis 15999 16000 pidof [-s] [-x] [-o omitpid...] program... 16001 16002 Description 16003 16004 Return the process ID of a process which is running the program named on the 16005 command line. 16006 16007 Options 16008 16009 -s 16010 16011 instructs the program to only return one pid. 16012 16013 -x 16014 16015 causes the program to also return process id's of shells running the named 16016 scripts. 16017 16018 -o 16019 16020 omits processes with specified process id. 16021 16022 remove_initd 16023 16024 Name 16025 16026 remove_initd -- clean up boot script system modifications introduced by 16027 install_initd 16028 16029 Synopsis 16030 16031 /usr/lib/lsb/remove_initd initd_file 16032 16033 Description 16034 16035 remove_initd processes the removal of the modifications made to a 16036 distribution's boot script system by the install_initd program. This cleanup is 16037 performed in the preuninstall script of a package; however, the package manager 16038 is still responsible for removing the /etc/init.d file. See also the Section 16039 called Installation and Removal of init.d Files in Chapter 8. 16040 16041 renice 16042 16043 Name 16044 16045 renice -- alter priority of running processes 16046 16047 Description 16048 16049 renice is as specified in ISO POSIX (2003), but with differences as listed 16050 below. 16051 16052 Differences 16053 16054 -n increment 16055 16056 has unspecified behavior. 16057 16058 sed 16059 16060 Name 16061 16062 sed -- stream editor 16063 16064 Description 16065 16066 sed is as specified in ISO POSIX (2003), but with differences as listed below. 16067 16068 LSB Differences 16069 16070 Certain aspects of internationalized regular expressions are optional; see 16071 Internationalization and Regular Expressions>. 16072 16073 sendmail 16074 16075 Name 16076 16077 sendmail -- an electronic mail transport agent 16078 16079 Synopsis 16080 16081 sendmail [options] [address...] 16082 16083 Description 16084 16085 To deliver electronic mail (email), applications shall support the interface 16086 provided by /usr/sbin/sendmail (described here). This interface shall be the 16087 default delivery method for applications. 16088 16089 This program sends an email message to one or more recipients, routing the 16090 message as necessary. This program is not intended as a user interface routine. 16091 16092 With no options, sendmail reads its standard input up to an end-of-file or a 16093 line consisting only of a single dot and sends a copy of the message found 16094 there to all of the addresses listed. It determines the network(s) to use based 16095 on the syntax and contents of the addresses. 16096 16097 It is recommended that applications use as few options as necessary, none if 16098 possible. 16099 16100 Some agents allow aliasing on the local system to be prevented by preceding the 16101 address with a backslash. 16102 16103 The format of messages shall be as defined in RFC 2822. 16104 16105 Options 16106 16107 -bm 16108 16109 reads mail from standard input and delivers to the recipient addresses. 16110 This is the default mode of operation. 16111 16112 -bp 16113 16114 lists information about messages currently in the input mail queue. 16115 16116 -bs 16117 16118 uses the SMTP protocol as described in RFC 2821; reads SMTP commands on 16119 standard input and writes SMTP responses on standard output. 16120 16121 Note that RFC 2821 specifies \r\n (CR-LF) be used at the end of each line, 16122 but pipes almost always use \n (LF) instead. To deal with this, agents will 16123 accept both \r\n and \n at the end of each line. When accepting \r\n, the \ 16124 r before the \n is silently discarded. 16125 16126 -F fullname 16127 16128 explicitly sets the full name of the sender for incoming mail unless the 16129 message already contains a From: message header. 16130 16131 If the user running sendmail is not sufficiently trusted, then the actual 16132 sender may be indicated in the message, depending on the behavior of the 16133 agent. 16134 16135 -f name 16136 16137 explicitly sets the envelope sender address for incoming mail. If there is 16138 no From: header, the address specified in the From: header will also be 16139 set. 16140 16141 If the user running sendmail is not sufficiently trusted, then the actual 16142 sender will be indicated in the message. 16143 16144 -i 16145 16146 ignores dots alone on lines by themselves in incoming messages. If -bs is 16147 also used, the behavior is unspecified. 16148 16149 -odb 16150 16151 delivers any mail in background, if supported; otherwise ignored. 16152 16153 -odf 16154 16155 delivers any mail in foreground, if supported; otherwise ignored. 16156 16157 -oem or -em 16158 16159 mails errors back to the sender. (default) 16160 16161 -oep or -ep 16162 16163 writes errors to the standard error output. 16164 16165 -oeq or -eq 16166 16167 does not send notification of errors to the sender. This only works for 16168 mail delivered locally. 16169 16170 -oi 16171 16172 is equivalent to -i. 16173 16174 -om 16175 16176 indicates that the sender of a message should receive a copy of the message 16177 if the sender appears in an alias expansion. Ignored if aliases are not 16178 supported. 16179 16180 -t 16181 16182 reads the message to obtain recipients from the To:, Cc:, and Bcc: headers 16183 in the message instead of from the command arguments. If a Bcc: header is 16184 present, it is removed from the message unless there is no To: or Cc: 16185 header, in which case a Bcc: header with no data is created, in accordance 16186 with RFC 2822. 16187 16188 If there are any arguments, they specify addresses to which the message is 16189 not to be delivered. That is, the argument addresses are removed from the 16190 recipients list obtained from the headers. Note: some agents implement this 16191 behavior in reverse, adding addresses instead of removing them. Others may 16192 disallow addresses in argument list. Therefore, applications should not put 16193 addresses in the argument list if -t is used. 16194 16195 This option is sometimes ignored when not in -bm mode (the default). 16196 16197 Exit status 16198 16199 0 16200 16201 successful completion on all addresses. This does not indicate successful 16202 delivery. 16203 16204 >0 16205 16206 there was an error. 16207 16208 Notes/Rationale 16209 16210 This page is believed to reflect functionality provided by smail, exim and 16211 other implementations, not just the sendmail implementation. 16212 16213 shutdown 16214 16215 Name 16216 16217 shutdown -- bring the system down 16218 16219 Synopsis 16220 16221 /sbin/shutdown [-t sec] [-arkhcfF] time [warning-message] 16222 16223 Description 16224 16225 shutdown brings the system down in a secure way. All logged-in users are 16226 notified that the system is going down, and login(1) is blocked. It is possible 16227 to shut the system down immediately or after a specified delay. All processes 16228 are first notified that the system is going down by the signal SIGTERM. If 16229 neither the -h or the -r argument is used, then the default behavior is to take 16230 the system to runlevel one where administrative tasks can be run. 16231 16232 Standard Options 16233 16234 -a 16235 16236 uses /etc/shutdown.allow. 16237 16238 -t sec 16239 16240 tells init(8) to wait sec seconds between sending processes the warning and 16241 the kill signal, before changing to another runlevel. 16242 16243 -k 16244 16245 doesn't really shutdown; only sends the warning messages to everybody. 16246 16247 -r 16248 16249 reboots after shutdown. 16250 16251 -h 16252 16253 halts after shutdown. Powering off after halting is unspecified. 16254 16255 -f 16256 16257 skips fsck on reboot. 16258 16259 -F 16260 16261 forces fsck on reboot. 16262 16263 -c 16264 16265 cancels an already running shutdown. With this option, it is of course not 16266 possible to give the time argument, but you can enter a explanatory message 16267 on the command line that will be sent to all users. 16268 16269 time 16270 16271 specifies when to shut down. 16272 16273 The time argument can have different formats. First, it can be an absolute 16274 time in the format hh:mm, in which hh is the hour (1 or 2 digits) and mm is 16275 the minute of the hour (in two digits). Second, it can be in the format +m, 16276 in which m is the number of minutes to wait. The word now is an alias for 16277 +0. 16278 16279 If shutdown is called with a delay, it creates the advisory file /etc/ 16280 nologin which causes programs such as login(1) to not allow new user 16281 logins. shutdown only removes this file if it is stopped before it can 16282 signal init (i.e. it is cancelled or something goes wrong). Otherwise it is 16283 the responsibility of the system shutdown or startup scripts to remove this 16284 file so that users can login. 16285 16286 warning-message 16287 16288 specifies message to send all users. 16289 16290 su 16291 16292 Name 16293 16294 su -- change user ID or become super-user 16295 16296 Synopsis 16297 16298 su [options] [-] [username [ARGS]] 16299 16300 Description 16301 16302 su is used to become another user during a login session. Invoked without a 16303 username, su defaults to becoming the super user. The optional argument - may 16304 be used to provide an environment similar to what the user would expect had the 16305 user logged in directly. 16306 16307 The user will be prompted for a password, if appropriate. Invalid passwords 16308 will produce an error message. All attempts, both valid and invalid, are logged 16309 to detect abuses of the system. Applications may not assume the format of 16310 prompts and anticipated input for user interaction, because they are 16311 unspecified. 16312 16313 An optional command can be executed. This is done by the shell specified in / 16314 etc/passwd for the target user unless the -s or -m options are used. Any 16315 arguments supplied after the username will be passed to the invoked shell 16316 (shell shall support the -c command line option in order for a command to be 16317 passed to it). 16318 16319 The current environment is passed to the new shell. The value of $PATH is reset 16320 to /bin:/usr/bin for normal users, or /sbin:/bin:/usr/sbin:/usr/bin for the 16321 super user. This may be changed with the ENV_PATH and ENV_SUPATH definitions in 16322 /etc/login.defs. When using the -m or -p options, the user's environment is not 16323 changed. 16324 16325 A subsystem login is indicated by the presense of a "*" as the first character 16326 of the login shell. The given home directory will be used as the root of a new 16327 filesystem which the user is actually logged into. 16328 16329 Standard Options 16330 16331 - 16332 16333 makes this a login shell. 16334 16335 -c, --comand=command 16336 16337 passes command to the invoked shell. It is passed directly to the invoked 16338 shell (using the shell's -c option), so its syntax is whatever that shell 16339 can accept. 16340 16341 -m, -p, --preserve-environment 16342 16343 does not reset environment variables, and keeps the same shell if it is 16344 present in /etc/shells. 16345 16346 -s, --shell=shell 16347 16348 uses shell instead of the default in /etc/passwd. The shell specified shall 16349 be present in /etc/shells. 16350 16351 sync 16352 16353 Name 16354 16355 sync -- flush filesystem buffers 16356 16357 Synopsis 16358 16359 sync 16360 16361 Description 16362 16363 Force changed blocks to disk, update the super block. 16364 16365 tar 16366 16367 Name 16368 16369 tar -- file archiver 16370 16371 Description 16372 16373 tar is as specified in SUSv2, but with differences as listed below. 16374 16375 Differences 16376 16377 Certain aspects of internationalized filename globbing are optional; see 16378 Internationalization and Pattern Matching Notation>. 16379 16380 -h 16381 16382 doesn't dump symlinks; dumps the files they point to. 16383 16384 -z 16385 16386 filters the archive through gzip. 16387 16388 umount 16389 16390 Name 16391 16392 umount -- unmount file systems 16393 16394 Synopsis 16395 16396 umount [-hV] 16397 16398 umount -a [-nrv] [-t vfstype] 16399 16400 umount [-nrv] device | dir 16401 16402 Description 16403 16404 umount detaches the file system(s) mentioned from the file hierarchy. A file 16405 system is specified by giving the directory where it has been mounted. 16406 16407 Standard Options 16408 16409 -v 16410 16411 invokes verbose mode. 16412 16413 -n 16414 16415 unmounts without writing in /etc/mtab. 16416 16417 -r 16418 16419 tries to remount read-only if unmounting fails. 16420 16421 -a 16422 16423 unmounts all of the file systems described in /etc/mtab except for the proc 16424 filesystem. 16425 16426 -t vfstype 16427 16428 indicates that the actions should only be taken on file systems of the 16429 specified type. More than one type may be specified in a comma separated 16430 list. The list of file system types can be prefixed with no to specify the 16431 file system types on which no action should be taken. 16432 16433 -f 16434 16435 forces unmount (in case of an unreachable NFS system). 16436 16437 LSB Deprecated Options 16438 16439 The behaviors specified in this section are expected to disappear from a future 16440 version of the LSB; applications should only use the non-LSB-deprecated 16441 behaviors. 16442 16443 -V 16444 16445 print version and exits. 16446 16447 useradd 16448 16449 Name 16450 16451 useradd -- create a new user or update default new user information 16452 16453 Synopsis 16454 16455 useradd [-c comment] [-d home_dir] 16456 [-g initial_group] [-G group[,...]] 16457 [-m [-k skeleton_dir]] [-p passwd] [-r] 16458 [-s shell] [-u uid [ -o]] login 16459 16460 useradd -D [-g default_group] [-b default_home] 16461 [-s default_shell] 16462 16463 Description 16464 16465 When invoked without the -D option, useradd creates a new user account using 16466 the values specified on the command line and the default values from the 16467 system. The new user account will be entered into the system files as needed, 16468 the home directory will be created, and initial files copied, depending on the 16469 command line options. 16470 16471 When invoked with the -D option, useradd will either display the current 16472 default values, or update the default values from the command line. If no 16473 options are specified, useradd displays the current default values. 16474 16475 Standard Options 16476 16477 -c comment 16478 16479 specifies the new user's password file comment field value. 16480 16481 -d home_dir 16482 16483 creates the new user using home_dir as the value for the user's login 16484 directory. The default is to append the login name to default_home and use 16485 that as the login directory name. 16486 16487 -g initial_group 16488 16489 specifies the group name or number of the user's initial login group. The 16490 group name shall exist. A group number shall refer to an already existing 16491 group. If -g is not specified, the implementation will follow the normal 16492 user default for that system. This may create a new group or choose a 16493 default group that normal users are placed in. Applications which require 16494 control of the groups into which a user is placed should specify -g. 16495 16496 -G group,[...] 16497 16498 specifies a list of supplementary groups which the user is also a member 16499 of. Each group is separated from the next by a comma, with no intervening 16500 whitespace. The groups are subject to the same restrictions as the group 16501 given with the -g option. The default is for the user to belong only to the 16502 initial group. 16503 16504 -m [-k skeleton_dir] 16505 16506 specifies the user's home directory will be created if it does not exist. 16507 The files contained in skeleton_dir will be copied to the home directory if 16508 the -k option is used, otherwise the files contained in /etc/skel will be 16509 used instead. Any directories contained in skeleton_dir or /etc/skel will 16510 be created in the user's home directory as well. The -k option is only 16511 valid in conjunction with the -m option. The default is to not create the 16512 directory and to not copy any files. 16513 16514 -p passwd 16515 16516 is the encrypted password, as returned by crypt(3). The default is to 16517 disable the account. 16518 16519 -r 16520 16521 creates a system account, that is, a user with a UID in the range reserved 16522 for system account users. If there is not a UID free in the reserved range 16523 the command will fail. 16524 16525 -s shell 16526 16527 specifies the name of the user's login shell. The default is to leave this 16528 field blank, which causes the system to select the default login shell. 16529 16530 -u uid [-o] 16531 16532 specifies the numerical value of the user's ID. This value shall be unique, 16533 unless the -o option is used. The value shall be non-negative. The default 16534 is the smallest ID value greater than 499 which is not yet used. 16535 16536 Change Default Options 16537 16538 -b default_home 16539 16540 specifies the initial path prefix for a new user's home directory. The 16541 user's name will be affixed to the end of default_home to create the new 16542 directory name if the -d option is not used when creating a new account. 16543 16544 -g default_group 16545 16546 specifies the group name or ID for a new user's initial group. The named 16547 group shall exist, and a numerical group ID shall have an existing entry. 16548 16549 -s default_shell 16550 16551 specifies the name of the new user's login shell. The named program will be 16552 used for all future new user accounts. 16553 16554 -c comment 16555 16556 specifies the new user's password file comment field value. 16557 16558 Application Usage 16559 16560 The -D option will typically be used by system administration packages. Most 16561 applications should not change defaults which will affect other applications 16562 and users. 16563 16564 userdel 16565 16566 Name 16567 16568 userdel -- delete a user account and related files 16569 16570 Synopsis 16571 16572 userdel [-r] login 16573 16574 Description 16575 16576 Delete the user account named login. If there is also a group named login, this 16577 command may delete the group as well, or may leave it alone. 16578 16579 Options 16580 16581 -r 16582 16583 removes files in the user's home directory along with the home directory 16584 itself. Files located in other file system will have to be searched for and 16585 deleted manually. 16586 16587 usermod 16588 16589 Name 16590 16591 usermod -- modify a user account 16592 16593 Synopsis 16594 16595 usermod [-c comment] [-d home_dir [ -m]] 16596 [-g initial_group] [-G group[,...]] 16597 [-l login_name] [-p passwd] 16598 [-s shell] [-u uid [ -o]] login 16599 16600 Options 16601 16602 -c comment 16603 16604 specifies the new value of the user's password file comment field. 16605 16606 -d home_dir 16607 16608 specifies the user's new login directory. If the -m option is given the 16609 contents of the current home directory will be moved to the new home 16610 directory, which is created if it does not already exist. 16611 16612 -g initial_group 16613 16614 specifies the group name or number of the user's new initial login group. 16615 The group name shall exist. A group number shall refer to an already 16616 existing group. 16617 16618 -G group,[...] 16619 16620 specifies a list of supplementary groups which the user is also a member 16621 of. Each group is separated from the next by a comma, with no intervening 16622 whitespace. The groups are subject to the same restrictions as the group 16623 given with the -g option. If the user is currently a member of a group 16624 which is not listed, the user will be removed from the group. 16625 16626 -l login_name 16627 16628 changes the name of the user from login to login_name. Nothing else is 16629 changed. In particular, the user's home directory name should probably be 16630 changed to reflect the new login name. 16631 16632 -p passwd 16633 16634 is the encrypted password, as returned by crypt(3). 16635 16636 -s shell 16637 16638 specifies the name of the user's new login shell. Setting this field to 16639 blank causes the system to select the default login shell. 16640 16641 -u uid [-o] 16642 16643 specifies the numerical value of the user's ID. This value shall be unique, 16644 unless the -o option is used. The value shall be non-negative. Any files 16645 which the user owns and which are located in the directory tree rooted at 16646 the user's home directory will have the file user ID changed automatically. 16647 Files outside of the user's home directory shall be altered manually. 16648 16649 xargs 16650 16651 Name 16652 16653 xargs -- build and execute command lines from standard input 16654 16655 Description 16656 16657 xargs is as specified in ISO POSIX (2003), but with differences as listed 16658 below. 16659 16660 Differences 16661 16662 -E 16663 16664 has unspecified behavior. 16665 16666 -I 16667 16668 has unspecified behavior. 16669 16670 -L 16671 16672 has unspecified behavior. 16673 16674 IV. Execution Environment 16675 16676 Table of Contents 16677 4. File System Hierarchy 16678 5. Additional Recommendations 16679 6. Additional Behaviors 16680 7. Localization 16681 16682 ------------------------------------------------------------------------------- 16683 16684 Chapter 4. File System Hierarchy 16685 16686 An LSB conforming implementation shall provide the mandatory portions of the 16687 filesystem hierarchy specified in the Filesystem Hierarchy Standard (FHS), 16688 together with any additional requirements made in this specification. 16689 16690 An LSB conforming application shall conform to the Filesystem Hierarchy 16691 Standard. 16692 16693 The FHS allows many components or subsystems to be optional. An application 16694 shall check for the existence of an optional component before using it, and 16695 should behave in a reasonable manner if the optional component is not present. 16696 16697 The FHS requirement to locate the operating system kernel in either / or /boot 16698 does not apply if the operating system kernel does not exist as a file in the 16699 filesystem. 16700 16701 The FHS specifies certain behaviors for a variety of commands if they are 16702 present (for example, ping or python). However, LSB applications shall not rely 16703 on any commands beyond those specified by the LSB. The mere existence of a 16704 command may not be used as an indication that the command behaves in any 16705 particular way. 16706 16707 The following directories or links need not be present: /etc/X11 /usr/bin/X11 / 16708 usr/lib/X11 /proc 16709 16710 ------------------------------------------------------------------------------- 16711 16712 /dev 16713 16714 The following shall exist under /dev. Other devices may also exist in /dev. 16715 Device names may exist as symbolic links to other device nodes located in /dev 16716 or subdirectories of /dev. There is no requirement concerning major/minor 16717 number values. 16718 16719 /dev/null 16720 16721 An infinite data source and data sink. Data written to this device shall be 16722 discarded. Reads from this device shall always return end-of-file (EOF). 16723 16724 /dev/zero 16725 16726 This device is a source of zeroed out data. All data written to this device 16727 shall be discarded. A read from this device shall always return the 16728 requested number of bytes, each initialized to the value '\0'. 16729 16730 /dev/tty 16731 16732 In each process, a synonym for the controlling terminal associated with the 16733 process group of that process, if any. All reads and writes to this device 16734 shall behave as if the actual controlling terminal device had been opened. 16735 16736 ------------------------------------------------------------------------------- 16737 16738 Chapter 5. Additional Recommendations 16739 16740 Minimal granted Directory and File permissions 16741 16742 In this Chapter "System" means an "LSB conforming implementation" and 16743 "application" means an "LSB conforming (third party vendor) application". 16744 16745 The system shall grant to the application read and execute permissions on files 16746 needed to use all system interfaces (ABIs) required by the LSB specification. 16747 16748 ------------------------------------------------------------------------------- 16749 16750 Recommendations for applications on ownership and permissions 16751 16752 Directory Write Permissions 16753 16754 The application should not depend on having directory write permission outside 16755 /tmp, /var/tmp, invoking user's home directory and /var/opt/package, (where 16756 package is the name of the application package). 16757 16758 The application should not depend on owning these directories. 16759 16760 For these directories the application should be able to work with directory 16761 write permissions restricted by the S_ISVTXT bit (otherwise known as the 16762 "sticky bit"). 16763 16764 ------------------------------------------------------------------------------- 16765 16766 File Write Permissions 16767 16768 The application should not depend on file write permission on files not owned 16769 by the user it runs under with the exception of its personal inbox /var/mail/ 16770 username. 16771 16772 ------------------------------------------------------------------------------- 16773 16774 File Read and execute Permissions 16775 16776 The application should not depend on having read permission to every file and 16777 directory. 16778 16779 ------------------------------------------------------------------------------- 16780 16781 Suid and Sgid Permissions 16782 16783 The application should not depend on the set user ID or set group ID (the 16784 S_ISUID or S_ISGID permissions of a file not packaged with the application. 16785 Instead, the distribution is responsible for assuming that all system commands 16786 have the required permissions and work correctly. 16787 16788 Rationale: In order to implement common security policies it is strongly 16789 advisable for applications to use the minimum set of security attributes 16790 necessary for correct operation. Applications that require substantial 16791 appropriate privilege are likely to cause problems with such security 16792 policies. 16793 16794 ------------------------------------------------------------------------------- 16795 16796 Privileged users 16797 16798 In general, applications should not depend on running as a privileged user. 16799 This specification uses the term "appropriate privilege" throughout to identify 16800 operations that cannot be achieved without some special granting of additional 16801 privilege. 16802 16803 Applications that have a reason to run with appropriate privilege should 16804 outline this reason clearly in their documentation. Users of the application 16805 should be informed, that "this application demands security privileges, which 16806 could interfere with system security". 16807 16808 The application should not contain binary-only software that requires being run 16809 with appropriate privilege, as this makes security auditing harder or even 16810 impossible. 16811 16812 ------------------------------------------------------------------------------- 16813 16814 Changing permissions 16815 16816 The application shall not change permissions of files and directories that do 16817 not belong to its own package. Should an application require that certain files 16818 and directories not directly belonging to the package have a particular 16819 ownership, the application shall document this requirement, and may fail during 16820 installation if the permissions on these files is inappropriate. 16821 16822 ------------------------------------------------------------------------------- 16823 16824 Removable Media (Cdrom, Floppy, etc.) 16825 16826 Applications that expect to be runnable from removable media should not depend 16827 on logging in as a privileged user, and should be prepared to deal with a 16828 restrictive environment. Examples of such restrictions could be default mount 16829 options that disable set-user/group-ID attributes, disabling block or 16830 character-special files on the medium, or remapping the user and group IDs of 16831 files away from any privileged value. 16832 16833 16834 Rationale: System vendors and local system administrators want to run 16835 applications from removable media, but want the possibility to control what 16836 the application can do. 16837 16838 ------------------------------------------------------------------------------- 16839 16840 Installable applications 16841 16842 Where the installation of an application needs additional privileges, it must 16843 clearly document all files and system databases that are modified outside of 16844 those in /opt/pkg-name and /var/opt/pkg-name, other than those that may be 16845 updated by system logging or auditing activities. 16846 16847 Without this, the local system administrator would have to blindly trust a 16848 piece of software, particularly with respect to its security. 16849 16850 ------------------------------------------------------------------------------- 16851 16852 Chapter 6. Additional Behaviors 16853 16854 Mandatory Optional Behaviors 16855 16856 This section specifies behaviors in which there is optional behavior in one of 16857 the standards on which the LSB relies, and where the LSB requires a specific 16858 behavior. 16859 16860 16861 Note: The LSB does not require the kernel to be Linux; the set of mandated 16862 options reflects current existing practice, but may be modified in future 16863 releases. 16864 16865 LSB conforming implementations shall support the following options defined 16866 within the ISO POSIX (2003): 16867 16868 _POSIX_FSYNC 16869 _POSIX_MAPPED_FILES 16870 _POSIX_MEMLOCK 16871 _POSIX_MEMLOCK_RANGE 16872 _POSIX_MEMORY_PROTECTION 16873 _POSIX_PRIORITY_SCHEDULING 16874 _POSIX_REALTIME_SIGNALS 16875 _POSIX_THREAD_ATTR_STACKADDR 16876 _POSIX_THREAD_ATTR_STACKSIZE 16877 _POSIX_THREAD_PROCESS_SHARED 16878 _POSIX_THREAD_SAFE_FUNCTIONS 16879 _POSIX_THREADS 16880 _XOPEN_UNIX 16881 16882 The opendir() function shall consume a file descriptor in the same fashion as 16883 open, and therefore may fail with EMFILE or ENFILE. 16884 16885 The START and STOP termios characters shall be changeable, as described as 16886 optional behavior in the "General Terminal Interface" section of the ISO POSIX 16887 (2003). 16888 16889 The access() function function shall fail with errno set to EINVAL if the amode 16890 argument contains bits other than those set by the bitwise inclusive OR of 16891 R_OK, W_OK, X_OK and F_OK. 16892 16893 The link() function shall require access to the existing file in order to 16894 succeed, as described as optional behavior in the ISO POSIX (2003). 16895 16896 Calling unlink() on a directory shall fail. Calling link() specifying a 16897 directory as the first argument shall fail. See also unlink. 16898 16899 16900 Note: Linux allows rename() on a directory without having write access, but 16901 the LSB does not require this. 16902 16903 ------------------------------------------------------------------------------- 16904 16905 Special Requirements 16906 16907 LSB conforming systems shall enforce certain special additional restrictions 16908 above and beyond those required by ISO POSIX (2003). 16909 16910 16911 Note: These additional restrictions are required in order to support the 16912 testing and certification programs associated with the LSB. In each case, 16913 these are values that defined macros must not have; conforming applications 16914 that use these values shall trigger a failure in the interface that is 16915 otherwise described as a "may fail". 16916 16917 The fcntl() function shall treat the "cmd" value -1 as invalid. 16918 16919 The whence value -1 shall be an invalid value for the lseek(), fseek() and 16920 fcntl() functions. 16921 16922 The value -5 shall be an invalid signal number. 16923 16924 If the sigaddset() or sigdelset() functions are passed an invalid signal 16925 number, they shall return with EINVAL. Implementations are only required to 16926 enforce this requirement for signal numbers which are specified to be invalid 16927 by this specification (such as the -5 mentioned above). 16928 16929 The mode value -1 to the access() function shall be treated as invalid. 16930 16931 A value of -1 shall be an invalid "_PC_..." value for pathconf(). 16932 16933 A value of -1 shall be an invalid "_SC..." value for sysconf(). 16934 16935 The nl_item value -1 shall be invalid for nl_langinfo. 16936 16937 The value -1 shall be an invalid "_CS_..." value for confstr(). 16938 16939 The value "z" shall be an invalid mode argument to popen(). 16940 16941 ------------------------------------------------------------------------------- 16942 16943 Chapter 7. Localization 16944 16945 In order to install a message catalog, the installation procedure shall supply 16946 the message catalog in a format readable by the msgfmt utility, which shall be 16947 invoked to compile the message catalog into an appropriate binary format on the 16948 target system. 16949 16950 16951 Rationale: The original intent was to allow an application to contain the 16952 binary GNU MO format files. However, the format of these files is not 16953 officially stable, hence it is necessary to compile these catalogs on the 16954 target system. These binary catalogs may differ from architecture to 16955 architecture as well. 16956 16957 The resulting binary message catalog shall be located in the package's private 16958 area under /opt, and the application may use bindtextdomain() to specify this 16959 location. 16960 16961 Implementations shall support the POSIX and C locales as specified in the ISO 16962 POSIX (2003). 16963 16964 ------------------------------------------------------------------------------- 16965 16966 Regular Expressions 16967 16968 Utilities that process regular expressions shall support Basic Regular 16969 Expressions and Extended Regular Expressions as specified in ISO POSIX (2003), 16970 with the following exceptions: 16971 16972 Range expression (such as [a-z]) can be based on code point order instead of 16973 collating element order. 16974 16975 Equivalence class expression (such as [=a=]) and multi-character collating 16976 element expression (such as [.ch.]) are optional. 16977 16978 Handling of a multi-character collating element is optional. 16979 16980 This affects at least the following utilities: grep (grep) (including egrep), 16981 sed (sed), and awk (awk). 16982 16983 ------------------------------------------------------------------------------- 16984 16985 Pattern Matching Notation 16986 16987 Utilities that perform filename pattern matching (also known as Filename 16988 Globbing) shall do it as specified in ISO POSIX (2003), Pattern Matching 16989 Notation, with the following exceptions: 16990 16991 Pattern bracket expressions (such as [a-z]) can be based on code point order 16992 instead of collating element order. 16993 16994 Equivalence class expression (such as [=a=]) and multi-character collating 16995 element expression (such as [.ch.]) are optional. 16996 16997 Handling of a multi-character collating element is optional. 16998 16999 This affects at least the following utilities: cpio (cpio), find (find), ls (ls 17000 ) and tar (tar). 17001 17002 V. System Initialization 17003 17004 Table of Contents 17005 8. System Initialization 17006 17007 ------------------------------------------------------------------------------- 17008 17009 Chapter 8. System Initialization 17010 17011 Cron Jobs 17012 17013 In addition to the individual user crontab files specified by ISO POSIX (2003) 17014 stored under /var/spool/cron, the process that executes scheduled commands 17015 shall also process the following additional crontab files: /etc/crontab, /etc/ 17016 cron.d/* The installation of a package shall not modify the configuration file 17017 /etc/crontab. 17018 17019 If a package wishes to install a job that has to be executed periodically, it 17020 shall place a file in one of the following directories: 17021 17022 /etc/cron.daily 17023 /etc/cron.weekly 17024 /etc/cron.monthly 17025 17026 As these directory names suggest, the files within them are executed on a 17027 daily, weekly, or monthly basis, respectively, under the control of an entry in 17028 one of the system crontab files. See below for the rules concerning the names 17029 of files in these directories. 17030 17031 It is recommended that files installed in any of these directories be scripts 17032 (e.g. shell scripts, Perl scripts, etc.) so that they may be modified by the 17033 local system administrator. 17034 17035 The scripts in these directories should check if all necessary programs are 17036 installed before they try to execute them. Otherwise, problems will arise if a 17037 package is removed (but not purged), since the configuration files are kept on 17038 the system in this situation. 17039 17040 If a certain job has to be executed at a different frequency (e.g. more 17041 frequently than daily), the package shall install a file /etc/cron.d/cron-name 17042 tagged as a configuration file. This file uses the same syntax as /etc/crontab 17043 and is processed by the system automatically. 17044 17045 To avoid namespace conflicts in the /etc/cron.* directories, the filenames used 17046 by LSB-compliant packages in /etc/cron.daily, /etc/cron.weekly, /etc/ 17047 cron.monthly, or /etc/cron.d shall come from a managed namespace. These 17048 filenames may be assigned using one of the following methods: 17049 17050 * Assigned namespace. This namespace consists of names which only use the 17051 character set [a-z0-9]. In order to avoid conflicts these cron script names 17052 shall be reserved through the Linux Assigned Names and Numbers Authority 17053 (LANANA). Information about the LANANA may be found at www.lanana.org. 17054 17055 Commonly used names shall be reserved in advance; developers for projects 17056 should be encouraged reserve names from LANANA, so that each distribution 17057 can use the same name, and to avoid conflicts with other projects. 17058 17059 * Hierarchical namespace. This namespace consists of script names of the 17060 form: [hier1]-[hier2]-...-[name], where name is again taken from the 17061 character set [a-z0-9], and where there may be one or more [hier-n] 17062 components. [hier1] may either be an LSB provider name assigned by the 17063 LANANA, or it may be owners' DNS name in lower case, with at least one '.'. 17064 e.g. "debian.org", "staroffice.sun.com", etc. The LSB provider name 17065 assigned by LANANA shall only consist of the ASCII characters [a-z0-9]. 17066 17067 * Reserved namespace. This namespace consists of script names which begin 17068 with the character '_', and is reserved for distribution use only. This 17069 namespace should be used for core packages only. 17070 17071 ------------------------------------------------------------------------------- 17072 17073 Init Script Actions 17074 17075 Init files provided by LSB applications shall accept one argument, saying what 17076 to do: 17077 17078 start start the service 17079 stop stop the service 17080 restart stop and restart the service if the service is already running, 17081 otherwise start the service 17082 try-restart restart the service if the service is already running 17083 reload cause the configuration of the service to be reloaded without 17084 actually stopping and restarting the service 17085 force-reload cause the configuration to be reloaded if the service supports 17086 this, otherwise restart the service if it is running 17087 status print the current status of the service 17088 17089 The start, stop, restart, force-reload, and status commands shall be supported 17090 by all init files; the reload and the try-restart options are optional. Other 17091 init script actions may be defined by the init script. 17092 17093 Init files shall ensure that they will behave sensibly if invoked with start 17094 when the service is already running, or with stop when it isn't, and that they 17095 don't kill unfortunately-named user processes. The best way to achieve this is 17096 to use the init-script functions provided by /lib/lsb/init-functions. 17097 17098 If a service reloads its configuration automatically (as in the case of cron, 17099 for example), the reload option of the init file shall behave as if the 17100 configuration has been reloaded successfully. The restart, try-restart, reload 17101 and force-reload action may be atomic; i.e. if a service is known not be 17102 operational after a restart or reload, the script may return an error without 17103 any further action. 17104 17105 These executable files shall not fail obscurely when the configuration files 17106 remain but the package has been removed, as the default in [the packaging 17107 system] is to leave configuration files on the system after the package has 17108 been removed. Only when it is executed with the [purge] option will [the 17109 packaging system] remove configuration files. Therefore, you should include a 17110 test statement at the top of the file, like this: 17111 17112 test -f program-executed-later-in-file || exit 5 17113 17114 or take the equivalent action if the init file is not a shell script. 17115 17116 If the status command is given, the init script will return the following exit 17117 status codes. 17118 17119 0 program is running or service is OK 17120 1 program is dead and /var/run pid file exists 17121 2 program is dead and /var/lock lock file exists 17122 3 program is not running 17123 4 program or service status is unknown 17124 5-99 reserved for future LSB use 17125 100-149 reserved for distribution use 17126 150-199 reserved for application use 17127 200-254 reserved 17128 17129 In the case of init script commands other than "status" (i.e., "start", "stop", 17130 "restart", "try-restart", "reload", and "force-reload"), the init script shall 17131 return an exit status of zero if the action described by the argument has been 17132 successful. Otherwise, the exit status shall be non-zero, as defined below. In 17133 addition to straightforward success, the following situations are also to be 17134 considered successful: 17135 17136 * restarting a service (instead of reloading it) with the "force-reload" 17137 argument 17138 17139 * running "start" on a service already running 17140 17141 * running "stop" on a service already stopped or not running 17142 17143 * running "restart" on a service already stopped or not running 17144 17145 * running "try-restart" on a service already stopped or not running 17146 17147 17148 17149 In case of an error, while processing any init script action except for 17150 "status", the init script shall print an error message and return one of the 17151 following non-zero exit status codes. 17152 17153 1 generic or unspecified error (current practice) 17154 2 invalid or excess argument(s) 17155 3 unimplemented feature (for example, "reload") 17156 4 user had insufficient privilege 17157 5 program is not installed 17158 6 program is not configured 17159 7 program is not running 17160 8-99 reserved for future LSB use 17161 100-149 reserved for distribution use 17162 150-199 reserved for application use 17163 200-254 reserved 17164 17165 Error and status messages should be printed with the logging functions such as 17166 log_failure_msg and so on. Scripts may write to standard error or standard 17167 output, but implementations need not present text written to standard error/ 17168 output to the user or do anything else with it. 17169 17170 Since init files may be run manually by a system administrator with 17171 non-standard environment variable values for PATH, USER, LOGNAME, etc. init 17172 files shall not depend on the values of these environment variables. They 17173 should set them to some known/default values if they are needed. 17174 17175 ------------------------------------------------------------------------------- 17176 17177 Comment Conventions for Init Scripts 17178 17179 LSB applications which need to execute script(s) at bootup and/or shutdown may 17180 provide one or more init.d files. These files are installed by the 17181 install_initd program described below, which copies it into a standard 17182 directory and makes whatever other adjustments (creation of symlinks, creation 17183 of entries in a database, etc.) are necessary so that the script can be run at 17184 boot-time. [2] 17185 17186 In the init.d file, information about the shell script shall be delimited by 17187 the lines "### BEGIN INIT INFO" and "### END INIT INFO". These delimiter lines 17188 may containg trailing whitespace, which shall be ignored. Inside this block 17189 there shall be lines of the form "# {keyword}: [arg1] [arg2] ...". (All lines 17190 inside this block start with a hash ('#') character in the first column, so 17191 that shell treats them as comments.) There shall be exactly one space character 17192 between "#" and the keyword.[3] The following keywords, with their arguments 17193 are defined in this specification: 17194 17195 # Provides: boot_facility_1 [ boot_facility_2 ...] 17196 # Required-Start: boot_facility_1 [ boot_facility_2 ...] 17197 # Required-Stop: boot_facility_1 [ boot_facility_2 ...] 17198 # Should-Start: boot_facility_1 [ boot_facility_2 ...] 17199 # Should-Stop: boot_facility_1 [ boot_facility_2 ...] 17200 # Default-Start: run_level_1 [ run_level_2 ...] 17201 # Default-Stop: run_level_1 [ run_level_2 ...] 17202 # Short-Description: short_description 17203 # Description: multiline_description 17204 17205 Additional keywords may be defined in future LSB specifications. Distributions 17206 may define local extensions by using the prefix "X-[distribution name]" --- for 17207 example, "X-RedHat-foobardecl", or "X-Debian-xyzzydecl". 17208 17209 An init.d shell script may declare using the "Required-Start: " header that it 17210 shall not be run until certain boot facilities are provided. This information 17211 is used by the installation tool or the boot-time boot-script execution 17212 facility to assure that init scripts are run in the correct order. When an init 17213 script is run with a "start" argument, the boot facility or facilities 17214 specified in the "Provides" header shall be considered present, and hence init 17215 scripts which require those boot facilities would then be eligble to be run. 17216 When an init script is run with a "stop" argument, the boot facilities 17217 specified in the "Provides" header are considered no longer present. There are 17218 naming conventions for boot facilities and system facilities, as described in a 17219 following section. 17220 17221 Similarly, the "Required-Stop:" header defines which facilities shall still be 17222 available during the shutdown of that service. Hence, the init script system 17223 should avoid stopping shell scripts which provide those facilities until this 17224 shell script is stopped. 17225 17226 The "Should-Start:" header defines which facilities if present should be 17227 started before this service. This allows for weak dependencies which do not 17228 cause the service to fail if a facility is not available. But may cause reduced 17229 functionality of the service. Compliant applications should not rely on the 17230 existence of this feature. 17231 17232 The "Should-Stop:" header defines which facilities should be still available 17233 during the shutdown of that service. 17234 17235 The "Default-Start" and "Default-Stop" headers define which run levels should 17236 by default run the script with a start or stop argument, respectively, to start 17237 or stop the services controlled by the init script. [4] 17238 17239 The "Short-Description" and "Description" header fields are used to provide 17240 text which describes the actions of the init script. The "short_description" 17241 shall be a relatively short, pithy description of the init script, where as the 17242 "multiline_description" can be a much longer piece of text that may span 17243 mulitple lines. In a multiline description, each continuation line shall begin 17244 with a '#' followed by tab character or a '#' followed by at least two space 17245 characters. The multiline description is terminated by the first line that does 17246 not match this criteria. 17247 17248 The comment conventions described in this session are only required for use by 17249 LSB-compliant applications; system init scripts as provided by LSB-compliant 17250 run-time environments are not required to use the scheme outlined here. 17251 17252 ------------------------------------------------------------------------------- 17253 17254 Installation and Removal of init.d Files 17255 17256 An init.d file is installed in /etc/init.d (which may be a symlink to another 17257 location). This can be done by the package installer. See Script Names>. During 17258 the package's postinstall script, the program "/usr/lib/lsb/install_initd" 17259 configures the distribution's boot script system to call the package's init.d 17260 file at the appropriate time. [5] 17261 17262 The install_initd program takes a single argument, the pathname to the /etc/ 17263 init.d file. For example: 17264 17265 /usr/lib/lsb/install_initd /etc/init.d/example.com-coffeed 17266 17267 The install_initd program shall return an exit status of zero if the init.d 17268 file has been successfully installed or if the the init.d file was already 17269 installed. If the required boot facilities cannot be fulfilled an exit status 17270 of one shall be returned and the init.d file shall not be installed. 17271 17272 When a software package is removed, the package's preuninstall script shall 17273 call /usr/lib/lsb/remove_initd and pass the pathname to the /etc/init.d file. 17274 The package manager is still responsible for removing the /etc/init.d file; the 17275 remove_initd program is provided in case the distribution needs to clean up any 17276 other modifications in the distribution's boot script system that might have 17277 been made by the install_initd program. For example: 17278 17279 /usr/lib/lsb/remove_initd /etc/init.d/example.com-coffeed 17280 17281 The remove_initd program shall return an exit status of zero if the init.d file 17282 has been successfully removed or if the the init.d file is not installed. If 17283 another init.d file which depends on a boot facility provided by this init.d 17284 file is installed, an exit status of one shall be returned and the init.d file 17285 shall remained installed. 17286 17287 There should be a tool available to the user (e.g., RedHat's chkconfig) which 17288 can be used by the system administrator to easily manipulate at which init 17289 levels a particular init.d script is started or stopped. This specification 17290 currently does not specify such an interface, however. 17291 17292 ------------------------------------------------------------------------------- 17293 17294 Run Levels 17295 17296 The following run levels are specified for use by the "Default-Start:" and 17297 "Default-Stop:" specifiers as defined by the section Comment Conventions for 17298 Init Scripts>. Many LSB run-time environments commonly use these run level 17299 definitions, and in the absence of other considerations, providers of run-time 17300 environments are strongly encouraged to follow this convention to provide 17301 consistency for system administrators who need to work with multiple 17302 distributions. However, it is not required that LSB-compliant run-time 17303 environments use these run levels; the distribution-provided install_initd 17304 script may map the run levels specified below to whatever 17305 distribution-specified run levels are most appropriate. 17306 17307 0 halt 17308 1 single user mode 17309 2 multiuser with no network services exported 17310 3 normal/full multiuser 17311 4 reserved for local use, default is normal/full multiuser 17312 5 multiuser with xdm or equivalent 17313 6 reboot 17314 17315 ------------------------------------------------------------------------------- 17316 17317 Facility Names 17318 17319 Boot facilities are used to indicate dependencies in init scripts, as defined 17320 in a previous section. Facility names that begin with a dollar sign ('$') are 17321 system facility names, defined by the LSB, and SHALL be provided by 17322 distributions. [6] LSB applications shall not provide facilities that begin 17323 with a dollar sign. This document defines the following facility names: 17324 17325 $local_fs all local filesystems are mounted 17326 $network low level networking (ethernet card; may imply PCMCIA running) 17327 $named daemons which may provide hostname resolution (if present) are 17328 running[7] 17329 $portmap daemons providing SunRPC/ONCRPC portmapping service[8] (if present) 17330 are running 17331 $remote_fs all remote filesystems are mounted[9]. 17332 $syslog system logger is operational 17333 $time the system time has been set [10] 17334 17335 Other (non-system) facilities may be defined by other LSB applications. These 17336 facilities shall be named using the same conventions defined for naming init.d 17337 script names. Commonly, the facility provided by an LSB application init.d 17338 script will have the same name as the name assigned to the init.d script. 17339 17340 ------------------------------------------------------------------------------- 17341 17342 Script Names 17343 17344 Since the init.d scripts shall live in a single directory, they shall come from 17345 a single namespace. Three means of assigning names from this namespace are 17346 available: 17347 17348 * Assigned namespace. This namespace consists of names which only use the 17349 character set [a-z0-9]. This space is desirable for scripts which system 17350 administrators may often wish to run manually: e.g., "/etc/init.d/named 17351 restart" In order to avoid conflicts these init.d names shall be reserved 17352 through the Linux Assigned Names and Numbers Authority (LANANA). 17353 Information about the LANANA may be found at www.lanana.org. 17354 17355 Commonly used names shall be reserved in advance; developers for projects 17356 should be encouraged to reserve names from LANANA, so that each 17357 distribution can use the same name, and to avoid conflicts with other 17358 projects. 17359 17360 * Hierarchical namespace. This namespace consists of scripts names which look 17361 like this: [hier1]-[hier2]-...-[name], where name is again taken the 17362 character set [a-z0-9], and where there may be one or more [hier-n] 17363 components. [hier1] may either be an LSB provider name assigned by the 17364 LANANA, or it may be owners' DNS name in lower case, with at least one '.' 17365 (e.g., "debian.org", "staroffice.sun.com"). The LSB provider name assigned 17366 by LANANA shall only consist of the ASCII characters [a-z0-9]. 17367 17368 * Reserved namespace. This namespace consists of script names which begin 17369 with the character '_', and is reserved for distribution use only. This 17370 namespace should be used for core packages only, and in general use of this 17371 namespace is highly discouraged. 17372 17373 In general, if a package or some system function is likely to be used on 17374 multiple systems, the package developers or the distribution SHOULD get a 17375 registered name through LANANA, and distributions should strive to use the same 17376 name whenever possible. For applications which may not be "core" or may not be 17377 commonly installed, the hierarchical namespace may be more appropriate. An 17378 advantage to the hierarchical namespace is that there is no need to consult 17379 with the LANANA before obtaining an assigned name. 17380 17381 Short names are highly desirable, since many system administrators like to use 17382 them to manually start and stop services. Given this, they should be 17383 standardized on a per-package basis. This is the rationale behind having a 17384 LANANA organization to assign these names. The LANANA may be called upon to 17385 handle other namespace issues, such as package/prerequisites naming (which is 17386 essential to making prerequisites to work correctly). 17387 17388 ------------------------------------------------------------------------------- 17389 17390 Init Script Functions 17391 17392 Each LSB-compliant init.d script shall source the file /lib/lsb/init-functions. 17393 This file shall cause the following shell script commands to be defined. This 17394 can be done either by adding a directory to the PATH variable which defines 17395 these commands, or by defining sh aliases. While the distribution-provided 17396 aliases may choose to use shell extensions (at the distribution's option), the 17397 LSB init.d files themselves should only depend in shell features as defined by 17398 the LSB. 17399 17400 The start_daemon, killproc and pidofproc functions shall use this algorithm for 17401 determining the status and the pid(s) of the specified program. They shall read 17402 the pidfile specified or otherwise /var/run/basename.pid and use the pid(s) 17403 herein when determining whether a program is running. The method used to 17404 determine the status is implementation defined, but should allow for non-binary 17405 programs. [11] Compliant implementations may use other mechanisms besides those 17406 based on pidfiles, unless the -p pidfile option has been used. Compliant 17407 applications should not rely on such mechanisms and should always use a 17408 pidfile. When a program is stopped, it should delete its pidfile. Multiple pid 17409 (s) shall be separated by a single space in the pidfile and in the output of 17410 pidofproc. 17411 17412 This runs the specified program as a daemon. start_daemon shall 17413 start_daemon check if the program is already running using the algorithm 17414 [-f] [-n given above. If so, it shall not start another copy of the 17415 nicelevel] [-p daemon unless the -f option is given. The -n option specifies a 17416 pidfile] nice level. See nice(1). start_daemon should return the LSB 17417 pathname [args] defined exit status codes. It shall return 0 if the program has 17418 been successfully started or is running and not 0 otherwise. 17419 This stops the specified program. The program is found using 17420 the algorithm given above. If a signal is specified, using the 17421 -signal_name or -signal_number syntaxes as specified by the 17422 kill command, the program is sent that signal. Otherwise, a 17423 killproc [-p SIGTERM followed by a SIGKILL after some number of seconds 17424 pidfile] shall be sent. If a program has been terminated, the pidfile 17425 pathname should be removed if the terminated process has not already 17426 [signal] done so. Compliant applications may use the basename instead of 17427 the pathname. killproc should return the LSB defined exit 17428 status codes. If called without a signal, it shall return 0 if 17429 the program has been stopped or is not running and not 0 17430 otherwise. If a signal is given, it shall return 0 only if the 17431 program is running. 17432 This function returns one or more pid(s) for a particular 17433 pidofproc [-p daemon using the algorithm given above. Only pids of running 17434 pidfile] processes should be returned. Compliant applications may use 17435 pathname the basename instead of the pathname. pidofproc should return 17436 the LSB defined exit status codes for "status". It shall return 17437 0 if the program is running and not 0 otherwise. 17438 log_success_msg This requests the distribution to print a success message. The 17439 "message" message should be relatively short; no more than 60 characters 17440 is highly desirable. 17441 log_failure_msg This requests the distribution to print a failure message. The 17442 "message" message should be relatively short; no more than 60 characters 17443 is highly desirable. 17444 log_warning_msg This requests the distribution to print a warning message. The 17445 "message" message should be relatively short; no more than 60 characters 17446 is highly desirable. 17447 17448 VI. Users & Groups 17449 17450 Table of Contents 17451 9. Users & Groups 17452 17453 ------------------------------------------------------------------------------- 17454 17455 Chapter 9. Users & Groups 17456 17457 User and Group Database 17458 17459 The format of the User and Group databases is not specified. Programs may only 17460 read these databases using the provided API. Changes to these databases should 17461 be made using the provided commands. 17462 17463 ------------------------------------------------------------------------------- 17464 17465 User & Group Names 17466 17467 Below is a table of required mnemonic user and group names. This specification 17468 makes no attempt to numerically assign uid or gid numbers. The exception is the 17469 uid and gid for "root" which are equal to 0. 17470 17471 Table 9-1. Required User & Group Names 17472 17473 +-----------------------------------------------------------------------------+ 17474 |User |Group |Comments | 17475 |---------+---------+---------------------------------------------------------| 17476 |root |root |Administrative user with all appropriate privileges | 17477 |---------+---------+---------------------------------------------------------| 17478 |bin |bin |Legacy UID/GID[a] | 17479 |---------+---------+---------------------------------------------------------| 17480 |daemon |daemon |Legacy UID/GID[b] | 17481 |-----------------------------------------------------------------------------| 17482 |Notes: | 17483 |a. The 'bin' UID/GID is included for compatibility with legacy applications. | 17484 |New applications should no longer use the 'bin' UID/GID. | 17485 |b. The 'daemon' UID/GID was used as an unprivileged UID/GID for daemons to | 17486 |execute under in order to limit their access to the system. Generally daemons| 17487 |should now run under individual UID/GIDs in order to further partition | 17488 |daemons from one another. | 17489 +-----------------------------------------------------------------------------+ 17490 17491 Below is a table of optional mnemonic user and group names. This specification 17492 makes no attempt to numerically assign uid or gid numbers. If the username 17493 exists on a system, then they should be in the suggested corresponding group. 17494 These user and group names are for use by distributions, not by applications. 17495 17496 Table 9-2. Optional User & Group Names 17497 17498 +---------------------------------------------------+ 17499 |User |Group |Comments | 17500 |--------+--------+---------------------------------| 17501 |adm |adm |Administrative special privileges| 17502 |--------+--------+---------------------------------| 17503 |lp |lp |Printer special privileges | 17504 |--------+--------+---------------------------------| 17505 |sync |sync |Login to sync the system | 17506 |--------+--------+---------------------------------| 17507 |shutdown|shutdown|Login to shutdown the system | 17508 |--------+--------+---------------------------------| 17509 |halt |halt |Login to halt the system | 17510 |--------+--------+---------------------------------| 17511 |mail |mail |Mail special privileges | 17512 |--------+--------+---------------------------------| 17513 |news |news |News special privileges | 17514 |--------+--------+---------------------------------| 17515 |uucp |uucp |UUCP special privileges | 17516 |--------+--------+---------------------------------| 17517 |operator|root |Operator special privileges | 17518 |--------+--------+---------------------------------| 17519 |man |man |Man special privileges | 17520 |--------+--------+---------------------------------| 17521 |nobody |nobody |Used by NFS | 17522 +---------------------------------------------------+ 17523 17524 The differences in numeric values of the uids and gids between systems on a 17525 network can be reconciled via NIS, rdist(1), rsync(1), or ugidd(8). Only a 17526 minimum working set of "user names" and their corresponding "user groups" are 17527 required. Applications cannot assume non system user or group names will be 17528 defined. 17529 17530 Applications cannot assume any policy for the default umask or the default 17531 directory permissions a user may have. Applications should enforce user only 17532 file permissions on private files such as mailboxes. The location of the users 17533 home directory is also not defined by policy other than the recommendations of 17534 the FHS and shall be obtained by the *pwnam(3) calls. 17535 17536 ------------------------------------------------------------------------------- 17537 17538 UID Ranges 17539 17540 The system UIDs from 0 to 99 should be statically allocated by the system, and 17541 shall not be created by applications. 17542 17543 The system UIDs from 100 to 499 should be reserved for dynamic allocation by 17544 system administrators and post install scripts using useradd(1). 17545 17546 ------------------------------------------------------------------------------- 17547 17548 Rationale 17549 17550 The purpose of specifying optional users and groups is to reduce the potential 17551 for name conflicts between applications and distributions. 17552 17553 ------------------------------------------------------------------------------- 17554 17555 Appendix A. Alphabetical Listing of Interfaces 17556 17557 ------------------------------------------------------------------------------- 17558 17559 libc 17560 17561 The behaviour of the interfaces in this library is specified by the following 17562 Standards. 17563 17564 Large File Support 17565 this specification 17566 SUSv2 17567 ISO POSIX (2003) 17568 SVID Issue 3 17569 SVID Issue 4 17570 17571 Table A-1. libc Function Interfaces 17572 17573 +-----------------------------------------------------------------------------+ 17574 |_Exit(GLIBC_2.1.1)[1] |getrlimit(GLIBC_2.1.1)[1] |sigandset(GLIBC_2.1.1) | 17575 | | |[1] | 17576 |--------------------------+--------------------------+-----------------------| 17577 |_IO_feof(GLIBC_2.0)[1] |getrlimit64(GLIBC_2.0)[1] |sigblock(GLIBC_2.0)[1] | 17578 |--------------------------+--------------------------+-----------------------| 17579 |_IO_getc(GLIBC_2.0)[1] |getrusage(GLIBC_2.0)[1] |sigdelset(GLIBC_2.0)[1]| 17580 |--------------------------+--------------------------+-----------------------| 17581 |_IO_putc(GLIBC_2.0)[1] |getservbyname(GLIBC_2.0) |sigemptyset(GLIBC_2.0) | 17582 | |[1] |[1] | 17583 |--------------------------+--------------------------+-----------------------| 17584 |_IO_puts(GLIBC_2.0)[1] |getservbyport(GLIBC_2.0) |sigfillset(GLIBC_2.0) | 17585 | |[1] |[1] | 17586 |--------------------------+--------------------------+-----------------------| 17587 |__assert_fail(GLIBC_2.0) |getservent(GLIBC_2.0)[1] |siggetmask(GLIBC_2.0) | 17588 |[1] | |[1] | 17589 |--------------------------+--------------------------+-----------------------| 17590 |__ctype_b_loc[1] |getsid()[1] |sighold()[1] | 17591 |--------------------------+--------------------------+-----------------------| 17592 |__ctype_get_mb_cur_max |getsockname(GLIBC_2.0)[1] |sigignore(GLIBC_2.0)[1]| 17593 |(GLIBC_2.0)[1] | | | 17594 |--------------------------+--------------------------+-----------------------| 17595 |__ctype_tolower_loc[1] |getsockopt()[1] |siginterrupt()[1] | 17596 |--------------------------+--------------------------+-----------------------| 17597 |__ctype_toupper_loc[1] |getsubopt()[1] |sigisemptyset()[1] | 17598 |--------------------------+--------------------------+-----------------------| 17599 |__cxa_atexit(GLIBC_2.1.3) |gettext(GLIBC_2.1.3)[1] |sigismember | 17600 |[1] | |(GLIBC_2.1.3)[1] | 17601 |--------------------------+--------------------------+-----------------------| 17602 |__errno_location |gettimeofday(GLIBC_2.0)[1]|siglongjmp(GLIBC_2.0) | 17603 |(GLIBC_2.0)[1] | |[1] | 17604 |--------------------------+--------------------------+-----------------------| 17605 |__fpending(GLIBC_2.2)[1] |getuid(GLIBC_2.2)[1] |signal(GLIBC_2.2)[1] | 17606 |--------------------------+--------------------------+-----------------------| 17607 |__fxstat(GLIBC_2.0)[1] |getutent(GLIBC_2.0)[1] |sigorset(GLIBC_2.0)[1] | 17608 |--------------------------+--------------------------+-----------------------| 17609 |__fxstat64(GLIBC_2.2)[1] |getutent_r(GLIBC_2.2)[1] |sigpause(GLIBC_2.2)[1] | 17610 |--------------------------+--------------------------+-----------------------| 17611 |__getpagesize(GLIBC_2.0) |getutxent(GLIBC_2.0)[1] |sigpending(GLIBC_2.0) | 17612 |[1] | |[1] | 17613 |--------------------------+--------------------------+-----------------------| 17614 |__getpgid(GLIBC_2.0)[1] |getutxid(GLIBC_2.0)[1] |sigprocmask(GLIBC_2.0) | 17615 | | |[1] | 17616 |--------------------------+--------------------------+-----------------------| 17617 |__h_errno_location[1] |getutxline()[1] |sigqueue()[1] | 17618 |--------------------------+--------------------------+-----------------------| 17619 |__isinf[1] |getw()[1] |sigrelse()[1] | 17620 |--------------------------+--------------------------+-----------------------| 17621 |__isinff[1] |getwc()[1] |sigreturn()[1] | 17622 |--------------------------+--------------------------+-----------------------| 17623 |__isinfl[1] |getwchar()[1] |sigset()[1] | 17624 |--------------------------+--------------------------+-----------------------| 17625 |__isnan[1] |getwd()[1] |sigstack()[1] | 17626 |--------------------------+--------------------------+-----------------------| 17627 |__isnanf[1] |glob()[1] |sigsuspend()[1] | 17628 |--------------------------+--------------------------+-----------------------| 17629 |__isnanl[1] |glob64()[1] |sigtimedwait()[1] | 17630 |--------------------------+--------------------------+-----------------------| 17631 |__libc_current_sigrtmax |globfree(GLIBC_2.1)[1] |sigwait(GLIBC_2.1)[1] | 17632 |(GLIBC_2.1)[1] | | | 17633 |--------------------------+--------------------------+-----------------------| 17634 |__libc_current_sigrtmin |globfree64(GLIBC_2.1)[1] |sigwaitinfo(GLIBC_2.1) | 17635 |(GLIBC_2.1)[1] | |[1] | 17636 |--------------------------+--------------------------+-----------------------| 17637 |__libc_start_main |gmtime(GLIBC_2.0)[1] |sleep(GLIBC_2.0)[1] | 17638 |(GLIBC_2.0)[1] | | | 17639 |--------------------------+--------------------------+-----------------------| 17640 |__lxstat(GLIBC_2.0)[1] |gmtime_r(GLIBC_2.0)[1] |snprintf(GLIBC_2.0)[1] | 17641 |--------------------------+--------------------------+-----------------------| 17642 |__lxstat64(GLIBC_2.2)[1] |grantpt(GLIBC_2.2)[1] |socket(GLIBC_2.2)[1] | 17643 |--------------------------+--------------------------+-----------------------| 17644 |__mempcpy(GLIBC_2.0)[1] |hcreate(GLIBC_2.0)[1] |socketpair(GLIBC_2.0) | 17645 | | |[1] | 17646 |--------------------------+--------------------------+-----------------------| 17647 |__rawmemchr(GLIBC_2.1)[1] |hdestroy(GLIBC_2.1)[1] |sprintf(GLIBC_2.1)[1] | 17648 |--------------------------+--------------------------+-----------------------| 17649 |__register_atfork[1] |hsearch()[1] |srand()[1] | 17650 |--------------------------+--------------------------+-----------------------| 17651 |__sigsetjmp(GLIBC_2.0)[1] |htonl(GLIBC_2.0)[1] |srand48(GLIBC_2.0)[1] | 17652 |--------------------------+--------------------------+-----------------------| 17653 |__stpcpy(GLIBC_2.0)[1] |htons(GLIBC_2.0)[1] |srandom(GLIBC_2.0)[1] | 17654 |--------------------------+--------------------------+-----------------------| 17655 |__strdup(GLIBC_2.0)[1] |iconv(GLIBC_2.0)[1] |sscanf(GLIBC_2.0)[1] | 17656 |--------------------------+--------------------------+-----------------------| 17657 |__strtod_internal |iconv_close(GLIBC_2.0)[1] |statvfs(GLIBC_2.0)[1] | 17658 |(GLIBC_2.0)[1] | | | 17659 |--------------------------+--------------------------+-----------------------| 17660 |__strtof_internal |iconv_open(GLIBC_2.0)[1] |statvfs64[1] | 17661 |(GLIBC_2.0)[1] | | | 17662 |--------------------------+--------------------------+-----------------------| 17663 |__strtok_r(GLIBC_2.0)[1] |imaxabs(GLIBC_2.0)[1] |stime(GLIBC_2.0)[1] | 17664 |--------------------------+--------------------------+-----------------------| 17665 |__strtol_internal |imaxdiv(GLIBC_2.0)[1] |stpcpy(GLIBC_2.0)[1] | 17666 |(GLIBC_2.0)[1] | | | 17667 |--------------------------+--------------------------+-----------------------| 17668 |__strtold_internal |index(GLIBC_2.0)[1] |stpncpy(GLIBC_2.0)[1] | 17669 |(GLIBC_2.0)[1] | | | 17670 |--------------------------+--------------------------+-----------------------| 17671 |__strtoll_internal |inet_addr(GLIBC_2.0)[1] |strcasecmp(GLIBC_2.0) | 17672 |(GLIBC_2.0)[1] | |[1] | 17673 |--------------------------+--------------------------+-----------------------| 17674 |__strtoul_internal |inet_ntoa(GLIBC_2.0)[1] |strcasestr(GLIBC_2.0) | 17675 |(GLIBC_2.0)[1] | |[1] | 17676 |--------------------------+--------------------------+-----------------------| 17677 |__strtoull_internal |inet_ntop[1] |strcat(GLIBC_2.0)[1] | 17678 |(GLIBC_2.0)[1] | | | 17679 |--------------------------+--------------------------+-----------------------| 17680 |__sysconf(GLIBC_2.2)[1] |inet_pton[1] |strchr(GLIBC_2.2)[1] | 17681 |--------------------------+--------------------------+-----------------------| 17682 |__sysv_signal(GLIBC_2.0) |initgroups(GLIBC_2.0)[1] |strcmp(GLIBC_2.0)[1] | 17683 |[1] | | | 17684 |--------------------------+--------------------------+-----------------------| 17685 |__wcstod_internal |initstate(GLIBC_2.0)[1] |strcoll(GLIBC_2.0)[1] | 17686 |(GLIBC_2.0)[1] | | | 17687 |--------------------------+--------------------------+-----------------------| 17688 |__wcstof_internal |insque(GLIBC_2.0)[1] |strcpy(GLIBC_2.0)[1] | 17689 |(GLIBC_2.0)[1] | | | 17690 |--------------------------+--------------------------+-----------------------| 17691 |__wcstol_internal |ioctl(GLIBC_2.0)[1] |strcspn(GLIBC_2.0)[1] | 17692 |(GLIBC_2.0)[1] | | | 17693 |--------------------------+--------------------------+-----------------------| 17694 |__wcstold_internal |isalnum(GLIBC_2.0)[1] |strdup(GLIBC_2.0)[1] | 17695 |(GLIBC_2.0)[1] | | | 17696 |--------------------------+--------------------------+-----------------------| 17697 |__wcstoul_internal |isalpha(GLIBC_2.0)[1] |strerror(GLIBC_2.0)[1] | 17698 |(GLIBC_2.0)[1] | | | 17699 |--------------------------+--------------------------+-----------------------| 17700 |__xmknod(GLIBC_2.0)[1] |isascii(GLIBC_2.0)[1] |strerror_r(GLIBC_2.0) | 17701 | | |[1] | 17702 |--------------------------+--------------------------+-----------------------| 17703 |__xstat(GLIBC_2.0)[1] |isatty(GLIBC_2.0)[1] |strfmon(GLIBC_2.0)[1] | 17704 |--------------------------+--------------------------+-----------------------| 17705 |__xstat64(GLIBC_2.2)[1] |isblank(GLIBC_2.2)[1] |strfry(GLIBC_2.2)[1] | 17706 |--------------------------+--------------------------+-----------------------| 17707 |_exit(GLIBC_2.0)[1] |iscntrl(GLIBC_2.0)[1] |strftime(GLIBC_2.0)[1] | 17708 |--------------------------+--------------------------+-----------------------| 17709 |_longjmp(GLIBC_2.0)[1] |isdigit(GLIBC_2.0)[1] |strlen(GLIBC_2.0)[1] | 17710 |--------------------------+--------------------------+-----------------------| 17711 |_obstack_begin(GLIBC_2.0) |isgraph(GLIBC_2.0)[1] |strncasecmp(GLIBC_2.0) | 17712 |[1] | |[1] | 17713 |--------------------------+--------------------------+-----------------------| 17714 |_obstack_newchunk |islower(GLIBC_2.0)[1] |strncat(GLIBC_2.0)[1] | 17715 |(GLIBC_2.0)[1] | | | 17716 |--------------------------+--------------------------+-----------------------| 17717 |_setjmp(GLIBC_2.0)[1] |isprint(GLIBC_2.0)[1] |strncmp(GLIBC_2.0)[1] | 17718 |--------------------------+--------------------------+-----------------------| 17719 |_tolower(GLIBC_2.0)[1] |ispunct(GLIBC_2.0)[1] |strncpy(GLIBC_2.0)[1] | 17720 |--------------------------+--------------------------+-----------------------| 17721 |_toupper(GLIBC_2.0)[1] |isspace(GLIBC_2.0)[1] |strndup(GLIBC_2.0)[1] | 17722 |--------------------------+--------------------------+-----------------------| 17723 |a64l(GLIBC_2.0)[1] |isupper(GLIBC_2.0)[1] |strnlen(GLIBC_2.0)[1] | 17724 |--------------------------+--------------------------+-----------------------| 17725 |abort(GLIBC_2.0)[1] |iswalnum(GLIBC_2.0)[1] |strpbrk(GLIBC_2.0)[1] | 17726 |--------------------------+--------------------------+-----------------------| 17727 |abs(GLIBC_2.0)[1] |iswalpha(GLIBC_2.0)[1] |strptime(GLIBC_2.0)[1] | 17728 |--------------------------+--------------------------+-----------------------| 17729 |accept(GLIBC_2.0)[1] |iswblank(GLIBC_2.0)[1] |strrchr(GLIBC_2.0)[1] | 17730 |--------------------------+--------------------------+-----------------------| 17731 |access(GLIBC_2.0)[1] |iswcntrl(GLIBC_2.0)[1] |strsep(GLIBC_2.0)[1] | 17732 |--------------------------+--------------------------+-----------------------| 17733 |acct(GLIBC_2.0)[1] |iswctype(GLIBC_2.0)[1] |strsignal(GLIBC_2.0)[1]| 17734 |--------------------------+--------------------------+-----------------------| 17735 |adjtime(GLIBC_2.0)[1] |iswdigit(GLIBC_2.0)[1] |strspn(GLIBC_2.0)[1] | 17736 |--------------------------+--------------------------+-----------------------| 17737 |alarm(GLIBC_2.0)[1] |iswgraph(GLIBC_2.0)[1] |strstr(GLIBC_2.0)[1] | 17738 |--------------------------+--------------------------+-----------------------| 17739 |asctime(GLIBC_2.0)[1] |iswlower(GLIBC_2.0)[1] |strtod(GLIBC_2.0)[1] | 17740 |--------------------------+--------------------------+-----------------------| 17741 |asctime_r(GLIBC_2.0)[1] |iswprint(GLIBC_2.0)[1] |strtof(GLIBC_2.0)[1] | 17742 |--------------------------+--------------------------+-----------------------| 17743 |asprintf(GLIBC_2.0)[1] |iswpunct(GLIBC_2.0)[1] |strtoimax(GLIBC_2.0)[1]| 17744 |--------------------------+--------------------------+-----------------------| 17745 |atof(GLIBC_2.0)[1] |iswspace(GLIBC_2.0)[1] |strtok(GLIBC_2.0)[1] | 17746 |--------------------------+--------------------------+-----------------------| 17747 |atoi(GLIBC_2.0)[1] |iswupper(GLIBC_2.0)[1] |strtok_r(GLIBC_2.0)[1] | 17748 |--------------------------+--------------------------+-----------------------| 17749 |atol(GLIBC_2.0)[1] |iswxdigit(GLIBC_2.0)[1] |strtol(GLIBC_2.0)[1] | 17750 |--------------------------+--------------------------+-----------------------| 17751 |atoll[1] |isxdigit()[1] |strtold()[1] | 17752 |--------------------------+--------------------------+-----------------------| 17753 |authnone_create(GLIBC_2.0)|jrand48(GLIBC_2.0)[1] |strtoll(GLIBC_2.0)[1] | 17754 |[1] | | | 17755 |--------------------------+--------------------------+-----------------------| 17756 |basename(GLIBC_2.0)[1] |key_decryptsession |strtoq(GLIBC_2.0)[1] | 17757 | |(GLIBC_2.0)[1] | | 17758 |--------------------------+--------------------------+-----------------------| 17759 |bcmp(GLIBC_2.0)[1] |kill(GLIBC_2.0)[1] |strtoul(GLIBC_2.0)[1] | 17760 |--------------------------+--------------------------+-----------------------| 17761 |bcopy(GLIBC_2.0)[1] |killpg(GLIBC_2.0)[1] |strtoull(GLIBC_2.0)[1] | 17762 |--------------------------+--------------------------+-----------------------| 17763 |bind(GLIBC_2.0)[1] |l64a(GLIBC_2.0)[1] |strtoumax(GLIBC_2.0)[1]| 17764 |--------------------------+--------------------------+-----------------------| 17765 |bind_textdomain_codeset[1]|labs()[1] |strtouq()[1] | 17766 |--------------------------+--------------------------+-----------------------| 17767 |bindresvport(GLIBC_2.0)[1]|lchown(GLIBC_2.0)[1] |strverscmp(GLIBC_2.0) | 17768 | | |[1] | 17769 |--------------------------+--------------------------+-----------------------| 17770 |bindtextdomain(GLIBC_2.0) |lcong48(GLIBC_2.0)[1] |strxfrm(GLIBC_2.0)[1] | 17771 |[1] | | | 17772 |--------------------------+--------------------------+-----------------------| 17773 |brk(GLIBC_2.0)[1] |ldiv(GLIBC_2.0)[1] |svc_getreqset | 17774 | | |(GLIBC_2.0)[1] | 17775 |--------------------------+--------------------------+-----------------------| 17776 |bsd_signal(GLIBC_2.0)[1] |lfind(GLIBC_2.0)[1] |svc_register(GLIBC_2.0)| 17777 | | |[1] | 17778 |--------------------------+--------------------------+-----------------------| 17779 |bsearch(GLIBC_2.0)[1] |link(GLIBC_2.0)[1] |svc_run(GLIBC_2.0)[1] | 17780 |--------------------------+--------------------------+-----------------------| 17781 |btowc(GLIBC_2.0)[1] |listen(GLIBC_2.0)[1] |svc_sendreply | 17782 | | |(GLIBC_2.0)[1] | 17783 |--------------------------+--------------------------+-----------------------| 17784 |bzero(GLIBC_2.0)[1] |llabs(GLIBC_2.0)[1] |svcerr_auth(GLIBC_2.0) | 17785 | | |[1] | 17786 |--------------------------+--------------------------+-----------------------| 17787 |calloc(GLIBC_2.0)[1] |lldiv(GLIBC_2.0)[1] |svcerr_decode | 17788 | | |(GLIBC_2.0)[1] | 17789 |--------------------------+--------------------------+-----------------------| 17790 |catclose(GLIBC_2.0)[1] |localeconv(GLIBC_2.0)[1] |svcerr_noproc | 17791 | | |(GLIBC_2.0)[1] | 17792 |--------------------------+--------------------------+-----------------------| 17793 |catgets(GLIBC_2.0)[1] |localtime(GLIBC_2.0)[1] |svcerr_noprog | 17794 | | |(GLIBC_2.0)[1] | 17795 |--------------------------+--------------------------+-----------------------| 17796 |catopen(GLIBC_2.0)[1] |localtime_r(GLIBC_2.0)[1] |svcerr_progvers | 17797 | | |(GLIBC_2.0)[1] | 17798 |--------------------------+--------------------------+-----------------------| 17799 |cfgetispeed(GLIBC_2.0)[1] |lockf(GLIBC_2.0)[1] |svcerr_systemerr | 17800 | | |(GLIBC_2.0)[1] | 17801 |--------------------------+--------------------------+-----------------------| 17802 |cfgetospeed(GLIBC_2.0)[1] |lockf64(GLIBC_2.0)[1] |svcerr_weakauth | 17803 | | |(GLIBC_2.0)[1] | 17804 |--------------------------+--------------------------+-----------------------| 17805 |cfmakeraw(GLIBC_2.0)[1] |longjmp(GLIBC_2.0)[1] |svctcp_create | 17806 | | |(GLIBC_2.0)[1] | 17807 |--------------------------+--------------------------+-----------------------| 17808 |cfsetispeed(GLIBC_2.0)[1] |lrand48(GLIBC_2.0)[1] |svcudp_create | 17809 | | |(GLIBC_2.0)[1] | 17810 |--------------------------+--------------------------+-----------------------| 17811 |cfsetospeed(GLIBC_2.0)[1] |lsearch(GLIBC_2.0)[1] |swab(GLIBC_2.0)[1] | 17812 |--------------------------+--------------------------+-----------------------| 17813 |cfsetspeed(GLIBC_2.0)[1] |lseek(GLIBC_2.0)[1] |swapcontext(GLIBC_2.0) | 17814 | | |[1] | 17815 |--------------------------+--------------------------+-----------------------| 17816 |chdir(GLIBC_2.0)[1] |lseek64(GLIBC_2.0)[1] |swprintf(GLIBC_2.0)[1] | 17817 |--------------------------+--------------------------+-----------------------| 17818 |chmod(GLIBC_2.0)[1] |makecontext(GLIBC_2.0)[1] |swscanf(GLIBC_2.0)[1] | 17819 |--------------------------+--------------------------+-----------------------| 17820 |chown(GLIBC_2.1)[1] |malloc(GLIBC_2.1)[1] |symlink(GLIBC_2.1)[1] | 17821 |--------------------------+--------------------------+-----------------------| 17822 |chroot(GLIBC_2.0)[1] |mblen(GLIBC_2.0)[1] |sync(GLIBC_2.0)[1] | 17823 |--------------------------+--------------------------+-----------------------| 17824 |clearerr(GLIBC_2.0)[1] |mbrlen(GLIBC_2.0)[1] |sysconf(GLIBC_2.0)[1] | 17825 |--------------------------+--------------------------+-----------------------| 17826 |clnt_create(GLIBC_2.0)[1] |mbrtowc(GLIBC_2.0)[1] |syslog(GLIBC_2.0)[1] | 17827 |--------------------------+--------------------------+-----------------------| 17828 |clnt_pcreateerror |mbsinit(GLIBC_2.0)[1] |system(GLIBC_2.0)[1] | 17829 |(GLIBC_2.0)[1] | | | 17830 |--------------------------+--------------------------+-----------------------| 17831 |clnt_perrno(GLIBC_2.0)[1] |mbsnrtowcs(GLIBC_2.0)[1] |tcdrain(GLIBC_2.0)[1] | 17832 |--------------------------+--------------------------+-----------------------| 17833 |clnt_perror(GLIBC_2.0)[1] |mbsrtowcs(GLIBC_2.0)[1] |tcflow(GLIBC_2.0)[1] | 17834 |--------------------------+--------------------------+-----------------------| 17835 |clnt_spcreateerror |mbstowcs(GLIBC_2.0)[1] |tcflush(GLIBC_2.0)[1] | 17836 |(GLIBC_2.0)[1] | | | 17837 |--------------------------+--------------------------+-----------------------| 17838 |clnt_sperrno(GLIBC_2.0)[1]|mbtowc(GLIBC_2.0)[1] |tcgetattr(GLIBC_2.0)[1]| 17839 |--------------------------+--------------------------+-----------------------| 17840 |clnt_sperror(GLIBC_2.0)[1]|memccpy(GLIBC_2.0)[1] |tcgetpgrp(GLIBC_2.0)[1]| 17841 |--------------------------+--------------------------+-----------------------| 17842 |clock(GLIBC_2.0)[1] |memchr(GLIBC_2.0)[1] |tcgetsid(GLIBC_2.0)[1] | 17843 |--------------------------+--------------------------+-----------------------| 17844 |close(GLIBC_2.0)[1] |memcmp(GLIBC_2.0)[1] |tcsendbreak(GLIBC_2.0) | 17845 | | |[1] | 17846 |--------------------------+--------------------------+-----------------------| 17847 |closedir(GLIBC_2.0)[1] |memcpy(GLIBC_2.0)[1] |tcsetattr(GLIBC_2.0)[1]| 17848 |--------------------------+--------------------------+-----------------------| 17849 |closelog(GLIBC_2.0)[1] |memmem(GLIBC_2.0)[1] |tcsetpgrp(GLIBC_2.0)[1]| 17850 |--------------------------+--------------------------+-----------------------| 17851 |confstr(GLIBC_2.0)[1] |memmove(GLIBC_2.0)[1] |tdelete[1] | 17852 |--------------------------+--------------------------+-----------------------| 17853 |connect(GLIBC_2.0)[1] |memrchr(GLIBC_2.0)[1] |telldir(GLIBC_2.0)[1] | 17854 |--------------------------+--------------------------+-----------------------| 17855 |creat(GLIBC_2.0)[1] |memset(GLIBC_2.0)[1] |tempnam(GLIBC_2.0)[1] | 17856 |--------------------------+--------------------------+-----------------------| 17857 |creat64(GLIBC_2.1)[1] |mkdir(GLIBC_2.1)[1] |textdomain(GLIBC_2.1) | 17858 | | |[1] | 17859 |--------------------------+--------------------------+-----------------------| 17860 |ctermid(GLIBC_2.0)[1] |mkfifo(GLIBC_2.0)[1] |tfind(GLIBC_2.0)[1] | 17861 |--------------------------+--------------------------+-----------------------| 17862 |ctime(GLIBC_2.0)[1] |mkstemp(GLIBC_2.0)[1] |time(GLIBC_2.0)[1] | 17863 |--------------------------+--------------------------+-----------------------| 17864 |ctime_r(GLIBC_2.0)[1] |mkstemp64(GLIBC_2.0)[1] |times(GLIBC_2.0)[1] | 17865 |--------------------------+--------------------------+-----------------------| 17866 |cuserid(GLIBC_2.0)[1] |mktemp(GLIBC_2.0)[1] |tmpfile(GLIBC_2.0)[1] | 17867 |--------------------------+--------------------------+-----------------------| 17868 |daemon(GLIBC_2.0)[1] |mktime(GLIBC_2.0)[1] |tmpfile64(GLIBC_2.0)[1]| 17869 |--------------------------+--------------------------+-----------------------| 17870 |dcgettext(GLIBC_2.0)[1] |mlock(GLIBC_2.0)[1] |tmpnam(GLIBC_2.0)[1] | 17871 |--------------------------+--------------------------+-----------------------| 17872 |dcngettext[1] |mlockall()[1] |toascii()[1] | 17873 |--------------------------+--------------------------+-----------------------| 17874 |dgettext[1] |mmap()[1] |tolower()[1] | 17875 |--------------------------+--------------------------+-----------------------| 17876 |difftime(GLIBC_2.0)[1] |mmap64(GLIBC_2.0)[1] |toupper(GLIBC_2.0)[1] | 17877 |--------------------------+--------------------------+-----------------------| 17878 |dirname(GLIBC_2.0)[1] |mprotect(GLIBC_2.0)[1] |towctrans(GLIBC_2.0)[1]| 17879 |--------------------------+--------------------------+-----------------------| 17880 |div(GLIBC_2.0)[1] |mrand48(GLIBC_2.0)[1] |towlower(GLIBC_2.0)[1] | 17881 |--------------------------+--------------------------+-----------------------| 17882 |dngettext[1] |msgctl()[1] |towupper()[1] | 17883 |--------------------------+--------------------------+-----------------------| 17884 |drand48(GLIBC_2.0)[1] |msgget(GLIBC_2.0)[1] |truncate(GLIBC_2.0)[1] | 17885 |--------------------------+--------------------------+-----------------------| 17886 |dup(GLIBC_2.0)[1] |msgrcv(GLIBC_2.0)[1] |truncate64(GLIBC_2.0) | 17887 | | |[1] | 17888 |--------------------------+--------------------------+-----------------------| 17889 |dup2(GLIBC_2.0)[1] |msgsnd(GLIBC_2.0)[1] |tsearch(GLIBC_2.0)[1] | 17890 |--------------------------+--------------------------+-----------------------| 17891 |ecvt(GLIBC_2.0)[1] |msync(GLIBC_2.0)[1] |ttyname(GLIBC_2.0)[1] | 17892 |--------------------------+--------------------------+-----------------------| 17893 |endgrent(GLIBC_2.0)[1] |munlock(GLIBC_2.0)[1] |ttyname_r(GLIBC_2.0)[1]| 17894 |--------------------------+--------------------------+-----------------------| 17895 |endnetent(GLIBC_2.0)[1] |munlockall(GLIBC_2.0)[1] |twalk(GLIBC_2.0)[1] | 17896 |--------------------------+--------------------------+-----------------------| 17897 |endprotoent(GLIBC_2.0)[1] |munmap(GLIBC_2.0)[1] |tzset(GLIBC_2.0)[1] | 17898 |--------------------------+--------------------------+-----------------------| 17899 |endpwent(GLIBC_2.0)[1] |nanosleep(GLIBC_2.0)[1] |ualarm(GLIBC_2.0)[1] | 17900 |--------------------------+--------------------------+-----------------------| 17901 |endservent(GLIBC_2.0)[1] |nftw(GLIBC_2.0)[1] |ulimit(GLIBC_2.0)[1] | 17902 |--------------------------+--------------------------+-----------------------| 17903 |endutent(GLIBC_2.0)[1] |nftw64(GLIBC_2.0)[1] |umask(GLIBC_2.0)[1] | 17904 |--------------------------+--------------------------+-----------------------| 17905 |endutxent(GLIBC_2.1)[1] |ngettext[1] |uname(GLIBC_2.1)[1] | 17906 |--------------------------+--------------------------+-----------------------| 17907 |erand48(GLIBC_2.0)[1] |nice(GLIBC_2.0)[1] |ungetc(GLIBC_2.0)[1] | 17908 |--------------------------+--------------------------+-----------------------| 17909 |err(GLIBC_2.0)[1] |nl_langinfo(GLIBC_2.0)[1] |ungetwc(GLIBC_2.0)[1] | 17910 |--------------------------+--------------------------+-----------------------| 17911 |error(GLIBC_2.0)[1] |nrand48(GLIBC_2.0)[1] |unlink(GLIBC_2.0)[1] | 17912 |--------------------------+--------------------------+-----------------------| 17913 |errx(GLIBC_2.0)[1] |ntohl(GLIBC_2.0)[1] |unlockpt(GLIBC_2.0)[1] | 17914 |--------------------------+--------------------------+-----------------------| 17915 |execl(GLIBC_2.0)[1] |ntohs(GLIBC_2.0)[1] |unsetenv[1] | 17916 |--------------------------+--------------------------+-----------------------| 17917 |execle(GLIBC_2.0)[1] |obstack_free(GLIBC_2.0)[1]|usleep(GLIBC_2.0)[1] | 17918 |--------------------------+--------------------------+-----------------------| 17919 |execlp(GLIBC_2.0)[1] |open(GLIBC_2.0)[1] |utime(GLIBC_2.0)[1] | 17920 |--------------------------+--------------------------+-----------------------| 17921 |execv(GLIBC_2.0)[1] |open64(GLIBC_2.0)[1] |utimes(GLIBC_2.0)[1] | 17922 |--------------------------+--------------------------+-----------------------| 17923 |execve(GLIBC_2.0)[1] |opendir(GLIBC_2.0)[1] |vasprintf(GLIBC_2.0)[1]| 17924 |--------------------------+--------------------------+-----------------------| 17925 |execvp(GLIBC_2.0)[1] |openlog(GLIBC_2.0)[1] |vdprintf(GLIBC_2.0)[1] | 17926 |--------------------------+--------------------------+-----------------------| 17927 |exit(GLIBC_2.0)[1] |pathconf(GLIBC_2.0)[1] |verrx(GLIBC_2.0)[1] | 17928 |--------------------------+--------------------------+-----------------------| 17929 |fchdir(GLIBC_2.0)[1] |pause(GLIBC_2.0)[1] |vfork(GLIBC_2.0)[1] | 17930 |--------------------------+--------------------------+-----------------------| 17931 |fchmod(GLIBC_2.0)[1] |pclose(GLIBC_2.0)[1] |vfprintf(GLIBC_2.0)[1] | 17932 |--------------------------+--------------------------+-----------------------| 17933 |fchown(GLIBC_2.0)[1] |perror(GLIBC_2.0)[1] |vfscanf[1] | 17934 |--------------------------+--------------------------+-----------------------| 17935 |fclose(GLIBC_2.1)[1] |pipe(GLIBC_2.1)[1] |vfwprintf(GLIBC_2.1)[1]| 17936 |--------------------------+--------------------------+-----------------------| 17937 |fcntl(GLIBC_2.0)[1] |pmap_getport(GLIBC_2.0)[1]|vfwscanf(GLIBC_2.0)[1] | 17938 |--------------------------+--------------------------+-----------------------| 17939 |fcvt(GLIBC_2.0)[1] |pmap_set(GLIBC_2.0)[1] |vprintf(GLIBC_2.0)[1] | 17940 |--------------------------+--------------------------+-----------------------| 17941 |fdatasync(GLIBC_2.0)[1] |pmap_unset(GLIBC_2.0)[1] |vscanf[1] | 17942 |--------------------------+--------------------------+-----------------------| 17943 |fdopen(GLIBC_2.1)[1] |poll(GLIBC_2.1)[1] |vsnprintf(GLIBC_2.1)[1]| 17944 |--------------------------+--------------------------+-----------------------| 17945 |feof(GLIBC_2.0)[1] |popen(GLIBC_2.0)[1] |vsprintf(GLIBC_2.0)[1] | 17946 |--------------------------+--------------------------+-----------------------| 17947 |ferror(GLIBC_2.0)[1] |posix_memalign(GLIBC_2.0) |vsscanf[1] | 17948 | |[1] | | 17949 |--------------------------+--------------------------+-----------------------| 17950 |fflush(GLIBC_2.0)[1] |printf(GLIBC_2.0)[1] |vswprintf(GLIBC_2.0)[1]| 17951 |--------------------------+--------------------------+-----------------------| 17952 |fflush_unlocked(GLIBC_2.0)|psignal(GLIBC_2.0)[1] |vswscanf(GLIBC_2.0)[1] | 17953 |[1] | | | 17954 |--------------------------+--------------------------+-----------------------| 17955 |ffs(GLIBC_2.0)[1] |ptsname(GLIBC_2.0)[1] |vsyslog[1] | 17956 |--------------------------+--------------------------+-----------------------| 17957 |fgetc(GLIBC_2.0)[1] |putc(GLIBC_2.0)[1] |vwprintf(GLIBC_2.0)[1] | 17958 |--------------------------+--------------------------+-----------------------| 17959 |fgetpos(GLIBC_2.0)[1] |putc_unlocked(GLIBC_2.0) |vwscanf(GLIBC_2.0)[1] | 17960 | |[1] | | 17961 |--------------------------+--------------------------+-----------------------| 17962 |fgetpos64(GLIBC_2.1)[1] |putchar(GLIBC_2.1)[1] |wait(GLIBC_2.1)[1] | 17963 |--------------------------+--------------------------+-----------------------| 17964 |fgets(GLIBC_2.0)[1] |putchar_unlocked |wait3(GLIBC_2.0)[1] | 17965 | |(GLIBC_2.0)[1] | | 17966 |--------------------------+--------------------------+-----------------------| 17967 |fgetwc(GLIBC_2.2)[1] |putenv(GLIBC_2.2)[1] |wait4(GLIBC_2.2)[1] | 17968 |--------------------------+--------------------------+-----------------------| 17969 |fgetwc_unlocked(GLIBC_2.2)|puts(GLIBC_2.2)[1] |waitpid(GLIBC_2.2)[1] | 17970 |[1] | | | 17971 |--------------------------+--------------------------+-----------------------| 17972 |fgetws(GLIBC_2.2)[1] |pututxline(GLIBC_2.2)[1] |warn(GLIBC_2.2)[1] | 17973 |--------------------------+--------------------------+-----------------------| 17974 |fileno(GLIBC_2.0)[1] |putw(GLIBC_2.0)[1] |warnx(GLIBC_2.0)[1] | 17975 |--------------------------+--------------------------+-----------------------| 17976 |flock(GLIBC_2.0)[1] |putwc(GLIBC_2.0)[1] |wcpcpy(GLIBC_2.0)[1] | 17977 |--------------------------+--------------------------+-----------------------| 17978 |flockfile(GLIBC_2.0)[1] |putwchar(GLIBC_2.0)[1] |wcpncpy(GLIBC_2.0)[1] | 17979 |--------------------------+--------------------------+-----------------------| 17980 |fmtmsg(GLIBC_2.1)[1] |qsort(GLIBC_2.1)[1] |wcrtomb(GLIBC_2.1)[1] | 17981 |--------------------------+--------------------------+-----------------------| 17982 |fnmatch(GLIBC_2.2.3)[1] |raise(GLIBC_2.2.3)[1] |wcscasecmp(GLIBC_2.2.3)| 17983 | | |[1] | 17984 |--------------------------+--------------------------+-----------------------| 17985 |fopen(GLIBC_2.1)[1] |rand(GLIBC_2.1)[1] |wcscat(GLIBC_2.1)[1] | 17986 |--------------------------+--------------------------+-----------------------| 17987 |fopen64(GLIBC_2.1)[1] |rand_r(GLIBC_2.1)[1] |wcschr(GLIBC_2.1)[1] | 17988 |--------------------------+--------------------------+-----------------------| 17989 |fork(GLIBC_2.0)[1] |random(GLIBC_2.0)[1] |wcscmp(GLIBC_2.0)[1] | 17990 |--------------------------+--------------------------+-----------------------| 17991 |fpathconf(GLIBC_2.0)[1] |random_r(GLIBC_2.0)[1] |wcscoll(GLIBC_2.0)[1] | 17992 |--------------------------+--------------------------+-----------------------| 17993 |fprintf(GLIBC_2.0)[1] |read(GLIBC_2.0)[1] |wcscpy(GLIBC_2.0)[1] | 17994 |--------------------------+--------------------------+-----------------------| 17995 |fputc(GLIBC_2.0)[1] |readdir(GLIBC_2.0)[1] |wcscspn(GLIBC_2.0)[1] | 17996 |--------------------------+--------------------------+-----------------------| 17997 |fputs(GLIBC_2.0)[1] |readdir64(GLIBC_2.0)[1] |wcsdup(GLIBC_2.0)[1] | 17998 |--------------------------+--------------------------+-----------------------| 17999 |fputwc(GLIBC_2.2)[1] |readdir_r[1] |wcsftime(GLIBC_2.2)[1] | 18000 |--------------------------+--------------------------+-----------------------| 18001 |fputws(GLIBC_2.2)[1] |readlink(GLIBC_2.2)[1] |wcslen(GLIBC_2.2)[1] | 18002 |--------------------------+--------------------------+-----------------------| 18003 |fread(GLIBC_2.0)[1] |readv(GLIBC_2.0)[1] |wcsncasecmp(GLIBC_2.0) | 18004 | | |[1] | 18005 |--------------------------+--------------------------+-----------------------| 18006 |free(GLIBC_2.0)[1] |realloc(GLIBC_2.0)[1] |wcsncat(GLIBC_2.0)[1] | 18007 |--------------------------+--------------------------+-----------------------| 18008 |freeaddrinfo[1] |realpath()[1] |wcsncmp()[1] | 18009 |--------------------------+--------------------------+-----------------------| 18010 |freopen(GLIBC_2.0)[1] |recv(GLIBC_2.0)[1] |wcsncpy(GLIBC_2.0)[1] | 18011 |--------------------------+--------------------------+-----------------------| 18012 |freopen64(GLIBC_2.1)[1] |recvfrom(GLIBC_2.1)[1] |wcsnlen(GLIBC_2.1)[1] | 18013 |--------------------------+--------------------------+-----------------------| 18014 |fscanf(GLIBC_2.0)[1] |recvmsg(GLIBC_2.0)[1] |wcsnrtombs(GLIBC_2.0) | 18015 | | |[1] | 18016 |--------------------------+--------------------------+-----------------------| 18017 |fseek(GLIBC_2.0)[1] |regcomp(GLIBC_2.0)[1] |wcspbrk(GLIBC_2.0)[1] | 18018 |--------------------------+--------------------------+-----------------------| 18019 |fseeko(GLIBC_2.1)[1] |regerror(GLIBC_2.1)[1] |wcsrchr(GLIBC_2.1)[1] | 18020 |--------------------------+--------------------------+-----------------------| 18021 |fseeko64(GLIBC_2.1)[1] |regexec(GLIBC_2.1)[1] |wcsrtombs(GLIBC_2.1)[1]| 18022 |--------------------------+--------------------------+-----------------------| 18023 |fsetpos(GLIBC_2.0)[1] |regfree(GLIBC_2.0)[1] |wcsspn(GLIBC_2.0)[1] | 18024 |--------------------------+--------------------------+-----------------------| 18025 |fsetpos64(GLIBC_2.1)[1] |remove(GLIBC_2.1)[1] |wcsstr(GLIBC_2.1)[1] | 18026 |--------------------------+--------------------------+-----------------------| 18027 |fstatvfs(GLIBC_2.1)[1] |remque(GLIBC_2.1)[1] |wcstod(GLIBC_2.1)[1] | 18028 |--------------------------+--------------------------+-----------------------| 18029 |fstatvfs64(GLIBC_2.1)[1] |rename(GLIBC_2.1)[1] |wcstof(GLIBC_2.1)[1] | 18030 |--------------------------+--------------------------+-----------------------| 18031 |fsync(GLIBC_2.0)[1] |rewind(GLIBC_2.0)[1] |wcstoimax(GLIBC_2.0)[1]| 18032 |--------------------------+--------------------------+-----------------------| 18033 |ftell(GLIBC_2.0)[1] |rewinddir(GLIBC_2.0)[1] |wcstok(GLIBC_2.0)[1] | 18034 |--------------------------+--------------------------+-----------------------| 18035 |ftello(GLIBC_2.1)[1] |rindex(GLIBC_2.1)[1] |wcstol(GLIBC_2.1)[1] | 18036 |--------------------------+--------------------------+-----------------------| 18037 |ftello64(GLIBC_2.1)[1] |rmdir(GLIBC_2.1)[1] |wcstold(GLIBC_2.1)[1] | 18038 |--------------------------+--------------------------+-----------------------| 18039 |ftime(GLIBC_2.0)[1] |sbrk(GLIBC_2.0)[1] |wcstoll(GLIBC_2.0)[1] | 18040 |--------------------------+--------------------------+-----------------------| 18041 |ftok(GLIBC_2.0)[1] |scanf(GLIBC_2.0)[1] |wcstombs(GLIBC_2.0)[1] | 18042 |--------------------------+--------------------------+-----------------------| 18043 |ftruncate(GLIBC_2.0)[1] |sched_get_priority_max |wcstoq(GLIBC_2.0)[1] | 18044 | |(GLIBC_2.0)[1] | | 18045 |--------------------------+--------------------------+-----------------------| 18046 |ftruncate64(GLIBC_2.1)[1] |sched_get_priority_min |wcstoul(GLIBC_2.1)[1] | 18047 | |(GLIBC_2.1)[1] | | 18048 |--------------------------+--------------------------+-----------------------| 18049 |ftrylockfile(GLIBC_2.0)[1]|sched_getparam(GLIBC_2.0) |wcstoull(GLIBC_2.0)[1] | 18050 | |[1] | | 18051 |--------------------------+--------------------------+-----------------------| 18052 |ftw(GLIBC_2.0)[1] |sched_getscheduler |wcstoumax(GLIBC_2.0)[1]| 18053 | |(GLIBC_2.0)[1] | | 18054 |--------------------------+--------------------------+-----------------------| 18055 |ftw64(GLIBC_2.1)[1] |sched_rr_get_interval |wcstouq(GLIBC_2.1)[1] | 18056 | |(GLIBC_2.1)[1] | | 18057 |--------------------------+--------------------------+-----------------------| 18058 |funlockfile(GLIBC_2.0)[1] |sched_setparam(GLIBC_2.0) |wcswcs(GLIBC_2.0)[1] | 18059 | |[1] | | 18060 |--------------------------+--------------------------+-----------------------| 18061 |fwide(GLIBC_2.2)[1] |sched_setscheduler |wcswidth(GLIBC_2.2)[1] | 18062 | |(GLIBC_2.2)[1] | | 18063 |--------------------------+--------------------------+-----------------------| 18064 |fwprintf(GLIBC_2.2)[1] |sched_yield(GLIBC_2.2)[1] |wcsxfrm(GLIBC_2.2)[1] | 18065 |--------------------------+--------------------------+-----------------------| 18066 |fwrite(GLIBC_2.0)[1] |seed48(GLIBC_2.0)[1] |wctob(GLIBC_2.0)[1] | 18067 |--------------------------+--------------------------+-----------------------| 18068 |fwscanf(GLIBC_2.2)[1] |seekdir(GLIBC_2.2)[1] |wctomb(GLIBC_2.2)[1] | 18069 |--------------------------+--------------------------+-----------------------| 18070 |gai_strerror[1] |select()[1] |wctrans()[1] | 18071 |--------------------------+--------------------------+-----------------------| 18072 |gcvt(GLIBC_2.0)[1] |semctl(GLIBC_2.0)[1] |wctype(GLIBC_2.0)[1] | 18073 |--------------------------+--------------------------+-----------------------| 18074 |getaddrinfo[1] |semget()[1] |wcwidth()[1] | 18075 |--------------------------+--------------------------+-----------------------| 18076 |getc(GLIBC_2.0)[1] |semop(GLIBC_2.0)[1] |wmemchr(GLIBC_2.0)[1] | 18077 |--------------------------+--------------------------+-----------------------| 18078 |getc_unlocked(GLIBC_2.0) |send(GLIBC_2.0)[1] |wmemcmp(GLIBC_2.0)[1] | 18079 |[1] | | | 18080 |--------------------------+--------------------------+-----------------------| 18081 |getchar(GLIBC_2.0)[1] |sendmsg(GLIBC_2.0)[1] |wmemcpy(GLIBC_2.0)[1] | 18082 |--------------------------+--------------------------+-----------------------| 18083 |getchar_unlocked |sendto(GLIBC_2.0)[1] |wmemmove(GLIBC_2.0)[1] | 18084 |(GLIBC_2.0)[1] | | | 18085 |--------------------------+--------------------------+-----------------------| 18086 |getcontext(GLIBC_2.1)[1] |setbuf(GLIBC_2.1)[1] |wmemset(GLIBC_2.1)[1] | 18087 |--------------------------+--------------------------+-----------------------| 18088 |getcwd(GLIBC_2.0)[1] |setbuffer(GLIBC_2.0)[1] |wordexp(GLIBC_2.0)[1] | 18089 |--------------------------+--------------------------+-----------------------| 18090 |getdate(GLIBC_2.1)[1] |setcontext(GLIBC_2.1)[1] |wordfree(GLIBC_2.1)[1] | 18091 |--------------------------+--------------------------+-----------------------| 18092 |getdomainname(GLIBC_2.0) |setdomainname[1] |wprintf(GLIBC_2.0)[1] | 18093 |[1] | | | 18094 |--------------------------+--------------------------+-----------------------| 18095 |getegid(GLIBC_2.0)[1] |setegid(GLIBC_2.0)[1] |write(GLIBC_2.0)[1] | 18096 |--------------------------+--------------------------+-----------------------| 18097 |getenv(GLIBC_2.0)[1] |setenv[1] |writev(GLIBC_2.0)[1] | 18098 |--------------------------+--------------------------+-----------------------| 18099 |geteuid(GLIBC_2.0)[1] |seteuid(GLIBC_2.0)[1] |wscanf(GLIBC_2.0)[1] | 18100 |--------------------------+--------------------------+-----------------------| 18101 |getgid(GLIBC_2.0)[1] |setgid(GLIBC_2.0)[1] |xdr_accepted_reply | 18102 | | |(GLIBC_2.0)[1] | 18103 |--------------------------+--------------------------+-----------------------| 18104 |getgrent(GLIBC_2.0)[1] |setgrent(GLIBC_2.0)[1] |xdr_array(GLIBC_2.0)[1]| 18105 |--------------------------+--------------------------+-----------------------| 18106 |getgrgid(GLIBC_2.0)[1] |setgroups(GLIBC_2.0)[1] |xdr_bool(GLIBC_2.0)[1] | 18107 |--------------------------+--------------------------+-----------------------| 18108 |getgrgid_r(GLIBC_2.0)[1] |sethostid(GLIBC_2.0)[1] |xdr_bytes(GLIBC_2.0)[1]| 18109 |--------------------------+--------------------------+-----------------------| 18110 |getgrnam(GLIBC_2.0)[1] |sethostname(GLIBC_2.0)[1] |xdr_callhdr(GLIBC_2.0) | 18111 | | |[1] | 18112 |--------------------------+--------------------------+-----------------------| 18113 |getgrnam_r(GLIBC_2.0)[1] |setitimer(GLIBC_2.0)[1] |xdr_callmsg(GLIBC_2.0) | 18114 | | |[1] | 18115 |--------------------------+--------------------------+-----------------------| 18116 |getgroups(GLIBC_2.0)[1] |setlocale(GLIBC_2.0)[1] |xdr_char(GLIBC_2.0)[1] | 18117 |--------------------------+--------------------------+-----------------------| 18118 |gethostbyaddr(GLIBC_2.0) |setlogmask(GLIBC_2.0)[1] |xdr_double(GLIBC_2.0) | 18119 |[1] | |[1] | 18120 |--------------------------+--------------------------+-----------------------| 18121 |gethostbyname(GLIBC_2.0) |setnetent(GLIBC_2.0)[1] |xdr_enum(GLIBC_2.0)[1] | 18122 |[1] | | | 18123 |--------------------------+--------------------------+-----------------------| 18124 |gethostid(GLIBC_2.0)[1] |setpgid(GLIBC_2.0)[1] |xdr_float(GLIBC_2.0)[1]| 18125 |--------------------------+--------------------------+-----------------------| 18126 |gethostname(GLIBC_2.0)[1] |setpgrp(GLIBC_2.0)[1] |xdr_free(GLIBC_2.0)[1] | 18127 |--------------------------+--------------------------+-----------------------| 18128 |getitimer(GLIBC_2.0)[1] |setpriority(GLIBC_2.0)[1] |xdr_int(GLIBC_2.0)[1] | 18129 |--------------------------+--------------------------+-----------------------| 18130 |getloadavg(GLIBC_2.2)[1] |setprotoent(GLIBC_2.2)[1] |xdr_long(GLIBC_2.2)[1] | 18131 |--------------------------+--------------------------+-----------------------| 18132 |getlogin(GLIBC_2.0)[1] |setpwent(GLIBC_2.0)[1] |xdr_opaque(GLIBC_2.0) | 18133 | | |[1] | 18134 |--------------------------+--------------------------+-----------------------| 18135 |getnameinfo[1] |setregid()[1] |xdr_opaque_auth()[1] | 18136 |--------------------------+--------------------------+-----------------------| 18137 |getnetbyaddr(GLIBC_2.0)[1]|setreuid(GLIBC_2.0)[1] |xdr_pointer(GLIBC_2.0) | 18138 | | |[1] | 18139 |--------------------------+--------------------------+-----------------------| 18140 |getopt(GLIBC_2.0)[1] |setrlimit(GLIBC_2.0)[1] |xdr_reference | 18141 | | |(GLIBC_2.0)[1] | 18142 |--------------------------+--------------------------+-----------------------| 18143 |getopt_long(GLIBC_2.0)[1] |setrlimit64[1] |xdr_rejected_reply | 18144 | | |(GLIBC_2.0)[1] | 18145 |--------------------------+--------------------------+-----------------------| 18146 |getopt_long_only |setservent(GLIBC_2.0)[1] |xdr_replymsg(GLIBC_2.0)| 18147 |(GLIBC_2.0)[1] | |[1] | 18148 |--------------------------+--------------------------+-----------------------| 18149 |getpagesize(GLIBC_2.0)[1] |setsid(GLIBC_2.0)[1] |xdr_short(GLIBC_2.0)[1]| 18150 |--------------------------+--------------------------+-----------------------| 18151 |getpeername(GLIBC_2.0)[1] |setsockopt(GLIBC_2.0)[1] |xdr_string(GLIBC_2.0) | 18152 | | |[1] | 18153 |--------------------------+--------------------------+-----------------------| 18154 |getpgid(GLIBC_2.0)[1] |setstate(GLIBC_2.0)[1] |xdr_u_char(GLIBC_2.0) | 18155 | | |[1] | 18156 |--------------------------+--------------------------+-----------------------| 18157 |getpgrp(GLIBC_2.0)[1] |setuid(GLIBC_2.0)[1] |xdr_u_int(GLIBC_2.0)[1]| 18158 |--------------------------+--------------------------+-----------------------| 18159 |getpid(GLIBC_2.0)[1] |setutent(GLIBC_2.0)[1] |xdr_u_long(GLIBC_2.0) | 18160 | | |[1] | 18161 |--------------------------+--------------------------+-----------------------| 18162 |getppid(GLIBC_2.0)[1] |setutxent(GLIBC_2.0)[1] |xdr_u_short(GLIBC_2.0) | 18163 | | |[1] | 18164 |--------------------------+--------------------------+-----------------------| 18165 |getpriority(GLIBC_2.0)[1] |setvbuf(GLIBC_2.0)[1] |xdr_union(GLIBC_2.0)[1]| 18166 |--------------------------+--------------------------+-----------------------| 18167 |getprotobyname(GLIBC_2.0) |shmat(GLIBC_2.0)[1] |xdr_vector(GLIBC_2.0) | 18168 |[1] | |[1] | 18169 |--------------------------+--------------------------+-----------------------| 18170 |getprotobynumber |shmctl(GLIBC_2.0)[1] |xdr_void(GLIBC_2.0)[1] | 18171 |(GLIBC_2.0)[1] | | | 18172 |--------------------------+--------------------------+-----------------------| 18173 |getprotoent(GLIBC_2.0)[1] |shmdt(GLIBC_2.0)[1] |xdr_wrapstring | 18174 | | |(GLIBC_2.0)[1] | 18175 |--------------------------+--------------------------+-----------------------| 18176 |getpwent(GLIBC_2.0)[1] |shmget(GLIBC_2.0)[1] |xdrmem_create | 18177 | | |(GLIBC_2.0)[1] | 18178 |--------------------------+--------------------------+-----------------------| 18179 |getpwnam(GLIBC_2.0)[1] |shutdown(GLIBC_2.0)[1] |xdrrec_create | 18180 | | |(GLIBC_2.0)[1] | 18181 |--------------------------+--------------------------+-----------------------| 18182 |getpwnam_r(GLIBC_2.0)[1] |sigaction(GLIBC_2.0)[1] |xdrrec_eof(GLIBC_2.0) | 18183 | | |[1] | 18184 |--------------------------+--------------------------+-----------------------| 18185 |getpwuid(GLIBC_2.0)[1] |sigaddset(GLIBC_2.0)[1] | | 18186 |--------------------------+--------------------------+-----------------------| 18187 |getpwuid_r(GLIBC_2.0)[1] |sigaltstack(GLIBC_2.0)[1] | | 18188 +-----------------------------------------------------------------------------+ 18189 18190 Table A-2. libc Data Interfaces 18191 18192 +-------------------------------------+ 18193 |__daylight |__timezone |_sys_errlist | 18194 |-----------+-----------+-------------| 18195 |__environ |__tzname | | 18196 +-------------------------------------+ 18197 ------------------------------------------------------------------------------- 18198 18199 libcrypt 18200 18201 The behaviour of the interfaces in this library is specified by the following 18202 Standards. 18203 18204 ISO POSIX (2003) 18205 18206 Table A-3. libcrypt Function Interfaces 18207 18208 +--------------------------------------------------------------+ 18209 |crypt(GLIBC_2.0)[1]|encrypt(GLIBC_2.0)[1]|setkey(GLIBC_2.0)[1]| 18210 +--------------------------------------------------------------+ 18211 ------------------------------------------------------------------------------- 18212 18213 libdl 18214 18215 The behaviour of the interfaces in this library is specified by the following 18216 Standards. 18217 18218 this specification 18219 ISO POSIX (2003) 18220 18221 Table A-4. libdl Function Interfaces 18222 18223 +---------------------------------------------------------------+ 18224 |dladdr(GLIBC_2.0)[1] |dlerror(GLIBC_2.0)[1]|dlsym(GLIBC_2.0)[1]| 18225 |---------------------+---------------------+-------------------| 18226 |dlclose(GLIBC_2.0)[1]|dlopen(GLIBC_2.0)[1] | | 18227 +---------------------------------------------------------------+ 18228 ------------------------------------------------------------------------------- 18229 18230 libm 18231 18232 The behaviour of the interfaces in this library is specified by the following 18233 Standards. 18234 18235 ISO C (1999) 18236 SUSv2 18237 ISO POSIX (2003) 18238 18239 Table A-5. libm Function Interfaces 18240 18241 +-----------------------------------------------------------------------------+ 18242 |acos(GLIBC_2.0)[1] |csinhl(GLIBC_2.0)[1] |log(GLIBC_2.0)[1] | 18243 |----------------------+----------------------------+-------------------------| 18244 |acosf(GLIBC_2.0)[1] |csinl(GLIBC_2.0)[1] |log10(GLIBC_2.0)[1] | 18245 |----------------------+----------------------------+-------------------------| 18246 |acosh(GLIBC_2.0)[1] |csqrt(GLIBC_2.0)[1] |log10f[1] | 18247 |----------------------+----------------------------+-------------------------| 18248 |acoshf(GLIBC_2.0)[1] |csqrtf(GLIBC_2.0)[1] |log10l[1] | 18249 |----------------------+----------------------------+-------------------------| 18250 |acoshl(GLIBC_2.0)[1] |csqrtl(GLIBC_2.0)[1] |log1p(GLIBC_2.0)[1] | 18251 |----------------------+----------------------------+-------------------------| 18252 |acosl(GLIBC_2.0)[1] |ctan(GLIBC_2.0)[1] |logb(GLIBC_2.0)[1] | 18253 |----------------------+----------------------------+-------------------------| 18254 |asin(GLIBC_2.0)[1] |ctanf(GLIBC_2.0)[1] |logf[1] | 18255 |----------------------+----------------------------+-------------------------| 18256 |asinf(GLIBC_2.0)[1] |ctanh(GLIBC_2.0)[1] |logl[1] | 18257 |----------------------+----------------------------+-------------------------| 18258 |asinh(GLIBC_2.0)[1] |ctanhf(GLIBC_2.0)[1] |lrint(GLIBC_2.0)[1] | 18259 |----------------------+----------------------------+-------------------------| 18260 |asinhf(GLIBC_2.0)[1] |ctanhl(GLIBC_2.0)[1] |lrintf(GLIBC_2.0)[1] | 18261 |----------------------+----------------------------+-------------------------| 18262 |asinhl(GLIBC_2.0)[1] |ctanl(GLIBC_2.0)[1] |lrintl(GLIBC_2.0)[1] | 18263 |----------------------+----------------------------+-------------------------| 18264 |asinl(GLIBC_2.0)[1] |dremf(GLIBC_2.0)[1] |lround(GLIBC_2.0)[1] | 18265 |----------------------+----------------------------+-------------------------| 18266 |atan(GLIBC_2.0)[1] |dreml(GLIBC_2.0)[1] |lroundf(GLIBC_2.0)[1] | 18267 |----------------------+----------------------------+-------------------------| 18268 |atan2(GLIBC_2.0)[1] |erf(GLIBC_2.0)[1] |lroundl(GLIBC_2.0)[1] | 18269 |----------------------+----------------------------+-------------------------| 18270 |atan2f(GLIBC_2.0)[1] |erfc(GLIBC_2.0)[1] |matherr(GLIBC_2.0)[1] | 18271 |----------------------+----------------------------+-------------------------| 18272 |atan2l(GLIBC_2.0)[1] |erfcf(GLIBC_2.0)[1] |modf(GLIBC_2.0)[1] | 18273 |----------------------+----------------------------+-------------------------| 18274 |atanf(GLIBC_2.0)[1] |erfcl(GLIBC_2.0)[1] |modff(GLIBC_2.0)[1] | 18275 |----------------------+----------------------------+-------------------------| 18276 |atanh(GLIBC_2.0)[1] |erff(GLIBC_2.0)[1] |modfl(GLIBC_2.0)[1] | 18277 |----------------------+----------------------------+-------------------------| 18278 |atanhf(GLIBC_2.0)[1] |erfl(GLIBC_2.0)[1] |nan(GLIBC_2.0)[1] | 18279 |----------------------+----------------------------+-------------------------| 18280 |atanhl(GLIBC_2.0)[1] |exp(GLIBC_2.0)[1] |nanf(GLIBC_2.0)[1] | 18281 |----------------------+----------------------------+-------------------------| 18282 |atanl(GLIBC_2.0)[1] |expf[1] |nanl(GLIBC_2.0)[1] | 18283 |----------------------+----------------------------+-------------------------| 18284 |cabs(GLIBC_2.1)[1] |expl[1] |nearbyint(GLIBC_2.1)[1] | 18285 |----------------------+----------------------------+-------------------------| 18286 |cabsf(GLIBC_2.1)[1] |expm1(GLIBC_2.1)[1] |nearbyintf(GLIBC_2.1)[1] | 18287 |----------------------+----------------------------+-------------------------| 18288 |cabsl(GLIBC_2.1)[1] |fabs(GLIBC_2.1)[1] |nearbyintl(GLIBC_2.1)[1] | 18289 |----------------------+----------------------------+-------------------------| 18290 |cacos(GLIBC_2.1)[1] |fabsf(GLIBC_2.1)[1] |nextafter(GLIBC_2.1)[1] | 18291 |----------------------+----------------------------+-------------------------| 18292 |cacosf(GLIBC_2.1)[1] |fabsl(GLIBC_2.1)[1] |nextafterf(GLIBC_2.1)[1] | 18293 |----------------------+----------------------------+-------------------------| 18294 |cacosh(GLIBC_2.1)[1] |fdim(GLIBC_2.1)[1] |nextafterl(GLIBC_2.1)[1] | 18295 |----------------------+----------------------------+-------------------------| 18296 |cacoshf(GLIBC_2.1)[1] |fdimf(GLIBC_2.1)[1] |nexttoward(GLIBC_2.1)[1] | 18297 |----------------------+----------------------------+-------------------------| 18298 |cacoshl(GLIBC_2.1)[1] |fdiml(GLIBC_2.1)[1] |nexttowardf(GLIBC_2.1)[1]| 18299 |----------------------+----------------------------+-------------------------| 18300 |cacosl(GLIBC_2.1)[1] |feclearexcept(GLIBC_2.1)[1] |nexttowardl(GLIBC_2.1)[1]| 18301 |----------------------+----------------------------+-------------------------| 18302 |carg(GLIBC_2.1)[1] |fegetenv(GLIBC_2.1)[1] |pow(GLIBC_2.1)[1] | 18303 |----------------------+----------------------------+-------------------------| 18304 |cargf(GLIBC_2.1)[1] |fegetexceptflag(GLIBC_2.1) |pow10(GLIBC_2.1)[1] | 18305 | |[1] | | 18306 |----------------------+----------------------------+-------------------------| 18307 |cargl(GLIBC_2.1)[1] |fegetround(GLIBC_2.1)[1] |pow10f(GLIBC_2.1)[1] | 18308 |----------------------+----------------------------+-------------------------| 18309 |casin(GLIBC_2.1)[1] |feholdexcept(GLIBC_2.1)[1] |pow10l(GLIBC_2.1)[1] | 18310 |----------------------+----------------------------+-------------------------| 18311 |casinf(GLIBC_2.1)[1] |feraiseexcept(GLIBC_2.1)[1] |powf(GLIBC_2.1)[1] | 18312 |----------------------+----------------------------+-------------------------| 18313 |casinh(GLIBC_2.1)[1] |fesetenv(GLIBC_2.1)[1] |powl(GLIBC_2.1)[1] | 18314 |----------------------+----------------------------+-------------------------| 18315 |casinhf(GLIBC_2.1)[1] |fesetexceptflag(GLIBC_2.1) |remainder(GLIBC_2.1)[1] | 18316 | |[1] | | 18317 |----------------------+----------------------------+-------------------------| 18318 |casinhl(GLIBC_2.1)[1] |fesetround(GLIBC_2.1)[1] |remainderf(GLIBC_2.1)[1] | 18319 |----------------------+----------------------------+-------------------------| 18320 |casinl(GLIBC_2.1)[1] |fetestexcept(GLIBC_2.1)[1] |remainderl(GLIBC_2.1)[1] | 18321 |----------------------+----------------------------+-------------------------| 18322 |catan(GLIBC_2.1)[1] |feupdateenv(GLIBC_2.1)[1] |remquo(GLIBC_2.1)[1] | 18323 |----------------------+----------------------------+-------------------------| 18324 |catanf(GLIBC_2.1)[1] |finite(GLIBC_2.1)[1] |remquof(GLIBC_2.1)[1] | 18325 |----------------------+----------------------------+-------------------------| 18326 |catanh(GLIBC_2.1)[1] |finitef(GLIBC_2.1)[1] |remquol(GLIBC_2.1)[1] | 18327 |----------------------+----------------------------+-------------------------| 18328 |catanhf(GLIBC_2.1)[1] |finitel(GLIBC_2.1)[1] |rint(GLIBC_2.1)[1] | 18329 |----------------------+----------------------------+-------------------------| 18330 |catanhl(GLIBC_2.1)[1] |floor(GLIBC_2.1)[1] |rintf(GLIBC_2.1)[1] | 18331 |----------------------+----------------------------+-------------------------| 18332 |catanl(GLIBC_2.1)[1] |floorf(GLIBC_2.1)[1] |rintl(GLIBC_2.1)[1] | 18333 |----------------------+----------------------------+-------------------------| 18334 |cbrt(GLIBC_2.0)[1] |floorl(GLIBC_2.0)[1] |round(GLIBC_2.0)[1] | 18335 |----------------------+----------------------------+-------------------------| 18336 |cbrtf(GLIBC_2.0)[1] |fma(GLIBC_2.0)[1] |roundf(GLIBC_2.0)[1] | 18337 |----------------------+----------------------------+-------------------------| 18338 |cbrtl(GLIBC_2.0)[1] |fmaf(GLIBC_2.0)[1] |roundl(GLIBC_2.0)[1] | 18339 |----------------------+----------------------------+-------------------------| 18340 |ccos(GLIBC_2.1)[1] |fmal(GLIBC_2.1)[1] |scalb(GLIBC_2.1)[1] | 18341 |----------------------+----------------------------+-------------------------| 18342 |ccosf(GLIBC_2.1)[1] |fmax(GLIBC_2.1)[1] |scalbf(GLIBC_2.1)[1] | 18343 |----------------------+----------------------------+-------------------------| 18344 |ccosh(GLIBC_2.1)[1] |fmaxf(GLIBC_2.1)[1] |scalbl(GLIBC_2.1)[1] | 18345 |----------------------+----------------------------+-------------------------| 18346 |ccoshf(GLIBC_2.1)[1] |fmaxl(GLIBC_2.1)[1] |scalbln(GLIBC_2.1)[1] | 18347 |----------------------+----------------------------+-------------------------| 18348 |ccoshl(GLIBC_2.1)[1] |fmin(GLIBC_2.1)[1] |scalblnf(GLIBC_2.1)[1] | 18349 |----------------------+----------------------------+-------------------------| 18350 |ccosl(GLIBC_2.1)[1] |fminf(GLIBC_2.1)[1] |scalblnl(GLIBC_2.1)[1] | 18351 |----------------------+----------------------------+-------------------------| 18352 |ceil(GLIBC_2.0)[1] |fminl(GLIBC_2.0)[1] |scalbn(GLIBC_2.0)[1] | 18353 |----------------------+----------------------------+-------------------------| 18354 |ceilf(GLIBC_2.0)[1] |fmod(GLIBC_2.0)[1] |scalbnf(GLIBC_2.0)[1] | 18355 |----------------------+----------------------------+-------------------------| 18356 |ceill(GLIBC_2.0)[1] |fmodf(GLIBC_2.0)[1] |scalbnl(GLIBC_2.0)[1] | 18357 |----------------------+----------------------------+-------------------------| 18358 |cexp(GLIBC_2.1)[1] |fmodl(GLIBC_2.1)[1] |significand(GLIBC_2.1)[1]| 18359 |----------------------+----------------------------+-------------------------| 18360 |cexpf(GLIBC_2.1)[1] |frexp(GLIBC_2.1)[1] |significandf(GLIBC_2.1) | 18361 | | |[1] | 18362 |----------------------+----------------------------+-------------------------| 18363 |cexpl(GLIBC_2.1)[1] |frexpf(GLIBC_2.1)[1] |significandl(GLIBC_2.1) | 18364 | | |[1] | 18365 |----------------------+----------------------------+-------------------------| 18366 |cimag(GLIBC_2.1)[1] |frexpl(GLIBC_2.1)[1] |sin(GLIBC_2.1)[1] | 18367 |----------------------+----------------------------+-------------------------| 18368 |cimagf(GLIBC_2.1)[1] |gamma(GLIBC_2.1)[1] |sincos(GLIBC_2.1)[1] | 18369 |----------------------+----------------------------+-------------------------| 18370 |cimagl(GLIBC_2.1)[1] |gammaf(GLIBC_2.1)[1] |sincosf(GLIBC_2.1)[1] | 18371 |----------------------+----------------------------+-------------------------| 18372 |clog(GLIBC_2.1)[1] |gammal(GLIBC_2.1)[1] |sincosl(GLIBC_2.1)[1] | 18373 |----------------------+----------------------------+-------------------------| 18374 |clog10(GLIBC_2.1)[1] |hypot(GLIBC_2.1)[1] |sinf(GLIBC_2.1)[1] | 18375 |----------------------+----------------------------+-------------------------| 18376 |clog10f(GLIBC_2.1)[1] |hypotf(GLIBC_2.1)[1] |sinh(GLIBC_2.1)[1] | 18377 |----------------------+----------------------------+-------------------------| 18378 |clog10l(GLIBC_2.1)[1] |hypotl(GLIBC_2.1)[1] |sinhf(GLIBC_2.1)[1] | 18379 |----------------------+----------------------------+-------------------------| 18380 |clogf(GLIBC_2.1)[1] |ilogb(GLIBC_2.1)[1] |sinhl(GLIBC_2.1)[1] | 18381 |----------------------+----------------------------+-------------------------| 18382 |clogl(GLIBC_2.1)[1] |ilogbf(GLIBC_2.1)[1] |sinl(GLIBC_2.1)[1] | 18383 |----------------------+----------------------------+-------------------------| 18384 |conj(GLIBC_2.1)[1] |ilogbl(GLIBC_2.1)[1] |sqrt(GLIBC_2.1)[1] | 18385 |----------------------+----------------------------+-------------------------| 18386 |conjf(GLIBC_2.1)[1] |j0(GLIBC_2.1)[1] |sqrtf(GLIBC_2.1)[1] | 18387 |----------------------+----------------------------+-------------------------| 18388 |conjl(GLIBC_2.1)[1] |j0f(GLIBC_2.1)[1] |sqrtl(GLIBC_2.1)[1] | 18389 |----------------------+----------------------------+-------------------------| 18390 |copysign(GLIBC_2.0)[1]|j0l(GLIBC_2.0)[1] |tan(GLIBC_2.0)[1] | 18391 |----------------------+----------------------------+-------------------------| 18392 |copysignf(GLIBC_2.0) |j1(GLIBC_2.0)[1] |tanf(GLIBC_2.0)[1] | 18393 |[1] | | | 18394 |----------------------+----------------------------+-------------------------| 18395 |copysignl(GLIBC_2.0) |j1f(GLIBC_2.0)[1] |tanh(GLIBC_2.0)[1] | 18396 |[1] | | | 18397 |----------------------+----------------------------+-------------------------| 18398 |cos(GLIBC_2.0)[1] |j1l(GLIBC_2.0)[1] |tanhf(GLIBC_2.0)[1] | 18399 |----------------------+----------------------------+-------------------------| 18400 |cosf(GLIBC_2.0)[1] |jn(GLIBC_2.0)[1] |tanhl(GLIBC_2.0)[1] | 18401 |----------------------+----------------------------+-------------------------| 18402 |cosh(GLIBC_2.0)[1] |jnf(GLIBC_2.0)[1] |tanl(GLIBC_2.0)[1] | 18403 |----------------------+----------------------------+-------------------------| 18404 |coshf(GLIBC_2.0)[1] |jnl(GLIBC_2.0)[1] |tgamma(GLIBC_2.0)[1] | 18405 |----------------------+----------------------------+-------------------------| 18406 |coshl(GLIBC_2.0)[1] |ldexp(GLIBC_2.0)[1] |tgammaf(GLIBC_2.0)[1] | 18407 |----------------------+----------------------------+-------------------------| 18408 |cosl(GLIBC_2.0)[1] |ldexpf(GLIBC_2.0)[1] |tgammal(GLIBC_2.0)[1] | 18409 |----------------------+----------------------------+-------------------------| 18410 |cpow(GLIBC_2.1)[1] |ldexpl(GLIBC_2.1)[1] |trunc(GLIBC_2.1)[1] | 18411 |----------------------+----------------------------+-------------------------| 18412 |cpowf(GLIBC_2.1)[1] |lgamma(GLIBC_2.1)[1] |truncf(GLIBC_2.1)[1] | 18413 |----------------------+----------------------------+-------------------------| 18414 |cpowl(GLIBC_2.1)[1] |lgamma_r(GLIBC_2.1)[1] |truncl(GLIBC_2.1)[1] | 18415 |----------------------+----------------------------+-------------------------| 18416 |cproj(GLIBC_2.1)[1] |lgammaf(GLIBC_2.1)[1] |y0(GLIBC_2.1)[1] | 18417 |----------------------+----------------------------+-------------------------| 18418 |cprojf(GLIBC_2.1)[1] |lgammaf_r(GLIBC_2.1)[1] |y0f(GLIBC_2.1)[1] | 18419 |----------------------+----------------------------+-------------------------| 18420 |cprojl(GLIBC_2.1)[1] |lgammal(GLIBC_2.1)[1] |y0l(GLIBC_2.1)[1] | 18421 |----------------------+----------------------------+-------------------------| 18422 |creal(GLIBC_2.1)[1] |lgammal_r(GLIBC_2.1)[1] |y1(GLIBC_2.1)[1] | 18423 |----------------------+----------------------------+-------------------------| 18424 |crealf(GLIBC_2.1)[1] |llrint(GLIBC_2.1)[1] |y1f(GLIBC_2.1)[1] | 18425 |----------------------+----------------------------+-------------------------| 18426 |creall(GLIBC_2.1)[1] |llrintf(GLIBC_2.1)[1] |y1l(GLIBC_2.1)[1] | 18427 |----------------------+----------------------------+-------------------------| 18428 |csin(GLIBC_2.1)[1] |llrintl(GLIBC_2.1)[1] |yn(GLIBC_2.1)[1] | 18429 |----------------------+----------------------------+-------------------------| 18430 |csinf(GLIBC_2.1)[1] |llround(GLIBC_2.1)[1] |ynf(GLIBC_2.1)[1] | 18431 |----------------------+----------------------------+-------------------------| 18432 |csinh(GLIBC_2.1)[1] |llroundf(GLIBC_2.1)[1] |ynl(GLIBC_2.1)[1] | 18433 |----------------------+----------------------------+-------------------------| 18434 |csinhf(GLIBC_2.1)[1] |llroundl(GLIBC_2.1)[1] | | 18435 +-----------------------------------------------------------------------------+ 18436 18437 Table A-6. libm Data Interfaces 18438 18439 +-------------+ 18440 |signgam | | | 18441 +-------------+ 18442 ------------------------------------------------------------------------------- 18443 18444 libncurses 18445 18446 The behaviour of the interfaces in this library is specified by the following 18447 Standards. 18448 18449 X/Open Curses 18450 18451 Table A-7. libncurses Function Interfaces 18452 18453 +-------------------------------------------------------+ 18454 |addch[1] |mvdelch[1] |slk_refresh[1] | 18455 |-------------------+-------------------+---------------| 18456 |addchnstr[1] |mvderwin[1] |slk_restore[1] | 18457 |-------------------+-------------------+---------------| 18458 |addchstr[1] |mvgetch[1] |slk_set[1] | 18459 |-------------------+-------------------+---------------| 18460 |addnstr[1] |mvgetnstr[1] |slk_touch[1] | 18461 |-------------------+-------------------+---------------| 18462 |addstr[1] |mvgetstr[1] |standend[1] | 18463 |-------------------+-------------------+---------------| 18464 |attr_get[1] |mvhline[1] |standout[1] | 18465 |-------------------+-------------------+---------------| 18466 |attr_off[1] |mvinch[1] |start_color[1] | 18467 |-------------------+-------------------+---------------| 18468 |attr_on[1] |mvinchnstr[1] |subpad[1] | 18469 |-------------------+-------------------+---------------| 18470 |attr_set[1] |mvinchstr[1] |subwin[1] | 18471 |-------------------+-------------------+---------------| 18472 |attroff[1] |mvinnstr[1] |syncok[1] | 18473 |-------------------+-------------------+---------------| 18474 |attron[1] |mvinsch[1] |termattrs[1] | 18475 |-------------------+-------------------+---------------| 18476 |attrset[1] |mvinsnstr[1] |termname[1] | 18477 |-------------------+-------------------+---------------| 18478 |baudrate[1] |mvinsstr[1] |tgetent[1] | 18479 |-------------------+-------------------+---------------| 18480 |beep[1] |mvinstr[1] |tgetflag[1] | 18481 |-------------------+-------------------+---------------| 18482 |bkgd[1] |mvprintw[1] |tgetnum[1] | 18483 |-------------------+-------------------+---------------| 18484 |bkgdset[1] |mvscanw[1] |tgetstr[1] | 18485 |-------------------+-------------------+---------------| 18486 |border[1] |mvvline[1] |tgoto[1] | 18487 |-------------------+-------------------+---------------| 18488 |box[1] |mvwaddch[1] |tigetflag[1] | 18489 |-------------------+-------------------+---------------| 18490 |can_change_color[1]|mvwaddchnstr[1] |tigetnum[1] | 18491 |-------------------+-------------------+---------------| 18492 |cbreak[1] |mvwaddchstr[1] |tigetstr[1] | 18493 |-------------------+-------------------+---------------| 18494 |chgat[1] |mvwaddnstr[1] |timeout[1] | 18495 |-------------------+-------------------+---------------| 18496 |clear[1] |mvwaddstr[1] |touchline[1] | 18497 |-------------------+-------------------+---------------| 18498 |clearok[1] |mvwchgat[1] |touchwin[1] | 18499 |-------------------+-------------------+---------------| 18500 |clrtobot[1] |mvwdelch[1] |tparm[1] | 18501 |-------------------+-------------------+---------------| 18502 |clrtoeol[1] |mvwgetch[1] |tputs[1] | 18503 |-------------------+-------------------+---------------| 18504 |color_content[1] |mvwgetnstr[1] |typeahead[1] | 18505 |-------------------+-------------------+---------------| 18506 |color_set[1] |mvwgetstr[1] |unctrl[1] | 18507 |-------------------+-------------------+---------------| 18508 |copywin[1] |mvwhline[1] |ungetch[1] | 18509 |-------------------+-------------------+---------------| 18510 |curs_set[1] |mvwin[1] |untouchwin[1] | 18511 |-------------------+-------------------+---------------| 18512 |def_prog_mode[1] |mvwinch[1] |use_env[1] | 18513 |-------------------+-------------------+---------------| 18514 |def_shell_mode[1] |mvwinchnstr[1] |vidattr[1] | 18515 |-------------------+-------------------+---------------| 18516 |del_curterm[1] |mvwinchstr[1] |vidputs[1] | 18517 |-------------------+-------------------+---------------| 18518 |delay_output[1] |mvwinnstr[1] |vline[1] | 18519 |-------------------+-------------------+---------------| 18520 |delch[1] |mvwinsch[1] |vw_printw[1] | 18521 |-------------------+-------------------+---------------| 18522 |deleteln[1] |mvwinsnstr[1] |vw_scanw[1] | 18523 |-------------------+-------------------+---------------| 18524 |delscreen[1] |mvwinsstr[1] |vwprintw[1] | 18525 |-------------------+-------------------+---------------| 18526 |delwin[1] |mvwinstr[1] |vwscanw[1] | 18527 |-------------------+-------------------+---------------| 18528 |derwin[1] |mvwprintw[1] |waddch[1] | 18529 |-------------------+-------------------+---------------| 18530 |doupdate[1] |mvwscanw[1] |waddchnstr[1] | 18531 |-------------------+-------------------+---------------| 18532 |dupwin[1] |mvwvline[1] |waddchstr[1] | 18533 |-------------------+-------------------+---------------| 18534 |echo[1] |napms[1] |waddnstr[1] | 18535 |-------------------+-------------------+---------------| 18536 |echochar[1] |newpad[1] |waddstr[1] | 18537 |-------------------+-------------------+---------------| 18538 |endwin[1] |newterm[1] |wattr_get[1] | 18539 |-------------------+-------------------+---------------| 18540 |erase[1] |newwin[1] |wattr_off[1] | 18541 |-------------------+-------------------+---------------| 18542 |erasechar[1] |nl[1] |wattr_on[1] | 18543 |-------------------+-------------------+---------------| 18544 |filter[1] |nocbreak[1] |wattr_set[1] | 18545 |-------------------+-------------------+---------------| 18546 |flash[1] |nodelay[1] |wattroff[1] | 18547 |-------------------+-------------------+---------------| 18548 |flushinp[1] |noecho[1] |wattron[1] | 18549 |-------------------+-------------------+---------------| 18550 |getbkgd[1] |nonl[1] |wattrset[1] | 18551 |-------------------+-------------------+---------------| 18552 |getch[1] |noqiflush[1] |wbkgd[1] | 18553 |-------------------+-------------------+---------------| 18554 |getnstr[1] |noraw[1] |wbkgdset[1] | 18555 |-------------------+-------------------+---------------| 18556 |getstr[1] |notimeout[1] |wborder[1] | 18557 |-------------------+-------------------+---------------| 18558 |getwin[1] |overlay[1] |wchgat[1] | 18559 |-------------------+-------------------+---------------| 18560 |halfdelay[1] |overwrite[1] |wclear[1] | 18561 |-------------------+-------------------+---------------| 18562 |has_colors[1] |pair_content[1] |wclrtobot[1] | 18563 |-------------------+-------------------+---------------| 18564 |has_ic[1] |pechochar[1] |wclrtoeol[1] | 18565 |-------------------+-------------------+---------------| 18566 |has_il[1] |pnoutrefresh[1] |wcolor_set[1] | 18567 |-------------------+-------------------+---------------| 18568 |hline[1] |prefresh[1] |wcursyncup[1] | 18569 |-------------------+-------------------+---------------| 18570 |idcok[1] |printw[1] |wdelch[1] | 18571 |-------------------+-------------------+---------------| 18572 |idlok[1] |putp[1] |wdeleteln[1] | 18573 |-------------------+-------------------+---------------| 18574 |immedok[1] |putwin[1] |wechochar[1] | 18575 |-------------------+-------------------+---------------| 18576 |inch[1] |qiflush[1] |werase[1] | 18577 |-------------------+-------------------+---------------| 18578 |inchnstr[1] |raw[1] |wgetch[1] | 18579 |-------------------+-------------------+---------------| 18580 |inchstr[1] |redrawwin[1] |wgetnstr[1] | 18581 |-------------------+-------------------+---------------| 18582 |init_color[1] |refresh[1] |wgetstr[1] | 18583 |-------------------+-------------------+---------------| 18584 |init_pair[1] |reset_prog_mode[1] |whline[1] | 18585 |-------------------+-------------------+---------------| 18586 |initscr[1] |reset_shell_mode[1]|winch[1] | 18587 |-------------------+-------------------+---------------| 18588 |innstr[1] |resetty[1] |winchnstr[1] | 18589 |-------------------+-------------------+---------------| 18590 |insch[1] |restartterm[1] |winchstr[1] | 18591 |-------------------+-------------------+---------------| 18592 |insdelln[1] |ripoffline[1] |winnstr[1] | 18593 |-------------------+-------------------+---------------| 18594 |insertln[1] |savetty[1] |winsch[1] | 18595 |-------------------+-------------------+---------------| 18596 |insnstr[1] |scanw[1] |winsdelln[1] | 18597 |-------------------+-------------------+---------------| 18598 |insstr[1] |scr_dump[1] |winsertln[1] | 18599 |-------------------+-------------------+---------------| 18600 |instr[1] |scr_init[1] |winsnstr[1] | 18601 |-------------------+-------------------+---------------| 18602 |intrflush[1] |scr_restore[1] |winsstr[1] | 18603 |-------------------+-------------------+---------------| 18604 |is_linetouched[1] |scr_set[1] |winstr[1] | 18605 |-------------------+-------------------+---------------| 18606 |is_wintouched[1] |scrl[1] |wmove[1] | 18607 |-------------------+-------------------+---------------| 18608 |isendwin[1] |scroll[1] |wnoutrefresh[1]| 18609 |-------------------+-------------------+---------------| 18610 |keyname[1] |scrollok[1] |wprintw[1] | 18611 |-------------------+-------------------+---------------| 18612 |keypad[1] |set_curterm[1] |wredrawln[1] | 18613 |-------------------+-------------------+---------------| 18614 |killchar[1] |set_term[1] |wrefresh[1] | 18615 |-------------------+-------------------+---------------| 18616 |leaveok[1] |setscrreg[1] |wscanw[1] | 18617 |-------------------+-------------------+---------------| 18618 |longname[1] |setupterm[1] |wscrl[1] | 18619 |-------------------+-------------------+---------------| 18620 |meta[1] |slk_attr_set[1] |wsetscrreg[1] | 18621 |-------------------+-------------------+---------------| 18622 |move[1] |slk_attroff[1] |wstandend[1] | 18623 |-------------------+-------------------+---------------| 18624 |mvaddch[1] |slk_attron[1] |wstandout[1] | 18625 |-------------------+-------------------+---------------| 18626 |mvaddchnstr[1] |slk_attrset[1] |wsyncdown[1] | 18627 |-------------------+-------------------+---------------| 18628 |mvaddchstr[1] |slk_clear[1] |wsyncup[1] | 18629 |-------------------+-------------------+---------------| 18630 |mvaddnstr[1] |slk_color[1] |wtimeout[1] | 18631 |-------------------+-------------------+---------------| 18632 |mvaddstr[1] |slk_init[1] |wtouchln[1] | 18633 |-------------------+-------------------+---------------| 18634 |mvchgat[1] |slk_label[1] |wvline[1] | 18635 |-------------------+-------------------+---------------| 18636 |mvcur[1] |slk_noutrefresh[1] | | 18637 +-------------------------------------------------------+ 18638 18639 Table A-8. libncurses Data Interfaces 18640 18641 +-------------------------------+ 18642 |COLORS |LINES |curscr | 18643 |-------------+---------+-------| 18644 |COLOR_PAIRS |acs_map |stdscr | 18645 |-------------+---------+-------| 18646 |COLS |cur_term | | 18647 +-------------------------------+ 18648 ------------------------------------------------------------------------------- 18649 18650 libpam 18651 18652 The behaviour of the interfaces in this library is specified by the following 18653 Standards. 18654 18655 this specification 18656 18657 Table A-9. libpam Function Interfaces 18658 18659 +--------------------------------------------------------+ 18660 |pam_acct_mgmt[1] |pam_fail_delay[1] |pam_setcred[1] | 18661 |--------------------+-------------------+---------------| 18662 |pam_authenticate[1] |pam_get_item[1] |pam_start[1] | 18663 |--------------------+-------------------+---------------| 18664 |pam_chauthtok[1] |pam_getenvlist[1] |pam_strerror[1]| 18665 |--------------------+-------------------+---------------| 18666 |pam_close_session[1]|pam_open_session[1]| | 18667 |--------------------+-------------------+---------------| 18668 |pam_end[1] |pam_set_item[1] | | 18669 +--------------------------------------------------------+ 18670 ------------------------------------------------------------------------------- 18671 18672 libpthread 18673 18674 The behaviour of the interfaces in this library is specified by the following 18675 Standards. 18676 18677 Large File Support 18678 this specification 18679 ISO POSIX (2003) 18680 18681 Table A-10. libpthread Function Interfaces 18682 18683 +--------------------------------------------------------------------------------------+ 18684 |_pthread_cleanup_pop[1] |pthread_create()[1] |pthread_rwlock_trywrlock()[1]| 18685 |---------------------------+----------------------------+-----------------------------| 18686 |_pthread_cleanup_push[1] |pthread_detach()[1] |pthread_rwlock_unlock()[1] | 18687 |---------------------------+----------------------------+-----------------------------| 18688 |pread(GLIBC_2.1)[1] |pthread_equal(GLIBC_2.1)[1] |pthread_rwlock_wrlock | 18689 | | |(GLIBC_2.1)[1] | 18690 |---------------------------+----------------------------+-----------------------------| 18691 |pread64(GLIBC_2.1)[1] |pthread_exit(GLIBC_2.1)[1] |pthread_rwlockattr_destroy | 18692 | | |(GLIBC_2.1)[1] | 18693 |---------------------------+----------------------------+-----------------------------| 18694 |pthread_attr_destroy |pthread_getspecific |pthread_rwlockattr_getpshared| 18695 |(GLIBC_2.0)[1] |(GLIBC_2.0)[1] |(GLIBC_2.0)[1] | 18696 |---------------------------+----------------------------+-----------------------------| 18697 |pthread_attr_getdetachstate|pthread_join(GLIBC_2.0)[1] |pthread_rwlockattr_init | 18698 |(GLIBC_2.0)[1] | |(GLIBC_2.0)[1] | 18699 |---------------------------+----------------------------+-----------------------------| 18700 |pthread_attr_getguardsize |pthread_key_create |pthread_rwlockattr_setpshared| 18701 |(GLIBC_2.1)[1] |(GLIBC_2.1)[1] |(GLIBC_2.1)[1] | 18702 |---------------------------+----------------------------+-----------------------------| 18703 |pthread_attr_getschedparam |pthread_key_delete |pthread_self(GLIBC_2.0)[1] | 18704 |(GLIBC_2.0)[1] |(GLIBC_2.0)[1] | | 18705 |---------------------------+----------------------------+-----------------------------| 18706 |pthread_attr_getstackaddr |pthread_kill(GLIBC_2.1)[1] |pthread_setcancelstate | 18707 |(GLIBC_2.1)[1] | |(GLIBC_2.1)[1] | 18708 |---------------------------+----------------------------+-----------------------------| 18709 |pthread_attr_getstacksize |pthread_mutex_destroy |pthread_setcanceltype | 18710 |(GLIBC_2.1)[1] |(GLIBC_2.1)[1] |(GLIBC_2.1)[1] | 18711 |---------------------------+----------------------------+-----------------------------| 18712 |pthread_attr_init |pthread_mutex_init |pthread_setconcurrency[1] | 18713 |(GLIBC_2.1)[1] |(GLIBC_2.1)[1] | | 18714 |---------------------------+----------------------------+-----------------------------| 18715 |pthread_attr_setdetachstate|pthread_mutex_lock |pthread_setspecific | 18716 |(GLIBC_2.0)[1] |(GLIBC_2.0)[1] |(GLIBC_2.0)[1] | 18717 |---------------------------+----------------------------+-----------------------------| 18718 |pthread_attr_setguardsize |pthread_mutex_trylock |pthread_sigmask(GLIBC_2.1)[1]| 18719 |(GLIBC_2.1)[1] |(GLIBC_2.1)[1] | | 18720 |---------------------------+----------------------------+-----------------------------| 18721 |pthread_attr_setschedparam |pthread_mutex_unlock |pthread_testcancel(GLIBC_2.0)| 18722 |(GLIBC_2.0)[1] |(GLIBC_2.0)[1] |[1] | 18723 |---------------------------+----------------------------+-----------------------------| 18724 |pthread_attr_setstackaddr |pthread_mutexattr_destroy |pwrite(GLIBC_2.1)[1] | 18725 |(GLIBC_2.1)[1] |(GLIBC_2.1)[1] | | 18726 |---------------------------+----------------------------+-----------------------------| 18727 |pthread_attr_setstacksize |pthread_mutexattr_getpshared|pwrite64(GLIBC_2.1)[1] | 18728 |(GLIBC_2.1)[1] |(GLIBC_2.1)[1] | | 18729 |---------------------------+----------------------------+-----------------------------| 18730 |pthread_cancel(GLIBC_2.0) |pthread_mutexattr_gettype |sem_close(GLIBC_2.0)[1] | 18731 |[1] |(GLIBC_2.0)[1] | | 18732 |---------------------------+----------------------------+-----------------------------| 18733 |pthread_cond_broadcast |pthread_mutexattr_init |sem_destroy(GLIBC_2.0)[1] | 18734 |(GLIBC_2.0)[1] |(GLIBC_2.0)[1] | | 18735 |---------------------------+----------------------------+-----------------------------| 18736 |pthread_cond_destroy |pthread_mutexattr_setpshared|sem_getvalue(GLIBC_2.0)[1] | 18737 |(GLIBC_2.0)[1] |(GLIBC_2.0)[1] | | 18738 |---------------------------+----------------------------+-----------------------------| 18739 |pthread_cond_init |pthread_mutexattr_settype |sem_init(GLIBC_2.0)[1] | 18740 |(GLIBC_2.0)[1] |(GLIBC_2.0)[1] | | 18741 |---------------------------+----------------------------+-----------------------------| 18742 |pthread_cond_signal |pthread_once(GLIBC_2.0)[1] |sem_open(GLIBC_2.0)[1] | 18743 |(GLIBC_2.0)[1] | | | 18744 |---------------------------+----------------------------+-----------------------------| 18745 |pthread_cond_timedwait |pthread_rwlock_destroy |sem_post(GLIBC_2.0)[1] | 18746 |(GLIBC_2.0)[1] |(GLIBC_2.0)[1] | | 18747 |---------------------------+----------------------------+-----------------------------| 18748 |pthread_cond_wait |pthread_rwlock_init |sem_timedwait(GLIBC_2.0)[1] | 18749 |(GLIBC_2.0)[1] |(GLIBC_2.0)[1] | | 18750 |---------------------------+----------------------------+-----------------------------| 18751 |pthread_condattr_destroy |pthread_rwlock_rdlock |sem_trywait(GLIBC_2.0)[1] | 18752 |(GLIBC_2.0)[1] |(GLIBC_2.0)[1] | | 18753 |---------------------------+----------------------------+-----------------------------| 18754 |pthread_condattr_getpshared|pthread_rwlock_timedrdlock |sem_unlink()[1] | 18755 |[1] |[1] | | 18756 |---------------------------+----------------------------+-----------------------------| 18757 |pthread_condattr_init |pthread_rwlock_timedwrlock |sem_wait(GLIBC_2.0)[1] | 18758 |(GLIBC_2.0)[1] |[1] | | 18759 |---------------------------+----------------------------+-----------------------------| 18760 |pthread_condattr_setpshared|pthread_rwlock_tryrdlock() | | 18761 |[1] |[1] | | 18762 +--------------------------------------------------------------------------------------+ 18763 ------------------------------------------------------------------------------- 18764 18765 libutil 18766 18767 The behaviour of the interfaces in this library is specified by the following 18768 Standards. 18769 18770 this specification 18771 18772 Table A-11. libutil Function Interfaces 18773 18774 +-------------------------------------------------------------------+ 18775 |forkpty(GLIBC_2.0)[1]|login_tty(GLIBC_2.0)[1]|logwtmp(GLIBC_2.0)[1]| 18776 |---------------------+-----------------------+---------------------| 18777 |login(GLIBC_2.0)[1] |logout(GLIBC_2.0)[1] |openpty(GLIBC_2.0)[1]| 18778 +-------------------------------------------------------------------+ 18779 ------------------------------------------------------------------------------- 18780 18781 libz 18782 18783 The behaviour of the interfaces in this library is specified by the following 18784 Standards. 18785 18786 zlib Manual 18787 18788 Table A-12. libz Function Interfaces 18789 18790 +--------------------------------------------------------------+ 18791 |adler32[1] |gzdopen[1] |gztell[1] | 18792 |-----------------------+--------------+-----------------------| 18793 |compress[1] |gzeof[1] |gzwrite[1] | 18794 |-----------------------+--------------+-----------------------| 18795 |compress2[1] |gzerror[1] |inflate[1] | 18796 |-----------------------+--------------+-----------------------| 18797 |crc32[1] |gzflush[1] |inflateEnd[1] | 18798 |-----------------------+--------------+-----------------------| 18799 |deflate[1] |gzgetc[1] |inflateInit2_[1] | 18800 |-----------------------+--------------+-----------------------| 18801 |deflateCopy[1] |gzgets[1] |inflateInit_[1] | 18802 |-----------------------+--------------+-----------------------| 18803 |deflateEnd[1] |gzopen[1] |inflateReset[1] | 18804 |-----------------------+--------------+-----------------------| 18805 |deflateInit2_[1] |gzprintf[1] |inflateSetDictionary[1]| 18806 |-----------------------+--------------+-----------------------| 18807 |deflateInit_[1] |gzputc[1] |inflateSync[1] | 18808 |-----------------------+--------------+-----------------------| 18809 |deflateParams[1] |gzputs[1] |inflateSyncPoint[1] | 18810 |-----------------------+--------------+-----------------------| 18811 |deflateReset[1] |gzread[1] |uncompress[1] | 18812 |-----------------------+--------------+-----------------------| 18813 |deflateSetDictionary[1]|gzrewind[1] |zError[1] | 18814 |-----------------------+--------------+-----------------------| 18815 |get_crc_table[1] |gzseek[1] | | 18816 |-----------------------+--------------+-----------------------| 18817 |gzclose[1] |gzsetparams[1]| | 18818 +--------------------------------------------------------------+ 18819 18820 Linux Packaging Specification 18821 18822 ------------------------------------------------------------------------------- 18823 18824 Table of Contents 18825 I. Package Format and Installation 18826 18827 1. Software Installation 18828 18829 Package File Format 18830 Package Script Restrictions 18831 Package Tools 18832 Package Naming 18833 Package Dependencies 18834 Package Architecture Considerations 18835 18836 List of Tables 18837 1-1. RPM File Format 18838 1-2. Signature Format 18839 1-3. Index Type values 18840 1-4. Header Private Tag Values 18841 1-5. Signature Tag Values 18842 1-6. Signature Digest Tag Values 18843 1-7. Signature Signing Tag Values 18844 1-8. Package Info Tag Values 18845 1-9. Installation Tag Values 18846 1-10. File Info Tag Values 18847 1-11. Package Dependency Tag Values 18848 1-12. Index Type values 18849 1-13. Package Dependency Attributes 18850 1-14. Other Tag Values 18851 1-15. CPIO File Format 18852 18853 I. Package Format and Installation 18854 18855 Table of Contents 18856 1. Software Installation 18857 18858 ------------------------------------------------------------------------------- 18859 18860 Chapter 1. Software Installation 18861 18862 Applications shall either be packaged in the RPM packaging format as defined in 18863 this specification, or supply an installer which is LSB conforming (for 18864 example, calls LSB commands and utilities). [12] 18865 18866 Distributions shall provide a mechanism for installing applications in this 18867 packaging format with some restrictions listed below. [13] 18868 18869 ------------------------------------------------------------------------------- 18870 18871 Package File Format 18872 18873 An RPM format file consists of 4 sections, the Lead, Signature, Header, and the 18874 Payload. All values are stored in network byte order. 18875 18876 Table 1-1. RPM File Format 18877 18878 +---------+ 18879 |Lead | 18880 |---------| 18881 |Signature| 18882 |---------| 18883 |Header | 18884 |---------| 18885 |Payload | 18886 +---------+ 18887 18888 These 4 sections shall exist in the order specified. 18889 18890 The lead section is used to identify the package file. 18891 18892 The signature section is used to verify the integrity, and optionally, the 18893 authenticity of the majority of the package file. 18894 18895 The header section contains all available information about the package. 18896 Entries such as the package's name, version, and file list, are contained in 18897 the header. 18898 18899 The payload section holds the files to be install. 18900 18901 ------------------------------------------------------------------------------- 18902 18903 Lead Section 18904 18905 struct rpmlead { 18906 unsigned char magic[4]; 18907 unsigned char major, minor; 18908 short type; 18909 short archnum; 18910 char name[66]; 18911 short osnum; 18912 short signature_type; 18913 char reserved[16]; 18914 } ; 18915 18916 magic 18917 18918 Value identifying this file as an RPM format file. This value shall be "\ 18919 355\253\356\333". 18920 18921 major 18922 18923 Value indicating the major version number of the file format version. This 18924 value shall be 3. 18925 18926 minor 18927 18928 Value indicating the minor revision number of file format version. This 18929 value shall be 0. 18930 18931 type 18932 18933 Value indicating whether this is a source or binary package. This value 18934 shall be 0 to indicate a binary package. 18935 18936 archnum 18937 18938 Value indicating the architecture for which this package is valid. This 18939 value is specified in the architecture-specific LSB specification. 18940 18941 name 18942 18943 A NUL terminated string that provides the package name. This name shall 18944 conform with the Package Naming section of this specification. 18945 18946 osnum 18947 18948 Value indicating the Operating System for which this package is valid. This 18949 value shall be 1. 18950 18951 signature_type 18952 18953 Value indicating the type of the signature used in the Signature part of 18954 the file. This value shall be 5. 18955 18956 reserved 18957 18958 Reserved space. The value is undefined. 18959 18960 ------------------------------------------------------------------------------- 18961 18962 Header Structure 18963 18964 The Header structure is used for both the Signature and Header Sections. A 18965 Header Structure consists of 3 parts, a Header record, followed by 1 or more 18966 Index records, followed by 0 or more bytes of data associated with the Index 18967 records. A Header structure shall be aligned to an 8 byte boundary. 18968 18969 Table 1-2. Signature Format 18970 18971 +----------------------+ 18972 |Header Record | 18973 |----------------------| 18974 |Array of Index Records| 18975 |----------------------| 18976 |Store of Index Values | 18977 +----------------------+ 18978 ------------------------------------------------------------------------------- 18979 18980 Header Record 18981 18982 struct rpmheader { 18983 unsigned char magic[4]; 18984 unsigned char reserved[4]; 18985 int nindex; 18986 int hsize; 18987 } ; 18988 18989 magic 18990 18991 Value identifying this record as an RPM header record. This value shall be 18992 "\216\255\350\001". 18993 18994 reserved 18995 18996 Reserved space. This value shall be "\000\000\000\000". 18997 18998 nindex 18999 19000 The number of Index Records that follow this Header Record. There should be 19001 at least 1 Index Record. 19002 19003 hsize 19004 19005 The size in bytes of the storage area for the data pointed to by the Index 19006 Records. 19007 19008 ------------------------------------------------------------------------------- 19009 19010 Index Record 19011 19012 struct rpmhdrindex { 19013 int tag; 19014 int type; 19015 int offset; 19016 int count; 19017 } ; 19018 19019 tag 19020 19021 Value identifying the purpose of the data associated with this Index 19022 Record. This value of this field is dependent on the context in which the 19023 Index Record is used, and is defined below and in later sections. 19024 19025 type 19026 19027 Value identifying the type of the data associated with this Index Record. 19028 The possible type values are defined below. 19029 19030 offset 19031 19032 Location in the Store of the data associated with this Index Record. This 19033 value should between 0 and the value contained in the hsize of the Header 19034 Structure. 19035 19036 count 19037 19038 Size of the data associated with this Index Record. The count is the number 19039 of elements whose size is defined by the type of this Record. 19040 19041 ------------------------------------------------------------------------------- 19042 19043 Index Type Values 19044 19045 The possible values for the type field are defined in this table. 19046 19047 Table 1-3. Index Type values 19048 19049 +-----------------------------------------------------------------------------+ 19050 | Type |Value| Size (in bytes) |Alignment| 19051 |---------------------+-----+---------------------------------------+---------| 19052 |RPM_NULL_TYPE |0 |Not Implemented. | | 19053 |---------------------+-----+---------------------------------------+---------| 19054 |RPM_CHAR_TYPE |1 |1 |1 | 19055 |---------------------+-----+---------------------------------------+---------| 19056 |RPM_INT8_TYPE |2 |1 |1 | 19057 |---------------------+-----+---------------------------------------+---------| 19058 |RPM_INT16_TYPE |3 |2 |2 | 19059 |---------------------+-----+---------------------------------------+---------| 19060 |RPM_INT32_TYPE |4 |4 |4 | 19061 |---------------------+-----+---------------------------------------+---------| 19062 |RPM_INT64_TYPE |5 |Reserved. | | 19063 |---------------------+-----+---------------------------------------+---------| 19064 |RPM_STRING_TYPE |6 |variable, NUL terminated |1 | 19065 |---------------------+-----+---------------------------------------+---------| 19066 |RPM_BIN_TYPE |7 |1 |1 | 19067 |---------------------+-----+---------------------------------------+---------| 19068 |RPM_STRING_ARRAY_TYPE|8 |Variable, sequence of NUL terminated |1 | 19069 | | |strings | | 19070 |---------------------+-----+---------------------------------------+---------| 19071 |RPM_I18NSTRING_TYPE |9 |variable, sequence of NUL terminated |1 | 19072 | | |strings | | 19073 +-----------------------------------------------------------------------------+ 19074 19075 The string arrays specified for enties of type RPM_STRING_ARRAY_TYPE and 19076 RPM_I18NSTRING_TYPE are vectors of strings in a contiguous block of memory, 19077 each element separated from its neighbors by a NUL character. 19078 19079 Index records with type RPM_I18NSTRING_TYPE shall always have a count of 1. The 19080 array entries in an index of type RPM_I18NSTRING_TYPE correspond to the locale 19081 names contained in the RPMTAG_HDRI18NTABLE index. 19082 19083 ------------------------------------------------------------------------------- 19084 19085 Index Tag Values 19086 19087 Some values are designated as header private, and may appear in any header 19088 structure. These are defined here. Additional values are defined in later 19089 sections. 19090 19091 Table 1-4. Header Private Tag Values 19092 19093 +-------------------------------------------------------------+ 19094 | Name |Tag Value| Type |Count| Status | 19095 |-----------------------+---------+------------+-----+--------| 19096 |RPMTAG_HEADERSIGNATURES|62 |BIN |16 |Optional| 19097 |-----------------------+---------+------------+-----+--------| 19098 |RPMTAG_HEADERIMMUTABLE |63 |BIN |16 |Optional| 19099 |-----------------------+---------+------------+-----+--------| 19100 |RPMTAG_HEADERI18NTABLE |100 |STRING_ARRAY| |Required| 19101 +-------------------------------------------------------------+ 19102 19103 RPMTAG_HEADERSIGNATURES 19104 19105 The signature tag differentiates a signature header from a metadata header, 19106 and identifies the original contents of the signature header. 19107 19108 RPMTAG_HEADERIMMUTABLE 19109 19110 This tag contains an index record which specifies the portion of the Header 19111 Record which was used for the calculation of a signature. This data shall 19112 be preserved or any header-only signature will be invalidated. 19113 19114 RPMTAG_HEADERI18NTABLE 19115 19116 Contains a list of locales for which strings are provided in other parts of 19117 the package. 19118 19119 Not all Index records defined here will be present in all packages. Each tag 19120 value has a status which is defined here. 19121 19122 Required 19123 19124 This Index Record shall be present. 19125 19126 Optional 19127 19128 This Index Record may be present. 19129 19130 Deprecated 19131 19132 This Index Record should not be present. 19133 19134 Obsolete 19135 19136 This Index Record shall not be present. 19137 19138 Reserved 19139 19140 This Index Record shall not be present. 19141 19142 ------------------------------------------------------------------------------- 19143 19144 Header Store 19145 19146 The header store contains the values specified by the Index structures. These 19147 values are aligned according to their type and padding is used if needed. The 19148 store is located immediately following the Index structures. 19149 19150 ------------------------------------------------------------------------------- 19151 19152 Signature Section 19153 19154 The Signature section is implemented using the Header structure. The signature 19155 section defines the following additional tag values which may be used in the 19156 Index structures. 19157 19158 These values exist to provide additional information about the rest of the 19159 package. 19160 19161 Table 1-5. Signature Tag Values 19162 19163 +-------------------------------------------------+ 19164 | Name |Tag Value|Type |Count| Status | 19165 |------------------+---------+-----+-----+--------| 19166 |SIGTAG_SIGSIZE |1000 |INT32|1 |Required| 19167 |------------------+---------+-----+-----+--------| 19168 |SIGTAG_PAYLOADSIZE|1007 |INT32|1 |Optional| 19169 +-------------------------------------------------+ 19170 19171 SIGTAG_SIGSIZE 19172 19173 This tag specifies the combined size of the Header and Payload sections. 19174 19175 SIGTAG_PAYLOADSIZE 19176 19177 This tag specifies the uncompressed size of the Payload archive, including 19178 the cpio headers. 19179 19180 These values exist to ensure the integrity of the rest of the package. 19181 19182 Table 1-6. Signature Digest Tag Values 19183 19184 +-------------------------------------------------+ 19185 | Name |Tag Value| Type |Count| Status | 19186 |-----------------+---------+------+-----+--------| 19187 |SIGTAG_MD5 |1004 |BIN |16 |Required| 19188 |-----------------+---------+------+-----+--------| 19189 |SIGTAG_SHA1HEADER|1010 |STRING|1 |Optional| 19190 +-------------------------------------------------+ 19191 19192 SIGTAG_MD5 19193 19194 This tag specifies the 128-bit MD5 checksum of the combined Header and 19195 Archive sections. 19196 19197 SIGTAG_SHA1HEADER 19198 19199 This index contains the SHA1 checksum of the entire Header Section, 19200 including the Header Record, Index Records and Header store. 19201 19202 These values exist to provide authentication of the package. 19203 19204 Table 1-7. Signature Signing Tag Values 19205 19206 +----------------------------------------------+ 19207 | Name |Tag Value|Type|Count| Status | 19208 |----------------+---------+----+-----+--------| 19209 |SIGTAG_PGP |1002 |BIN |1 |Optional| 19210 |----------------+---------+----+-----+--------| 19211 |SIGTAG_GPG |1005 |BIN |65 |Optional| 19212 |----------------+---------+----+-----+--------| 19213 |SIGTAG_DSAHEADER|1011 |BIN |1 |Optional| 19214 |----------------+---------+----+-----+--------| 19215 |SIGTAG_RSAHEADER|1012 |BIN |1 |Optional| 19216 +----------------------------------------------+ 19217 19218 SIGTAG_PGP 19219 19220 This tag specifies the RSA signature of the combined Header and Payload 19221 sections. The data is formatted as a Version 3 Signature Packet as 19222 specified in RFC 2440: OpenPGP Message Format. 19223 19224 SIGTAG_GPG 19225 19226 The tag contains the DSA signature of the combined Header and Payload 19227 sections. The data is formatted as a Version 3 Signature Packet as 19228 specified in RFC 2440: OpenPGP Message Format. 19229 19230 SIGTAG_DSAHEADER 19231 19232 The tag contains the DSA signature of the Header section. The data is 19233 formatted as a Version 3 Signature Packet as specified in RFC 2440: OpenPGP 19234 Message Format. If this tag is present,then the SIGTAG_GPG tag shall also 19235 be present. 19236 19237 SIGTAG_RSAHEADER 19238 19239 The tag contains the RSA signature of the Header section.The data is 19240 formatted as a Version 3 Signature Packet as specified in RFC 2440: OpenPGP 19241 Message Format. If this tag is present, then the SIGTAG_PGP shall also be 19242 present. 19243 19244 ------------------------------------------------------------------------------- 19245 19246 Header Section 19247 19248 The Header section is implemented using the Header structure. The Header 19249 section defines the following additional tag values which may be used in the 19250 Index structures. 19251 19252 ------------------------------------------------------------------------------- 19253 19254 Package Information 19255 19256 The following tag values are used to indicate information that describes the 19257 package as a whole. 19258 19259 Table 1-8. Package Info Tag Values 19260 19261 +------------------------------------------------------------+ 19262 | Name |Tag Value| Type |Count| Status | 19263 |------------------------+---------+----------+-----+--------| 19264 |RPMTAG_NAME |1000 |STRING |1 |Required| 19265 |------------------------+---------+----------+-----+--------| 19266 |RPMTAG_VERSION |1001 |STRING |1 |Required| 19267 |------------------------+---------+----------+-----+--------| 19268 |RPMTAG_RELEASE |1002 |STRING |1 |Required| 19269 |------------------------+---------+----------+-----+--------| 19270 |RPMTAG_SUMMARY |1004 |I18NSTRING|1 |Required| 19271 |------------------------+---------+----------+-----+--------| 19272 |RPMTAG_DESCRIPTION |1005 |I18NSTRING|1 |Required| 19273 |------------------------+---------+----------+-----+--------| 19274 |RPMTAG_SIZE |1009 |INT32 |1 |Required| 19275 |------------------------+---------+----------+-----+--------| 19276 |RPMTAG_LICENSE |1014 |STRING |1 |Required| 19277 |------------------------+---------+----------+-----+--------| 19278 |RPMTAG_GROUP |1016 |I18NSTRING|1 |Required| 19279 |------------------------+---------+----------+-----+--------| 19280 |RPMTAG_OS |1021 |STRING |1 |Required| 19281 |------------------------+---------+----------+-----+--------| 19282 |RPMTAG_ARCH |1022 |STRING |1 |Required| 19283 |------------------------+---------+----------+-----+--------| 19284 |RPMTAG_SOURCERPM |1044 |STRING |1 |Optional| 19285 |------------------------+---------+----------+-----+--------| 19286 |RPMTAG_ARCHIVESIZE |1046 |INT32 |1 |Optional| 19287 |------------------------+---------+----------+-----+--------| 19288 |RPMTAG_RPMVERSION |1064 |STRING |1 |Optional| 19289 |------------------------+---------+----------+-----+--------| 19290 |RPMTAG_COOKIE |1094 |STRING |1 |Optional| 19291 |------------------------+---------+----------+-----+--------| 19292 |RPMTAG_PAYLOADFORMAT |1124 |STRING |1 |Required| 19293 |------------------------+---------+----------+-----+--------| 19294 |RPMTAG_PAYLOADCOMPRESSOR|1125 |STRING |1 |Required| 19295 |------------------------+---------+----------+-----+--------| 19296 |RPMTAG_PAYLOADFLAGS |1126 |STRING |1 |Required| 19297 +------------------------------------------------------------+ 19298 19299 RPMTAG_NAME 19300 19301 This tag specifies the name of the package. 19302 19303 RPMTAG_VERSION 19304 19305 This tag specifies the version of the package. 19306 19307 RPMTAG_RELEASE 19308 19309 This tag specifies the release of the package. 19310 19311 RPMTAG_SUMMARY 19312 19313 This tag specifies the summary description of the package. The summary 19314 value pointed to by this index record contains a one line description of 19315 the package. 19316 19317 RPMTAG_DESCRIPTION 19318 19319 This tag specifies the description of the package. The description value 19320 pointed to by this index record contains a full desription of the package. 19321 19322 RPMTAG_SIZE 19323 19324 This tag specifies the sum of the sizes of the regular files in the 19325 archive. 19326 19327 RPMTAG_LICENSE 19328 19329 This tag specifies the license which applies to this package. 19330 19331 RPMTAG_GROUP 19332 19333 This tag specifies the administrative group to which this package belongs. 19334 19335 RPMTAG_OS 19336 19337 This tag specifies the OS of the package. The OS value pointed to by this 19338 index record shall be "linux". 19339 19340 RPMTAG_ARCH 19341 19342 This tag specifies the architecture of the package. The architecture value 19343 pointed to by this index record is defined in architecture specific LSB 19344 specification. 19345 19346 RPMTAG_SOURCERPM 19347 19348 This tag specifies the name of the source RPM 19349 19350 RPMTAG_ARCHIVESIZE 19351 19352 This tag specifies the uncompressed size of the Payload archive, including 19353 the cpio headers. 19354 19355 RPMTAG_RPMVERSION 19356 19357 This tag indicates the version of RPM tool used to build this package. The 19358 value is unused. 19359 19360 RPMTAG_COOKIE 19361 19362 This tag contains an opaque string whose contents are undefined. 19363 19364 RPMTAG_PAYLOADFORMAT 19365 19366 This tag specifies the format of the Archive section. The format value 19367 pointed to by this index record shall be 'cpio'. 19368 19369 RPMTAG_PAYLOADCOMPRESSOR 19370 19371 This tag specifies the compression used on the Archive section. The 19372 compression value pointed to by this index record shall be 'gzip' 19373 19374 RPMTAG_PAYLOADFLAGS 19375 19376 This tag indicates the compression level used for the Payload. This value 19377 shall always be '9'. 19378 19379 ------------------------------------------------------------------------------- 19380 19381 Installation Information 19382 19383 The following tag values are used to provide information needed during the 19384 installation of the package. 19385 19386 Table 1-9. Installation Tag Values 19387 19388 +-------------------------------------------------+ 19389 | Name |Tag Value| Type |Count| Status | 19390 |-----------------+---------+------+-----+--------| 19391 |RPMTAG_PREIN |1023 |STRING|1 |Optional| 19392 |-----------------+---------+------+-----+--------| 19393 |RPMTAG_POSTIN |1024 |STRING|1 |Optional| 19394 |-----------------+---------+------+-----+--------| 19395 |RPMTAG_PREUN |1025 |STRING|1 |Optional| 19396 |-----------------+---------+------+-----+--------| 19397 |RPMTAG_POSTUN |1026 |STRING|1 |Optional| 19398 |-----------------+---------+------+-----+--------| 19399 |RPMTAG_PREINPROG |1085 |STRING|1 |Optional| 19400 |-----------------+---------+------+-----+--------| 19401 |RPMTAG_POSTINPROG|1086 |STRING|1 |Optional| 19402 |-----------------+---------+------+-----+--------| 19403 |RPMTAG_PREUNPROG |1087 |STRING|1 |Optional| 19404 |-----------------+---------+------+-----+--------| 19405 |RPMTAG_POSTUNPROG|1088 |STRING|1 |Optional| 19406 +-------------------------------------------------+ 19407 19408 RPMTAG_PREIN 19409 19410 This tag specifies the preinstall scriptlet. 19411 19412 RPMTAG_POSTIN 19413 19414 This tag specifies the postinstall scriptlet. 19415 19416 RPMTAG_PREUN 19417 19418 his tag specifies the preuninstall scriptlet. 19419 19420 RPMTAG_POSTUN 19421 19422 This tag specified the postuninstall scriptlet. 19423 19424 RPMTAG_PREINPROG 19425 19426 This tag specifies the name of the intepreter to which the preinstall 19427 scriptlet will be passed. The intepreter pointed to by this index record 19428 shall be '/bin/sh'. 19429 19430 RPMTAG_POSTINPROG 19431 19432 This tag specifies the name of the intepreter to which the postinstall 19433 scriptlet will be passed. The intepreter pointed to by this index record 19434 shall be '/bin/sh'. 19435 19436 RPMTAG_PREUNPROG 19437 19438 This tag specifies the name of the intepreter to which the preuninstall 19439 scriptlet will be passed. The intepreter pointed to by this index record 19440 shall be '/bin/sh'. 19441 19442 RPMTAG_POSTUNPROG 19443 19444 This program specifies the name of the intepreter to which the 19445 postuninstall scriptlet will be passed. The intepreter pointed to by this 19446 index record shall be '/bin/sh'. 19447 19448 ------------------------------------------------------------------------------- 19449 19450 File Information 19451 19452 The following tag values are used to provide information about the files in the 19453 payload. This information is provided in the header to allow more efficient 19454 access of the information. 19455 19456 Table 1-10. File Info Tag Values 19457 19458 +----------------------------------------------------------+ 19459 | Name |Tag Value| Type |Count| Status | 19460 |--------------------+---------+------------+-----+--------| 19461 |RPMTAG_OLDFILENAMES |1027 |STRING_ARRAY| |Optional| 19462 |--------------------+---------+------------+-----+--------| 19463 |RPMTAG_FILESIZES |1028 |INT32 | |Required| 19464 |--------------------+---------+------------+-----+--------| 19465 |RPMTAG_FILEMODES |1030 |INT16 | |Required| 19466 |--------------------+---------+------------+-----+--------| 19467 |RPMTAG_FILERDEVS |1033 |INT16 | |Required| 19468 |--------------------+---------+------------+-----+--------| 19469 |RPMTAG_FILEMTIMES |1034 |INT32 | |Required| 19470 |--------------------+---------+------------+-----+--------| 19471 |RPMTAG_FILEMD5S |1035 |STRING_ARRAY| |Required| 19472 |--------------------+---------+------------+-----+--------| 19473 |RPMTAG_FILELINKTOS |1036 |STRING_ARRAY| |Required| 19474 |--------------------+---------+------------+-----+--------| 19475 |RPMTAG_FILEFLAGS |1037 |INT32 | |Required| 19476 |--------------------+---------+------------+-----+--------| 19477 |RPMTAG_FILEUSERNAME |1039 |STRING_ARRAY| |Required| 19478 |--------------------+---------+------------+-----+--------| 19479 |RPMTAG_FILEGROUPNAME|1040 |STRING_ARRAY| |Required| 19480 |--------------------+---------+------------+-----+--------| 19481 |RPMTAG_FILEDEVICES |1095 |INT32 | |Required| 19482 |--------------------+---------+------------+-----+--------| 19483 |RPMTAG_FILEINODES |1096 |INT32 | |Required| 19484 |--------------------+---------+------------+-----+--------| 19485 |RPMTAG_FILELANGS |1097 |STRING_ARRAY| |Required| 19486 |--------------------+---------+------------+-----+--------| 19487 |RPMTAG_DIRINDEXES |1116 |INT32 | |Optional| 19488 |--------------------+---------+------------+-----+--------| 19489 |RPMTAG_BASENAMES |1117 |STRING_ARRAY| |Optional| 19490 |--------------------+---------+------------+-----+--------| 19491 |RPMTAG_DIRNAMES |1118 |STRING_ARRAY| |Optional| 19492 +----------------------------------------------------------+ 19493 19494 RPMTAG_OLDFILENAMES 19495 19496 This tag specifies the filenames when not in a compressed format as 19497 determined by the absense of rpmlib(CompressedFileNames) in the 19498 RPMTAG_REQUIRENAME index. 19499 19500 RPMTAG_FILESIZES 19501 19502 This tag specifies the size of each file in the archive. 19503 19504 RPMTAG_FILEMODES 19505 19506 This tag specifies the mode of each file in the archive. 19507 19508 RPMTAG_FILERDEVS 19509 19510 This tag specifies the device number from which the file was copied. 19511 19512 RPMTAG_FILEMTIMES 19513 19514 This tag specifies the modification time in seconds since the epoch of each 19515 file in the archive. 19516 19517 RPMTAG_FILEMD5S 19518 19519 This tag specifies the ASCII representation of the MD5 sum of the 19520 corresponding file contents. This value is empty if the corresponding 19521 archive entry is not a regular file. 19522 19523 RPMTAG_FILELINKTOS 19524 19525 The target for a symlink, otherwise NULL. 19526 19527 RPMTAG_FILEFLAGS 19528 19529 This tag specifies the bit(s) to classify and control how files are to be 19530 installed. 19531 19532 RPMTAG_FILEUSERNAME 19533 19534 This tag specifies the owner of the corresponding file. 19535 19536 RPMTAG_FILEGROUPNAME 19537 19538 This tag specifies the of the corresponding file. 19539 19540 RPMTAG_FILEDEVICES 19541 19542 This tag specifies the 16 bit device number from which the file was copied. 19543 19544 RPMTAG_FILEINODES 19545 19546 This tag specifies the inode value from the original file on the build 19547 host. 19548 19549 RPMTAG_FILELANGS 19550 19551 This tag specifies a per-file locale marker used to install only locale 19552 specific subsets of files when the package is installed. 19553 19554 RPMTAG_DIRINDEXES 19555 19556 This tag specifies the index into the array provided by the RPMTAG_DIRNAMES 19557 Index which contains the directory name for the corresponding filename. 19558 19559 RPMTAG_BASENAMES 19560 19561 This tag specifies the base portion of the corresponding filename. 19562 19563 RPMTAG_DIRNAMES 19564 19565 This tag specifies the directory portion of the corresponding filename. 19566 Each directory name shall contain a trailing '/'. 19567 19568 One of RPMTAG_OLDFILENAMES or the tuple 19569 RPMTAG_DIRINDEXES,RPMTAG_BASENAMES,RPMTAG_DIRNAMES shall be present, but not 19570 both. 19571 19572 ------------------------------------------------------------------------------- 19573 19574 Dependency Information 19575 19576 The following tag values are used to provide information about 19577 interdependencies between packages. 19578 19579 Table 1-11. Package Dependency Tag Values 19580 19581 +------------------------------------------------------------+ 19582 | Name |Tag Value| Type |Count| Status | 19583 |----------------------+---------+------------+-----+--------| 19584 |RPMTAG_PROVIDENAME |1047 |STRING_ARRAY|1 |Required| 19585 |----------------------+---------+------------+-----+--------| 19586 |RPMTAG_REQUIREFLAGS |1048 |INT32 | |Required| 19587 |----------------------+---------+------------+-----+--------| 19588 |RPMTAG_REQUIRENAME |1049 |STRING_ARRAY| |Required| 19589 |----------------------+---------+------------+-----+--------| 19590 |RPMTAG_REQUIREVERSION |1050 |STRING_ARRAY| |Required| 19591 |----------------------+---------+------------+-----+--------| 19592 |RPMTAG_CONFLICTFLAGS |1053 |INT32 | |Optional| 19593 |----------------------+---------+------------+-----+--------| 19594 |RPMTAG_CONFLICTNAME |1054 |STRING_ARRAY| |Optional| 19595 |----------------------+---------+------------+-----+--------| 19596 |RPMTAG_CONFLICTVERSION|1055 |STRING_ARRAY| |Optional| 19597 |----------------------+---------+------------+-----+--------| 19598 |RPMTAG_OBSOLETENAME |1090 |STRING_ARRAY| |Optional| 19599 |----------------------+---------+------------+-----+--------| 19600 |RPMTAG_PROVIDEFLAGS |1112 |INT32 | |Required| 19601 |----------------------+---------+------------+-----+--------| 19602 |RPMTAG_PROVIDEVERSION |1113 |STRING_ARRAY| |Required| 19603 |----------------------+---------+------------+-----+--------| 19604 |RPMTAG_OBSOLETEFLAGS |1114 |INT32 |1 |Optional| 19605 |----------------------+---------+------------+-----+--------| 19606 |RPMTAG_OBSOLETEVERSION|1115 |STRING_ARRAY| |Optional| 19607 +------------------------------------------------------------+ 19608 19609 RPMTAG_PROVIDENAME 19610 19611 This tag indicates the name of the dependency provided by this package. 19612 19613 RPMTAG_REQUIREFLAGS 19614 19615 Bits(s) to specify the dependency range and context. 19616 19617 RPMTAG_REQUIRENAME 19618 19619 This tag indicates the dependencies for this package. 19620 19621 RPMTAG_REQUIREVERSION 19622 19623 This tag indicates the versions associated with the values found in the 19624 RPMTAG_REQUIRENAME Index. 19625 19626 RPMTAG_CONFLICTFLAGS 19627 19628 Bits(s) to specify the conflict range and context. 19629 19630 RPMTAG_CONFLICTNAME 19631 19632 This tag indicates the conflictind dependencies for this package. 19633 19634 RPMTAG_CONFLICTVERSION 19635 19636 This tag indicates the versions associated with the values found in the 19637 RPMTAG_CONFLICTNAME Index. 19638 19639 RPMTAG_OBSOLETENAME 19640 19641 This tag indicates the obsoleted dependencies for this package. 19642 19643 RPMTAG_PROVIDEFLAGS 19644 19645 Bits(s) to specify the conflict range and context. 19646 19647 RPMTAG_PROVIDEVERSION 19648 19649 This tag indicates the versions associated with the values found in the 19650 RPMTAG_PROVIDENAME Index. 19651 19652 RPMTAG_OBSOLETEFLAGS 19653 19654 Bits(s) to specify the conflict range and context. 19655 19656 RPMTAG_OBSOLETEVERSION 19657 19658 This tag indicates the versions associated with the values found in the 19659 RPMTAG_OBSOLETENAME Index. 19660 19661 ------------------------------------------------------------------------------- 19662 19663 Package Dependency Values 19664 19665 The package dependencies are stored in the RPMTAG_REQUIRENAME and 19666 RPMTAG_REQUIREVERSION index records. The following values may be used. 19667 19668 Table 1-12. Index Type values 19669 19670 +-----------------------------------------------------------------------------+ 19671 | Name |Version| Meaning | Status | 19672 |------------------------+-------+-----------------------------------+--------| 19673 |lsb |2.0 |Indicates this is an LSB conforming|Required| 19674 | | |package. | | 19675 |------------------------+-------+-----------------------------------+--------| 19676 | | |Indicates That the package contains| | 19677 |rpmlib | |PMTAG_PROVIDENAME, | | 19678 |(VersionedDependencies) |3.0.3-1|RPMTAG_OBSOLETENAME or |Optional| 19679 | | |RPMTAG_PREREQ records that have a | | 19680 | | |version associated with them. | | 19681 |------------------------+-------+-----------------------------------+--------| 19682 |rpmlib | |Indicates the filenames in the | | 19683 |(PayloadFilesHavePrefix)|4.0-1 |Archive have had "." prepended to |Optional| 19684 | | |them. | | 19685 |------------------------+-------+-----------------------------------+--------| 19686 | | |Indicates that the filenames in the| | 19687 |rpmlib |3.0.4-1|Payload are represented in the |Optional| 19688 |(CompressedFileNames) | |RPMTAG_DIRINDEXES, RPMTAG_DIRNAME | | 19689 | | |and RPMTAG_BASENAMES indexes. | | 19690 |------------------------+-------+-----------------------------------+--------| 19691 |/bin/sh | |Interpreter usually required for |Optional| 19692 | | |installation scripts. | | 19693 +-----------------------------------------------------------------------------+ 19694 ------------------------------------------------------------------------------- 19695 19696 Package Dependencies Attributes 19697 19698 The package dependency attributes are stored in the RPMTAG_REQUIREFLAGS, 19699 RPMTAG_PROVIDEFLAGS and RPMTAG_OBSOLETEFLAGS index records. The following 19700 values may be used. 19701 19702 Table 1-13. Package Dependency Attributes 19703 19704 +----------------------------------------+ 19705 | Name | Value |Meaning| 19706 |----------------------+---------+-------| 19707 |RPMSENSE_LESS |0x02 | | 19708 |----------------------+---------+-------| 19709 |RPMSENSE_GREATER |0x04 | | 19710 |----------------------+---------+-------| 19711 |RPMSENSE_EQUAL |0x08 | | 19712 |----------------------+---------+-------| 19713 |RPMSENSE_PREREQ |0x40 | | 19714 |----------------------+---------+-------| 19715 |RPMSENSE_INTERP |0x100 | | 19716 |----------------------+---------+-------| 19717 |RPMSENSE_SCRIPT_PRE |0x200 | | 19718 |----------------------+---------+-------| 19719 |RPMSENSE_SCRIPT_POST |0x400 | | 19720 |----------------------+---------+-------| 19721 |RPMSENSE_SCRIPT_PREUN |0x800 | | 19722 |----------------------+---------+-------| 19723 |RPMSENSE_SCRIPT_POSTUN|0x1000 | | 19724 |----------------------+---------+-------| 19725 |RPMSENSE_RPMLIB |0x1000000| | 19726 +----------------------------------------+ 19727 ------------------------------------------------------------------------------- 19728 19729 Other Information 19730 19731 The following tag values are also found in the Header section. 19732 19733 Table 1-14. Other Tag Values 19734 19735 +--------------------------------------------------------------+ 19736 | Name |Tag Value| Type |Count| Status | 19737 |----------------------+---------+------------+-----+----------| 19738 |RPMTAG_BUILDTIME |1006 |INT32 |1 |Optional | 19739 |----------------------+---------+------------+-----+----------| 19740 |RPMTAG_BUILDHOST |1007 |STRING |1 |Optional | 19741 |----------------------+---------+------------+-----+----------| 19742 |RPMTAG_FILEVERIFYFLAGS|1045 |INT32 | |Optional | 19743 |----------------------+---------+------------+-----+----------| 19744 |RPMTAG_CHANGELOGTIME |1080 |INT32 | |Optional | 19745 |----------------------+---------+------------+-----+----------| 19746 |RPMTAG_CHANGELOGNAME |1081 |STRING_ARRAY| |Optional | 19747 |----------------------+---------+------------+-----+----------| 19748 |RPMTAG_CHANGELOGTEXT |1082 |STRING_ARRAY| |Optional | 19749 |----------------------+---------+------------+-----+----------| 19750 |RPMTAG_OPTFLAGS |1122 |STRING |1 |Optional | 19751 |----------------------+---------+------------+-----+----------| 19752 |RPMTAG_RHNPLATFORM |1131 |STRING |1 |Deprecated| 19753 |----------------------+---------+------------+-----+----------| 19754 |RPMTAG_PLATFORM |1132 |STRING |1 |Optional | 19755 +--------------------------------------------------------------+ 19756 19757 RPMTAG_BUILDTIME 19758 19759 This tag specifies the time as seconds since the epoch at which the package 19760 was built. 19761 19762 RPMTAG_BUILDHOST 19763 19764 This tag specifies the on which which the package was built. 19765 19766 RPMTAG_FILEVERIFYFLAGS 19767 19768 This tag specifies the bit(s) to control how files are to be verified after 19769 install, specifying which checks should be performed. 19770 19771 RPMTAG_CHANGELOGTIME 19772 19773 This tag specifies the Unix time in seconds since the epoch associated with 19774 each entry in the Changelog file. 19775 19776 RPMTAG_CHANGELOGNAME 19777 19778 This tag specifies the name of who made a change to this package 19779 19780 RPMTAG_CHANGELOGTEXT 19781 19782 This tag specifies the changes asssociated with a changelog entry. 19783 19784 RPMTAG_OPTFLAGS 19785 19786 This tag indicates additional flags which may have been passed to the 19787 compiler when building this package. 19788 19789 RPMTAG_RHNPLATFORM 19790 19791 This tag contains an opaque string whose contents are undefined. 19792 19793 RPMTAG_PLATFORM 19794 19795 This tag contains an opaque string whose contents are undefined. 19796 19797 ------------------------------------------------------------------------------- 19798 19799 Payload Section 19800 19801 The Payload section contains a compressed cpio archive. The format of this 19802 section is defined by RFC 1952: GZIP File Format Specification. 19803 19804 When uncompressed, the cpio archive contains a sequence of records for each 19805 file. Each record contains a CPIO Header, Filename, Padding, and File Data. 19806 19807 Table 1-15. CPIO File Format 19808 19809 +-----------------------------------------------------------------------------+ 19810 |CPIO Header|Header structure as defined below. | 19811 |-----------+-----------------------------------------------------------------| 19812 |Filename |NUL terminated ASCII string containing the name of the file. | 19813 |-----------+-----------------------------------------------------------------| 19814 |Padding |0-3 bytes as needed to align the file stream to a 4 byte | 19815 | |boundary. | 19816 |-----------+-----------------------------------------------------------------| 19817 |File data |The contents of the file. | 19818 |-----------+-----------------------------------------------------------------| 19819 |Padding |0-3 bytes as needed to align the file stream to a 4 byte | 19820 | |boundary. | 19821 +-----------------------------------------------------------------------------+ 19822 19823 The CPIO Header uses the following header structure (sometimes referred to as 19824 "new ASCII" or "SVR4 cpio"). All numbers are stored as ASCII representations of 19825 their hexadecimal value with leading zeros as needed to fill the field. With 19826 the exception of c_namesize and the corresponding name string, and c_checksum, 19827 all information contained in the CPIO Header is also represented in the Header 19828 Section. The values in in the CPIO Header shall match the values contained in 19829 the Header Section. 19830 19831 struct { 19832 char c_magic[6]; 19833 char c_ino[8]; 19834 char c_mode[8]; 19835 char c_uid[8]; 19836 char c_gid[8]; 19837 char c_nlink[8]; 19838 char c_mtime[8]; 19839 char c_filesize[8]; 19840 char c_devmajor[8]; 19841 char c_devminor[8]; 19842 char c_rdevmajor[8]; 19843 char c_rdevminor[8]; 19844 char c_namesize[8]; 19845 char c_checksum[8]; 19846 }; 19847 19848 c_magic 19849 19850 Value identifying this cpio format. This value shall be "070701". 19851 19852 c_ino 19853 19854 This field contains the inode number from the filesystem from which the 19855 file was read. This field is ignored when installing a package. This field 19856 shall match the corresponding value in the RPMTAG_FILEINODES index in the 19857 Header section. 19858 19859 c_mode 19860 19861 Permission bits of the file. This is an ascii representation of the 19862 hexadecimal number representing the bit as defined for the st_mode field of 19863 the stat structure defined for the stat function. This field shall match 19864 the corresponding value in the RPMTAG_FILEMODES index in the Header 19865 section. 19866 19867 c_uid 19868 19869 Value identifying this owner of this file. This value matches the uid value 19870 of the corresponding user in the RPMTAG_FILEUSERNAME as found on the system 19871 where this package was built. The username specified in RPMTAG_FILEUSERNAME 19872 should take precedence when installing the package. 19873 19874 c_gid 19875 19876 Value identifying this group of this file. This value matches the gid value 19877 of the corresponding user in the RPMTAG_FILEGROUPNAME as found on the 19878 system where this package was built. The groupname specified in 19879 RPMTAG_FILEGROUPNAME should take precedence when installing the package. 19880 19881 c_nlink 19882 19883 Value identifying the number of links associated with this file. If the 19884 value is greater than 1, then this filename will be linked to 1 or more 19885 files in this archive that has a matching value for the c_ino, c_devmajor 19886 and c_devminor fields. 19887 19888 c_mtime 19889 19890 Value identifying the modification time of the file when it was read. This 19891 field shall match the corresponding value in the RPMTAG_FILEMTIMES index in 19892 the Header section. 19893 19894 c_filesize 19895 19896 Value identifying the size of the file. This field shall match the 19897 corresponding value in the RPMTAG_FILESIZES index in the Header section. 19898 19899 c_devmajor 19900 19901 The major number of the device containing the file system from which the 19902 file was read. With the exception of processing files with c_nlink >1, this 19903 field is ignored when installing a package. This field shall match the 19904 corresponding value in the RPMTAG_FILEDEVICES index in the Header section. 19905 19906 c_devminor 19907 19908 The minor number of the device containing the file system from which the 19909 file was read. With the exception of processing files with c_nlink >1, this 19910 field is ignored when installing a package. This field shall match the 19911 corresponding value in the RPMTAG_FILEDEVICES index in the Header section. 19912 19913 c_rdevmajor 19914 19915 The major number of the raw device containing the file system from which 19916 the file was read. This field is ignored when installing a package. This 19917 field shall match the corresponding value in the RPMTAG_RDEVS index in the 19918 Header section. 19919 19920 c_rdevminor 19921 19922 The minor number of the raw device containing the file system from which 19923 the file was read. This field is ignored when installing a package. This 19924 field shall match the corresponding value in the RPMTAG_RDEVS index in the 19925 Header section. 19926 19927 c_namesize 19928 19929 Value identifying the length of the filename, which is located immediately 19930 following the CPIO Header structure. 19931 19932 c_checksum 19933 19934 Value containing the CRC checksum of the file data. This field is not used, 19935 and shall contain the value "00000000". This field is ignored when 19936 installing a package. 19937 19938 A record with the filename "TRAILER!!!" indicates the last record in the 19939 archive. 19940 19941 ------------------------------------------------------------------------------- 19942 19943 Package Script Restrictions 19944 19945 Scripts used as part of the package install and uninstall shall only use 19946 commands and interfaces that are specified by the LSB. All other commands are 19947 not guaranteed to be present, or to behave in expected ways. 19948 19949 Packages shall not use RPM triggers. 19950 19951 Packages shall not depend on the order in which scripts are executed 19952 (pre-install, pre-uninstall, &c), when doing an upgrade. 19953 19954 ------------------------------------------------------------------------------- 19955 19956 Package Tools 19957 19958 The LSB does not specify the interface to the tools used to manipulate 19959 LSB-conformant packages. Each conforming distribution shall provide 19960 documentation for installing LSB packages. 19961 19962 ------------------------------------------------------------------------------- 19963 19964 Package Naming 19965 19966 Packages supplied by distributions and applications must follow the following 19967 rules for the name field within the package. These rules are not required for 19968 the filename of the package file itself.[14] 19969 19970 The following rules apply to the name field alone, not including any release or 19971 version.[15] 19972 19973 * If the name begins with "lsb-" and contains no other hyphens, the name 19974 shall be assigned by the Linux Assigned Names and Numbers Authority 19975 (LANANA), which shall maintain a registry of LSB names. The name may be 19976 registered by either a distribution or an application. 19977 19978 * If the package name begins with "lsb-" and contains more than one hyphen 19979 (for example "lsb-distro.example.com-database" or "lsb-gnome-gnumeric"), 19980 then the portion of the package name between first and second hyphens shall 19981 either be an LSB provider name assigned by the LANANA, or it may be one of 19982 the owners' fully-qualified domain names in lower case (e.g., "debian.org", 19983 "staroffice.sun.com"). The LSB provider name assigned by LANANA shall only 19984 consist of the ASCII characters [a-z0-9]. The provider name or domain name 19985 may be either that of a distribution or an application. 19986 19987 * Package names containing no hyphens are reserved for use by distributions. 19988 Applications must not use such names.[16] 19989 19990 * Package names which do not start with "lsb-" and which contain a hyphen 19991 are open to both distributions and applications. Distributions may name 19992 packages in any part of this namespace. They are encouraged to use names 19993 from one of the other namespaces available to them, but this is not 19994 required due to the large amount of current practice to the contrary.[17] 19995 Applications may name their packages this way, but only if the portion of 19996 the name before the first hyphen is a provider name or registered domain 19997 name as described above.[18]Note that package names in this namespace are 19998 available to both the distribution and an application. Distributions and 19999 applications will need to consider this potential for conflicts when 20000 deciding to use these names rather than the alternatives (such as names 20001 starting with "lsb-"). 20002 20003 ------------------------------------------------------------------------------- 20004 20005 Package Dependencies 20006 20007 Packages shall have a dependency that indicates which LSB modules are required. 20008 LSB module descriptions are dash seperated tuples containing the name 'lsb', 20009 the module name, and the architecture name. The following dependencies may be 20010 used. 20011 20012 lsb-core-arch 20013 20014 This dependency is used to indicate that the application is dependent on 20015 features contained in the LSB-Core specification. 20016 20017 lsb-core-noarch 20018 20019 This dependency is used to indicate that the application is dependent on 20020 features contained in the LSB-Core specification and that the package does 20021 not contain any architecture specific files. 20022 20023 Packages shall not depend on other system-provided dependencies. They shall not 20024 depend on non-system-provided dependencies unless those dependencies are 20025 fulfilled by packages which are part of the same application. A package may 20026 only provide a virtual package name which is registered to that application. 20027 20028 Other modules in the LSB may supplement this list. The architecture specific 20029 dependencies are described in the relevant architecture specific LSB. 20030 20031 ------------------------------------------------------------------------------- 20032 20033 Package Architecture Considerations 20034 20035 Packages which do not contain any architecture specific files must specify an 20036 architecture of noarch. A LSB runtime environment must accept values noarch, or 20037 the value specified in the architecture specific supplement. 20038 20039 Additional specifications or restrictions may be found in the architecture 20040 specific LSB specification. 20041 20042 Free Documentation License 20043 20044 ------------------------------------------------------------------------------- 20045 20046 Table of Contents 20047 A. GNU Free Documentation License 20048 20049 PREAMBLE 20050 APPLICABILITY AND DEFINITIONS 20051 VERBATIM COPYING 20052 COPYING IN QUANTITY 20053 MODIFICATIONS 20054 COMBINING DOCUMENTS 20055 COLLECTIONS OF DOCUMENTS 20056 AGGREGATION WITH INDEPENDENT WORKS 20057 TRANSLATION 20058 TERMINATION 20059 FUTURE REVISIONS OF THIS LICENSE 20060 How to use this License for your documents 20061 20062 ------------------------------------------------------------------------------- 20063 20064 Appendix A. GNU Free Documentation License 20065 20066 Version 1.1, March 2000 20067 20068 Copyright (C) 2000 Free Software Foundation, Inc. 59 Temple Place, Suite 20069 330, Boston, MA 02111-1307 USA Everyone is permitted to copy and distribute 20070 verbatim copies of this license document, but changing it is not allowed. 20071 20072 ------------------------------------------------------------------------------- 20073 20074 PREAMBLE 20075 20076 The purpose of this License is to make a manual, textbook, or other written 20077 document "free" in the sense of freedom: to assure everyone the effective 20078 freedom to copy and redistribute it, with or without modifying it, either 20079 commercially or noncommercially. Secondarily, this License preserves for the 20080 author and publisher a way to get credit for their work, while not being 20081 considered responsible for modifications made by others. 20082 20083 This License is a kind of "copyleft", which means that derivative works of the 20084 document must themselves be free in the same sense. It complements the GNU 20085 General Public License, which is a copyleft license designed for free software. 20086 20087 We have designed this License in order to use it for manuals for free software, 20088 because free software needs free documentation: a free program should come with 20089 manuals providing the same freedoms that the software does. But this License is 20090 not limited to software manuals; it can be used for any textual work, 20091 regardless of subject matter or whether it is published as a printed book. We 20092 recommend this License principally for works whose purpose is instruction or 20093 reference. 20094 20095 ------------------------------------------------------------------------------- 20096 20097 APPLICABILITY AND DEFINITIONS 20098 20099 This License applies to any manual or other work that contains a notice placed 20100 by the copyright holder saying it can be distributed under the terms of this 20101 License. The "Document", below, refers to any such manual or work. Any member 20102 of the public is a licensee, and is addressed as "you". 20103 20104 A "Modified Version" of the Document means any work containing the Document or 20105 a portion of it, either copied verbatim, or with modifications and/or 20106 translated into another language. 20107 20108 A "Secondary Section" is a named appendix or a front-matter section of the 20109 Document that deals exclusively with the relationship of the publishers or 20110 authors of the Document to the Document's overall subject (or to related 20111 matters) and contains nothing that could fall directly within that overall 20112 subject. (For example, if the Document is in part a textbook of mathematics, a 20113 Secondary Section may not explain any mathematics.) The relationship could be a 20114 matter of historical connection with the subject or with related matters, or of 20115 legal, commercial, philosophical, ethical or political position regarding them. 20116 20117 The "Invariant Sections" are certain Secondary Sections whose titles are 20118 designated, as being those of Invariant Sections, in the notice that says that 20119 the Document is released under this License. 20120 20121 The "Cover Texts" are certain short passages of text that are listed, as 20122 Front-Cover Texts or Back-Cover Texts, in the notice that says that the 20123 Document is released under this License. 20124 20125 A "Transparent" copy of the Document means a machine-readable copy, represented 20126 in a format whose specification is available to the general public, whose 20127 contents can be viewed and edited directly and straightforwardly with generic 20128 text editors or (for images composed of pixels) generic paint programs or (for 20129 drawings) some widely available drawing editor, and that is suitable for input 20130 to text formatters or for automatic translation to a variety of formats 20131 suitable for input to text formatters. A copy made in an otherwise Transparent 20132 file format whose markup has been designed to thwart or discourage subsequent 20133 modification by readers is not Transparent. A copy that is not "Transparent" is 20134 called "Opaque". 20135 20136 Examples of suitable formats for Transparent copies include plain ASCII without 20137 markup, Texinfo input format, LaTeX input format, SGML or XML using a publicly 20138 available DTD, and standard-conforming simple HTML designed for human 20139 modification. Opaque formats include PostScript, PDF, proprietary formats that 20140 can be read and edited only by proprietary word processors, SGML or XML for 20141 which the DTD and/or processing tools are not generally available, and the 20142 machine-generated HTML produced by some word processors for output purposes 20143 only. 20144 20145 The "Title Page" means, for a printed book, the title page itself, plus such 20146 following pages as are needed to hold, legibly, the material this License 20147 requires to appear in the title page. For works in formats which do not have 20148 any title page as such, "Title Page" means the text near the most prominent 20149 appearance of the work's title, preceding the beginning of the body of the 20150 text. 20151 20152 ------------------------------------------------------------------------------- 20153 20154 VERBATIM COPYING 20155 20156 You may copy and distribute the Document in any medium, either commercially or 20157 noncommercially, provided that this License, the copyright notices, and the 20158 license notice saying this License applies to the Document are reproduced in 20159 all copies, and that you add no other conditions whatsoever to those of this 20160 License. You may not use technical measures to obstruct or control the reading 20161 or further copying of the copies you make or distribute. However, you may 20162 accept compensation in exchange for copies. If you distribute a large enough 20163 number of copies you must also follow the conditions in section 3. 20164 20165 You may also lend copies, under the same conditions stated above, and you may 20166 publicly display copies. 20167 20168 ------------------------------------------------------------------------------- 20169 20170 COPYING IN QUANTITY 20171 20172 If you publish printed copies of the Document numbering more than 100, and the 20173 Document's license notice requires Cover Texts, you must enclose the copies in 20174 covers that carry, clearly and legibly, all these Cover Texts: Front-Cover 20175 Texts on the front cover, and Back-Cover Texts on the back cover. Both covers 20176 must also clearly and legibly identify you as the publisher of these copies. 20177 The front cover must present the full title with all words of the title equally 20178 prominent and visible. You may add other material on the covers in addition. 20179 Copying with changes limited to the covers, as long as they preserve the title 20180 of the Document and satisfy these conditions, can be treated as verbatim 20181 copying in other respects. 20182 20183 If the required texts for either cover are too voluminous to fit legibly, you 20184 should put the first ones listed (as many as fit reasonably) on the actual 20185 cover, and continue the rest onto adjacent pages. 20186 20187 If you publish or distribute Opaque copies of the Document numbering more than 20188 100, you must either include a machine-readable Transparent copy along with 20189 each Opaque copy, or state in or with each Opaque copy a publicly-accessible 20190 computer-network location containing a complete Transparent copy of the 20191 Document, free of added material, which the general network-using public has 20192 access to download anonymously at no charge using public-standard network 20193 protocols. If you use the latter option, you must take reasonably prudent 20194 steps, when you begin distribution of Opaque copies in quantity, to ensure that 20195 this Transparent copy will remain thus accessible at the stated location until 20196 at least one year after the last time you distribute an Opaque copy (directly 20197 or through your agents or retailers) of that edition to the public. 20198 20199 It is requested, but not required, that you contact the authors of the Document 20200 well before redistributing any large number of copies, to give them a chance to 20201 provide you with an updated version of the Document. 20202 20203 ------------------------------------------------------------------------------- 20204 20205 MODIFICATIONS 20206 20207 You may copy and distribute a Modified Version of the Document under the 20208 conditions of sections 2 and 3 above, provided that you release the Modified 20209 Version under precisely this License, with the Modified Version filling the 20210 role of the Document, thus licensing distribution and modification of the 20211 Modified Version to whoever possesses a copy of it. In addition, you must do 20212 these things in the Modified Version: 20213 20214 A. Use in the Title Page (and on the covers, if any) a title distinct from 20215 that of the Document, and from those of previous versions (which should, if 20216 there were any, be listed in the History section of the Document). You may 20217 use the same title as a previous version if the original publisher of that 20218 version gives permission. 20219 20220 B. List on the Title Page, as authors, one or more persons or entities 20221 responsible for authorship of the modifications in the Modified Version, 20222 together with at least five of the principal authors of the Document (all 20223 of its principal authors, if it has less than five). 20224 20225 C. State on the Title page the name of the publisher of the Modified Version, 20226 as the publisher. 20227 20228 D. Preserve all the copyright notices of the Document. 20229 20230 E. Add an appropriate copyright notice for your modifications adjacent to the 20231 other copyright notices. 20232 20233 F. Include, immediately after the copyright notices, a license notice giving 20234 the public permission to use the Modified Version under the terms of this 20235 License, in the form shown in the Addendum below. 20236 20237 G. Preserve in that license notice the full lists of Invariant Sections and 20238 required Cover Texts given in the Document's license notice. 20239 20240 H. Include an unaltered copy of this License. 20241 20242 I. Preserve the section entitled "History", and its title, and add to it an 20243 item stating at least the title, year, new authors, and publisher of the 20244 Modified Version as given on the Title Page. If there is no section 20245 entitled "History" in the Document, create one stating the title, year, 20246 authors, and publisher of the Document as given on its Title Page, then add 20247 an item describing the Modified Version as stated in the previous sentence. 20248 20249 J. Preserve the network location, if any, given in the Document for public 20250 access to a Transparent copy of the Document, and likewise the network 20251 locations given in the Document for previous versions it was based on. 20252 These may be placed in the "History" section. You may omit a network 20253 location for a work that was published at least four years before the 20254 Document itself, or if the original publisher of the version it refers to 20255 gives permission. 20256 20257 K. In any section entitled "Acknowledgements" or "Dedications", preserve the 20258 section's title, and preserve in the section all the substance and tone of 20259 each of the contributor acknowledgements and/or dedications given therein. 20260 20261 L. Preserve all the Invariant Sections of the Document, unaltered in their 20262 text and in their titles. Section numbers or the equivalent are not 20263 considered part of the section titles. 20264 20265 M. Delete any section entitled "Endorsements". Such a section may not be 20266 included in the Modified Version. 20267 20268 N. Do not retitle any existing section as "Endorsements" or to conflict in 20269 title with any Invariant Section. 20270 20271 If the Modified Version includes new front-matter sections or appendices that 20272 qualify as Secondary Sections and contain no material copied from the Document, 20273 you may at your option designate some or all of these sections as invariant. To 20274 do this, add their titles to the list of Invariant Sections in the Modified 20275 Version's license notice. These titles must be distinct from any other section 20276 titles. 20277 20278 You may add a section entitled "Endorsements", provided it contains nothing but 20279 endorsements of your Modified Version by various parties--for example, 20280 statements of peer review or that the text has been approved by an organization 20281 as the authoritative definition of a standard. 20282 20283 You may add a passage of up to five words as a Front-Cover Text, and a passage 20284 of up to 25 words as a Back-Cover Text, to the end of the list of Cover Texts 20285 in the Modified Version. Only one passage of Front-Cover Text and one of 20286 Back-Cover Text may be added by (or through arrangements made by) any one 20287 entity. If the Document already includes a cover text for the same cover, 20288 previously added by you or by arrangement made by the same entity you are 20289 acting on behalf of, you may not add another; but you may replace the old one, 20290 on explicit permission from the previous publisher that added the old one. 20291 20292 The author(s) and publisher(s) of the Document do not by this License give 20293 permission to use their names for publicity for or to assert or imply 20294 endorsement of any Modified Version. 20295 20296 ------------------------------------------------------------------------------- 20297 20298 COMBINING DOCUMENTS 20299 20300 You may combine the Document with other documents released under this License, 20301 under the terms defined in section 4 above for modified versions, provided that 20302 you include in the combination all of the Invariant Sections of all of the 20303 original documents, unmodified, and list them all as Invariant Sections of your 20304 combined work in its license notice. 20305 20306 The combined work need only contain one copy of this License, and multiple 20307 identical Invariant Sections may be replaced with a single copy. If there are 20308 multiple Invariant Sections with the same name but different contents, make the 20309 title of each such section unique by adding at the end of it, in parentheses, 20310 the name of the original author or publisher of that section if known, or else 20311 a unique number. Make the same adjustment to the section titles in the list of 20312 Invariant Sections in the license notice of the combined work. 20313 20314 In the combination, you must combine any sections entitled "History" in the 20315 various original documents, forming one section entitled "History"; likewise 20316 combine any sections entitled "Acknowledgements", and any sections entitled 20317 "Dedications". You must delete all sections entitled "Endorsements." 20318 20319 ------------------------------------------------------------------------------- 20320 20321 COLLECTIONS OF DOCUMENTS 20322 20323 You may make a collection consisting of the Document and other documents 20324 released under this License, and replace the individual copies of this License 20325 in the various documents with a single copy that is included in the collection, 20326 provided that you follow the rules of this License for verbatim copying of each 20327 of the documents in all other respects. 20328 20329 You may extract a single document from such a collection, and distribute it 20330 individually under this License, provided you insert a copy of this License 20331 into the extracted document, and follow this License in all other respects 20332 regarding verbatim copying of that document. 20333 20334 ------------------------------------------------------------------------------- 20335 20336 AGGREGATION WITH INDEPENDENT WORKS 20337 20338 A compilation of the Document or its derivatives with other separate and 20339 independent documents or works, in or on a volume of a storage or distribution 20340 medium, does not as a whole count as a Modified Version of the Document, 20341 provided no compilation copyright is claimed for the compilation. Such a 20342 compilation is called an "aggregate", and this License does not apply to the 20343 other self-contained works thus compiled with the Document, on account of their 20344 being thus compiled, if they are not themselves derivative works of the 20345 Document. 20346 20347 If the Cover Text requirement of section 3 is applicable to these copies of the 20348 Document, then if the Document is less than one quarter of the entire 20349 aggregate, the Document's Cover Texts may be placed on covers that surround 20350 only the Document within the aggregate. Otherwise they must appear on covers 20351 around the whole aggregate. 20352 20353 ------------------------------------------------------------------------------- 20354 20355 TRANSLATION 20356 20357 Translation is considered a kind of modification, so you may distribute 20358 translations of the Document under the terms of section 4. Replacing Invariant 20359 Sections with translations requires special permission from their copyright 20360 holders, but you may include translations of some or all Invariant Sections in 20361 addition to the original versions of these Invariant Sections. You may include 20362 a translation of this License provided that you also include the original 20363 English version of this License. In case of a disagreement between the 20364 translation and the original English version of this License, the original 20365 English version will prevail. 20366 20367 ------------------------------------------------------------------------------- 20368 20369 TERMINATION 20370 20371 You may not copy, modify, sublicense, or distribute the Document except as 20372 expressly provided for under this License. Any other attempt to copy, modify, 20373 sublicense or distribute the Document is void, and will automatically terminate 20374 your rights under this License. However, parties who have received copies, or 20375 rights, from you under this License will not have their licenses terminated so 20376 long as such parties remain in full compliance. 20377 20378 ------------------------------------------------------------------------------- 20379 20380 FUTURE REVISIONS OF THIS LICENSE 20381 20382 The Free Software Foundation may publish new, revised versions of the GNU Free 20383 Documentation License from time to time. Such new versions will be similar in 20384 spirit to the present version, but may differ in detail to address new problems 20385 or concerns. See http://www.gnu.org/copyleft/. 20386 20387 Each version of the License is given a distinguishing version number. If the 20388 Document specifies that a particular numbered version of this License "or any 20389 later version" applies to it, you have the option of following the terms and 20390 conditions either of that specified version or of any later version that has 20391 been published (not as a draft) by the Free Software Foundation. If the 20392 Document does not specify a version number of this License, you may choose any 20393 version ever published (not as a draft) by the Free Software Foundation. 20394 20395 ------------------------------------------------------------------------------- 20396 20397 How to use this License for your documents 20398 20399 To use this License in a document you have written, include a copy of the 20400 License in the document and put the following copyright and license notices 20401 just after the title page: 20402 20403 Copyright (c) YEAR YOUR NAME. Permission is granted to copy, distribute and 20404 /or modify this document under the terms of the GNU Free Documentation 20405 License, Version 1.1 or any later version published by the Free Software 20406 Foundation; with the Invariant Sections being LIST THEIR TITLES, with the 20407 Front-Cover Texts being LIST, and with the Back-Cover Texts being LIST. A 20408 copy of the license is included in the section entitled "GNU Free 20409 Documentation License". 20410 20411 If you have no Invariant Sections, write "with no Invariant Sections" instead 20412 of saying which ones are invariant. If you have no Front-Cover Texts, write "no 20413 Front-Cover Texts" instead of "Front-Cover Texts being LIST"; likewise for 20414 Back-Cover Texts. 20415 20416 If your document contains nontrivial examples of program code, we recommend 20417 releasing these examples in parallel under your choice of free software 20418 license, such as the GNU General Public License, to permit their use in free 20419 software. 20420 20421 Notes 20422 20423 [1] Future versions of this specification might define additional service 20424 names. 20425 20426 [2] This specification does not require, but is designed to allow, the 20427 development of a system which runs boot scripts in parallel. Hence, 20428 enforced-serialization of scripts is avoided unless it is explicitly 20429 necessary. 20430 20431 [3] More than one space, or a tab character, indicates the continuation line. 20432 20433 [4] For example, if you want a service to run in runlevels 3, 4, and 5 (only), 20434 specify "Default-Start: 3 4 5" and "Default-Stop: 0 1 2 6". 20435 20436 [5] For example, install_initd might create symbolic links in /etc/rc2.d and 20437 other such directories which point to the files in /etc/init.d (or it 20438 might update a database, or some other mechanism). The init.d files 20439 themselves should already be in /etc/init.d before running install_initd. 20440 20441 [6] The dollar sign does not indicate variable expansion as in many Linux 20442 utilities. Starting a facility name with a dollar sign is merely a way of 20443 dividing the namespace between the system and applications. 20444 20445 [7] For example, daemons to query DNS, NIS+, or LDAP 20446 20447 [8] as defined in RFC 1833 20448 20449 [9] In some LSB run-time environments, filesystems such as /usr may be remote. 20450 Many applications that require $local_fs will probably require also 20451 require $remote_fs 20452 20453 [10] i.e., using a network-based time program such as ntp or rdate, or via the 20454 hardware Real Time Clock 20455 20456 [11] This note is only informative. Commonly used methods check either for the 20457 existence of the /proc/pid directory or use /proc/pid/exe and /proc/pid/ 20458 cmdline. Relying only on /proc/pid/exe is discouraged since this results 20459 in a not-running status for daemons that are written in a script language. 20460 20461 [12] Supplying an RPM format package is encouraged because it makes systems 20462 easier to manage. A future version of the LSB may require RPM, or specify 20463 a way for an installer to update a package database. 20464 20465 Applications are also encouraged to uninstall cleanly. 20466 20467 [13] The distribution itself may use a different packaging format for its own 20468 packages, and of course it may use any available mechanism for installing 20469 the LSB-conformant packages. 20470 20471 [14] For example, there are discrepancies among distributions concerning 20472 whether the name might be frobnicator-1.7-21-ppc32.rpm or 20473 frobnicator-1.7-21-powerpc32.rpm. The architecture aside, recommended 20474 practice is for the filename of the package file to match the name within 20475 the package. 20476 20477 [15] For example, if the name with the release and version is 20478 frobnicator-1.7-21, the name part is frobnicator and falls under the rules 20479 for a name with no hyphens. 20480 20481 [16] For example, "frobnicator". 20482 20483 [17] For example, ssh-common, ssh-client, kernel-pcmcia, and the like. Possible 20484 alternative names include sshcommon, foolinux-ssh-common (where foolinux 20485 is registered to the distribution), or lsb-foolinux-ssh-common. 20486 20487 [18] For example, if an application vendor has domain name visicalc.example.com 20488 and has registered visicalc as a provider name, they might name packages 20489 visicalc-base, visicalc.example.com-charting, and the like. 20490