The /usr/include directoriesOn most UNIX systems, you will find a /usr/include directory. On some UNIX systems, you may need to install a programmer's environment or package to see this directory. On others, it is part of the core UNIX system. On Sun's Solaris 2 systems, the majority of the /usr/include files are in the SUNWhea package. Within the /usr/include directory, you will find several subdirectories. Note that each flavor of UNIX that you encounter may differ slightly here. On a Solaris 2.3 system, you will find a directory structure as follows . Each of these directories and subdirectories contains header files. Table 10-1. Subdirectories of /usr/include
Let's briefly talk about what might be found in each of these directories. /usr/includeIf /usr/include were to have a miscellaneous area, this would be it. Anything that doesn't fit into one of the more specialized subdirectories described below will be found here. It is here that we find header files commonly used by the programmers not writing kernel code, network software, or device drivers. /usr/include/adminThe header files here are all related to the administration framework products. /usr/include/arpaHere we find the header files relating to ftp , telnet , and other Advanced Research Project Agency (ARPA) products. /usr/include/bsmThis directory contains the header files relating to the Basic Security Module. Here we find among other things, information about security auditing policies, audit queue controls, the various audit record structures, and the list of auditable events. /usr/include/desThis directory contains the header files relating to the Data Encryption Set software. /usr/include/inetHere is where we find some of the header information relating to the Internet Protocol software. /usr/include/kerberosYes, you guessed it! This is where the header files for Kerberos live. /usr/include/netThis is where the low-level network interface header files can be found. Information about routing, the Address Resolution Protocol, and address families is tucked away here. /usr/include/netinetHere is where we find more information about the Internet Protocols. This includes:
/usr/include/nfsIf you're interested in digging through the Network File System structures, this is where you will find NFS information. Export and mount option flags are found here, as well as various NFS limits, such as the maximum length of an NFS pathname. This is the directory we reference when looking at structures used by NFS. /usr/include/protocolsThis directory contains a few header files that relate to the routed , rwhod , timed , dump , and restore programs. /usr/include/rpcThis is where we find information about the Remote Procedure Call software, keyserv , and more on Kerberos and DES authentication in relation to RPC. Also found here is information about boot parameters, more on exported directories, header files relating to the Port Mapper Protocol, and information about External Data Representation (XDR). /usr/include/rpcsvcThis directory contains the header files for software serviced by RPC. Software represented here includes autofs, NFS, NIS+, and NIS (formerly known as YP). /usr/include/securityHeader files relating to the Pluggable Authentication Module (PAM) interface software are kept here. /usr/include/sysThis directory contains the majority of the kernel header files as well as several subdirectories. /usr/include/sys/debugThe Kernel Absolute DeBugger ( kadb ) is compiled using the header files found here. /usr/include/sys/fpuEverything you might need to know about the Floating-Point Unit structures, function, and variables is kept here. /usr/include/sys/fsValuable information about the various local file systems exists in this directory. On Solaris 2.3, this information includes:
/usr/include/sys/procHere is where we find the header information regarding the /proc file system. /usr/include/sys/scsiA few generalized and common header files exist here; the subdirectories listed below contain more specific information relating to the Small Computer System Interface (SCSI) hardware and supporting software. /usr/include/sys/scsi/adaptersInformation about the Enhanced SCSI Processor (ESP) chip is found here. This information includes register definitions, register manipulation macros, and clocking information for the chip. ESP options used in tuning ESP devices can also be found in this directory. /usr/include/sys/scsi/confGlobal SCSI device configuration information is maintained here. This directory is also where we find the SCSI device structure. /usr/include/sys/scsi/genericWithin this directory are the header files that define and describe standard SCSI command definitions, direct access mode operations, message codes, and other information from the SCSI specification. /usr/include/sys/scsi/implThis directory contains the header files that accompany each UNIX vendor's specific implementation of the standard SCSI interface. /usr/include/sys/scsi/targetsHeader information specific to SCSI targets is found here, including data about the SCSI disk (sd) and SCSI tape (st) devices. /usr/include/vmThe header files in this directory define aspects of the virtual memory system. Here is where you will read about anonymous memory, how address space is structured, how hardware address translation is managed, and how virtual memory pages are handled. CAUTION! The information in these / usr/include files is considered a part of the source code and may be changed dramatically in later releases without warning. Use the information in these files for debugging and for understanding how the system is structured, but don't depend on it remaining the same. Programmers who write their code based only on data in the header files should expect severe porting problems. |