Linux Standard Base Core Specification 4.0
Linux Standard Base Core Specification 4.0
ISO/IEC 23360 Part 1:2008(E)
Copyright © 2008 Linux Foundation
Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free
Documentation License, Version 1.1; with no Invariant Sections, with no Front-Cover Texts, and with no Back-
Cover Texts. A copy of the license is included in the section entitled "GNU Free Documentation License".
Portions of the text may be copyrighted by the following parties:
• The Regents of the University of California
• Free Software Foundation
• Ian F. Darwin
• Paul Vixie
• BSDI (now Wind River)
• Andrew G Morgan
• Jean-loup Gailly and Mark Adler
• Massachusetts Institute of Technology
• Apple Inc.
• Easy Software Products
• artofcode LLC
• Till Kamppeter
• Manfred Wassman
• Python Software Foundation
These excerpts are being used in accordance with their respective licenses.
Linux is the registered trademark of Linus Torvalds in the U.S. and other countries.
UNIX is a registered trademark of The Open Group.
LSB is a trademark of the Linux Foundation in the United States and other countries.
AMD is a trademark of Advanced Micro Devices, Inc.
Intel and Itanium are registered trademarks and Intel386 is a trademark of Intel Corporation.
PowerPC is a registered trademark and PowerPC Architecture is a trademark of the IBM Corporation.
S/390 is a registered trademark of the IBM Corporation.
OpenGL is a registered trademark of Silicon Graphics, Inc.
ISO/IEC 23360 Part 1:2008(E)
Contents
I Introductory Elements..................................................................................................
1 Scope.......................................................................................................................
1.1 General......................................................................................................
1.2 Module Specific Scope............................................................................
2 References..............................................................................................................
2.1 Normative References.............................................................................
2.2 Informative References/Bibliography..................................................
3 Requirements........................................................................................................
3.1 Relevant Libraries....................................................................................
3.2 LSB Implementation Conformance.......................................................
3.3 LSB Application Conformance..............................................................
4 Definitions.............................................................................................................
5 Terminology..........................................................................................................
6 Documentation Conventions..............................................................................
7 Relationship To ISO/IEC 9945 POSIX...............................................................
8 Relationship To Other Linux Foundation Specifications...............................
II Executable And Linking Format (ELF)....................................................................
9 Introduction...........................................................................................................
10 Low Level System Information........................................................................
10.1 Operating System Interface..................................................................
10.2 Machine Interface...................................................................................
11 Object Format......................................................................................................
11.1 Object Files..............................................................................................
11.2 Sections....................................................................................................
11.3 Special Sections......................................................................................
11.4 Symbol Mapping....................................................................................
11.5 DWARF Extensions...............................................................................
11.6 Exception Frames...................................................................................
11.7 Symbol Versioning.................................................................................
11.8 ABI note tag............................................................................................
12 Dynamic Linking................................................................................................
12.1 Program Loading and Dynamic Linking...........................................
12.2 Program Header.....................................................................................
12.3 Dynamic Entries.....................................................................................
III Base Libraries..............................................................................................................
13 Base Libraries......................................................................................................
13.1 Introduction............................................................................................
13.2 Program Interpreter...............................................................................
13.3 Interfaces for libc....................................................................................
13.4 Data Definitions for libc........................................................................
13.5 Interface Definitions for libc.................................................................
13.6 Interfaces for libm..................................................................................
13.7 Data Definitions for libm......................................................................
13.8 Interface Definitions for libm...............................................................
13.9 Interfaces for libpthread........................................................................
13.10 Data Definitions for libpthread..........................................................
13.11 Interface Definitions for libpthread...................................................
13.12 Interfaces for libgcc_s..........................................................................
13.13 Data Definitions for libgcc_s..............................................................
© 2008 Linux Foundation 3
ISO/IEC 23360 Part 1:2008(E)
13.14 Interfaces for libdl................................................................................
13.15 Data Definitions for libdl....................................................................
13.16 Interface Definitions for libdl.............................................................
13.17 Interfaces for librt.................................................................................
13.18 Data Definitions for librt.....................................................................
13.19 Interfaces for libcrypt..........................................................................
13.20 Interfaces for libpam............................................................................
13.21 Data Definitions for libpam................................................................
13.22 Interface Definitions for libpam.........................................................
IV Utility Libraries..........................................................................................................
14 Utility Libraries...................................................................................................
14.1 Introduction............................................................................................
14.2 Interfaces for libz....................................................................................
14.3 Data Definitions for libz........................................................................
14.4 Interface Definitions for libz.................................................................
14.5 Interfaces for libncurses........................................................................
14.6 Data Definitions for libncurses............................................................
14.7 Interface Definitions for libncurses.....................................................
14.8 Interfaces for libutil................................................................................
14.9 Interface Definitions for libutil.............................................................
V Commands and Utilities.............................................................................................
15 Commands and Utilities....................................................................................
15.1 Commands and Utilities.......................................................................
15.2 Command Behavior...............................................................................
VI Execution Environment.............................................................................................
16 File System Hierarchy........................................................................................
16.1 /dev: Device Files..................................................................................
16.2 /etc: Host-specific system configuration............................................
16.3 User Accounting Databases..................................................................
16.4 Path For System Administration Utilities..........................................
17 Additional Recommendations..........................................................................
17.1 Recommendations for applications on ownership and
permissions...........................................................................................
18 Additional Behaviors.........................................................................................
18.1 Mandatory Optional Behaviors...........................................................
18.2 Optional Mandatory Behaviors...........................................................
18.3 Executable Scripts..................................................................................
19 Localization.........................................................................................................
19.1 Introduction............................................................................................
19.2 Regular Expressions..............................................................................
19.3 Pattern Matching Notation...................................................................
VII System Initialization................................................................................................
20 System Initialization...........................................................................................
20.1 Cron Jobs.................................................................................................
20.2 Init Script Actions..................................................................................
20.3 Comment Conventions for Init Scripts...............................................
20.4 Installation and Removal of Init Scripts.............................................
20.5 Run Levels...............................................................................................
20.6 Facility Names........................................................................................
20.7 Script Names...........................................................................................
20.8 Init Script Functions...............................................................................
4 © 2008 Linux Foundation
ISO/IEC 23360 Part 1:2008(E)
VIII Users & Groups.......................................................................................................
21 Users & Groups...................................................................................................
21.1 User and Group Database....................................................................
21.2 User & Group Names............................................................................
21.3 User ID Ranges.......................................................................................
21.4 Rationale..................................................................................................
IX Package Format and Installation..............................................................................
22 Software Installation..........................................................................................
22.1 Introduction............................................................................................
22.2 Package File Format...............................................................................
22.3 Package Script Restrictions...................................................................
22.4 Package Tools.........................................................................................
22.5 Package Naming....................................................................................
22.6 Package Dependencies..........................................................................
22.7 Package Architecture Considerations.................................................
A Alphabetical Listing of Interfaces............................................................................
A.1 libc.......................................................................................................................
A.2 libcrypt...............................................................................................................
A.3 libdl.....................................................................................................................
A.4 libm.....................................................................................................................
A.5 libncurses...........................................................................................................
A.6 libpam................................................................................................................
A.7 libpthread..........................................................................................................
A.8 librt.....................................................................................................................
A.9 libutil..................................................................................................................
A.10 libz....................................................................................................................
B Future Directions (Informative)................................................................................
B.1 Introduction.......................................................................................................
B.2 Commands And Utilities.................................................................................
lsbinstall...........................................................................................................
C GNU Free Documentation License (Informative).................................................
C.1 PREAMBLE.......................................................................................................
C.2 APPLICABILITY AND DEFINITIONS.........................................................
C.3 VERBATIM COPYING....................................................................................
C.4 COPYING IN QUANTITY..............................................................................
C.5 MODIFICATIONS............................................................................................
C.6 COMBINING DOCUMENTS.........................................................................
C.7 COLLECTIONS OF DOCUMENTS...............................................................
C.8 AGGREGATION WITH INDEPENDENT WORKS....................................
C.9 TRANSLATION................................................................................................
C.10 TERMINATION..............................................................................................
C.11 FUTURE REVISIONS OF THIS LICENSE..................................................
C.12 How to use this License for your documents.............................................
© 2008 Linux Foundation 5