Library

From Mac Guides

Jump to: navigation, search

The Library in Mac OS X is a special folder in which many system and applications resources are stored. There are separate Library folders for each file-system domain; the system domain, the local domain (resources shared by all users) and the user domain.

Contents

Libraries

System Library

The System Library, located at /System/Library/, stores the operating system. It is read only, to protect the system (although changes can be made by superusers), and so does not store any preferences files like other Library folders.

Notable items inside the System Library include:

  • Menu Extras- If you navigate to /System/Library/CoreServices/Menu Extras/, you can see a full list of menu extras. Open one to add it to your menu bar.
  • The Dock is located at /System/Library/CoreServices/Dock. If you control-click on it and choose "Show Package Contents", then navigate to Contents/Resources/, you will find several interesting files. The "Widgets" Dashboard widget, introduced in Mac OS X 10.4.2, is located here, as well as the Dock's "poof" animation (stored in poof.png), which can be replaced by an alternative animation provided you have an image with suitable dimensions (these can be found on various websites) and superuser privileges.
  • The Tiger introduction movie, shown when the operating system is first booted, can be found in two separate files, intro-sound.mp3 and intro.mov, both located in
    /System/Library/CoreServices/Setup Assistant/Contents/Resources/TransitionSection.bundle/Contents/Resources/

Local Library

The local Library (located at /Library/) is shared by all users on the system and stores a variety of resources. These include preferences for System processes, desktop pictures, dictionaries (for Tiger), receipts (used for repairing permissions, system logs, caches and more. It can also store Dashboard widgets, screen savers and other resources shared by all users.

User Library

The user Library (located at ~/Library/) is the one which you are most likely to need to be familiar with. It is the most frequently updated, as it stores application preferences, application support files, caches and much more. If you encounter problems with applications, a common source is a corrupt file in your user's Library folder. For more information about troubleshooting these problems, see the article on troubleshooting software problems.

Subdirectories

Each Library folder has a number of subdirectories. The following table lists some of these subdirectories, with a brief description and whether each Library folder can include it.

Subdirectory Description User Local System
Application Support Application specific support files such as plug-ins and helper applications. This is only used by some applications. Each application that uses this folder has its own subdirectory. Yes Yes No
Audio Audio plug-ins and device drivers. Yes Yes No
Caches Cached data to speed up future operations. Yes Yes Yes
Audio Audio plug-ins and device drivers. Yes Yes No
Components System bundles and extensions. No Yes Yes
CoreServices Essential system files. No No Yes
Documentation Documentation files intended for users and administrators. Not much useful data is contained in these, as most help files are stored in other places. No Yes Yes
Extensions Device drivers and other kernel extensions. No No Yes
Fonts Font files for display and printing. Yes Yes Yes
Frameworks Frameworks and shared libraries. Yes Yes Yes
Logs Log files for the system and applications, viewable with the Console application. Crash reports are stored here, which can be sent to Apple or application developers in order to fix bugs. Yes Yes No
Mail Your email stored in Mail. Yes No No
PreferencePanes Plug-ins from System Preferences, also known as preference panes. Yes Yes Yes
Preferences Application settings. Yes Yes No
Printers Printer drivers (for system and local domains) or printer configurations (for the user domain). Yes Yes Yes
QuickTime QuickTime components and extensions. Yes Yes Yes
Receipts Information about application and system installations. Used for repairing permissions. No Yes No
Screen Savers Screen Savers used in the Desktop & Screen Saver preference pane. Yes Yes Yes
Scripts AppleScript scripts. Yes Yes No
Sounds System alert sounds. Yes Yes Yes
StartupItems System and third-party processes to be run at boot time. You should not modify this folder yourself, use the Accounts preference pane to setup applications to startup when you log in. No Yes Yes
Widgets Dashboard Widgets. Yes Yes Yes

Links

The Library Directory (Apple Developer Connection Documentation)