1ddb351dbec246cf1fab5ec20d2d5520909041de1Kristian Monsen// Copyright (c) 2011 The Chromium Authors. All rights reserved. 2c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott// Use of this source code is governed by a BSD-style license that can be 3c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott// found in the LICENSE file. 4c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott 5c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott#ifndef BASE_BASE_PATHS_H_ 6c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott#define BASE_BASE_PATHS_H_ 73345a6884c488ff3a535c2c9acdd33d74b37e311Iain Merrick#pragma once 8c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott 9c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott// This file declares path keys for the base module. These can be used with 10c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott// the PathService to access various special directories and files. 11c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott 12ddb351dbec246cf1fab5ec20d2d5520909041de1Kristian Monsen#include "build/build_config.h" 13ddb351dbec246cf1fab5ec20d2d5520909041de1Kristian Monsen 14c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott#if defined(OS_WIN) 15c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott#include "base/base_paths_win.h" 16c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott#elif defined(OS_MACOSX) 17c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott#include "base/base_paths_mac.h" 18c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott#endif 19c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott 20c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scottnamespace base { 21c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott 22c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scottenum { 23c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott PATH_START = 0, 24c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott 25c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott DIR_CURRENT, // current directory 26c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott DIR_EXE, // directory containing FILE_EXE 27c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott DIR_MODULE, // directory containing FILE_MODULE 28c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott DIR_TEMP, // temporary directory 29c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott FILE_EXE, // Path and filename of the current executable. 30c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott FILE_MODULE, // Path and filename of the module containing the code for the 31c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott // PathService (which could differ from FILE_EXE if the 32c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott // PathService were compiled into a shared object, for example). 33c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott DIR_SOURCE_ROOT, // Returns the root of the source tree. This key is useful 34c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott // for tests that need to locate various resources. It 35c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott // should not be used outside of test code. 36c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott#if defined(OS_POSIX) 37201ade2fbba22bfb27ae029f4d23fca6ded109a0Ben Murdoch DIR_CACHE, // Directory where to put cache data. Note this is 38201ade2fbba22bfb27ae029f4d23fca6ded109a0Ben Murdoch // *not* where the browser cache lives, but the 39201ade2fbba22bfb27ae029f4d23fca6ded109a0Ben Murdoch // browser cache can be a subdirectory. 40201ade2fbba22bfb27ae029f4d23fca6ded109a0Ben Murdoch // This is $XDG_CACHE_HOME on Linux and 41201ade2fbba22bfb27ae029f4d23fca6ded109a0Ben Murdoch // ~/Library/Caches on Mac. 42c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott#endif 43c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott 44c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott PATH_END 45c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott}; 46c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott 47c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott} // namespace base 48c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott 49c7f5f8508d98d5952d42ed7648c2a8f30a4da156Patrick Scott#endif // BASE_BASE_PATHS_H_ 50