Useful Command-Line Tools
Apple has created or modified several command-line tools for
compilation, debugging, performance analysis, and so on. Table 4.2 lists some of the more useful tools. You can
get further information by using the manpages system. The tools are
all located in the /usr/bin directory.
Table 4-2. Command-Line Development Tools
| Name | Description |
|---|---|
cc
|
Compiles C, Objective-C, and C++ source code files. |
gdb
|
Is a source-level symbolic debugger for C, extended by Apple to support Objective-C and C++. |
gnumake
|
Builds the product(s) of a programming project based on dependency information. |
as
|
Assembles; translates assembly code into object code. |
defaults
|
Reads, writes, searches, and deletes user defaults. The defaults system records user preferences that persist when the application isn’t running. When users specify defaults in an application’s Preferences panel, NSUserDefaults methods are used to write the defaults. |
nibtool
|
Reads the contents of an Interface Builder nib file. Prints classes, the hierarchy, objects, connections, and localizable strings. |
libtool
|
Creates static or dynamic libraries from specified object bin files for one or multiple architectures. |
otool
|
Displays specified parts of object files or libraries. |
nm
|
Displays the symbol table, in whole or in part, of the specified object file or files. |
fixPrecomps
|
Creates or refreshes a precompiled header file for each of the major frameworks. |
strip
|
Removes or modifies the ... |
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access