|
## structure
each subdirectory should be named for a specific target tuple. the top level is reserved for development tools and files of relevance to more than one architecture; for instance, the standardized x86-64 SysV syscall ABI is kept at `/arch/x86.syscall.64.s`. these files should not be included directly from any files under the `/mod` directory; rather, they should be included from stub files in the appropriate target directory. this provides a consistent header selection mechanism.
## scripts
arch contains a number of shell scripts. unlike the shell scripts in /global, the shell scripts in /arch are not part of the build process; they are simply developer tools, usually for generating syscall tables for new architectures. the output of the scripts is written directly to the appropriate target directory; these files should be added to the source tree and committed.
- `mktbl.posix.sh <target> <ABI>`: generates the C headers for a particular target based on the system_calls.h and error_table.h files in its directory. the ABI parameter controls which syscalls are included; the ABI is the second column in the kernel system calls table.
- `mktbl.errno.linux.sh <target> <ABI>`: generates the errno table for a given architecture and ABI. requires the kernel source tree to be installed on the host system.
|
|
|
## structure
each subdirectory should be named for a specific target tuple. the top level is reserved for development tools and files of relevance to more than one architecture; for instance, the standardized x86-64 SysV syscall ABI is kept at `/arch/x86.syscall.64.s`. these files should not be included directly from any files under the `/mod` directory; rather, they should be included from stub files in the appropriate target directory. this provides a consistent header selection mechanism.
## scripts
arch contains a number of shell scripts. unlike the shell scripts in /global, the shell scripts in /arch are not part of the build process; they are simply developer tools, usually for generating syscall tables for new architectures. the output of the scripts is written directly to the appropriate target directory; these files should be added to the source tree and committed.
- `mktbl.posix.sh <target> <ABI>`: generates the C headers for a particular target based on the system_calls.h and error_table.h files in its directory. the ABI parameter controls which syscalls are included; the ABI is the second column in the kernel system calls table.
- `mktbl.linux.errno.sh <target> <ABI>`: generates the errno table for a given architecture and ABI. requires the kernel source tree to be installed on the host system.
- `mktbl.linux.syscall.sh <target> <ABI>`: generates the syscall table for a given architecture and ABI. requires the kernel source tree to be installed on the host system. note that some architectures like x86 have separate, architecture-specific tables. this script is not meant to be used with these architectures.
|