Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(87)

Side by Side Diff: chrome/common/chrome_paths.cc

Issue 215025: Make chromeos build use shared object to load battery... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/common/chrome_paths.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/common/chrome_paths.h" 5 #include "chrome/common/chrome_paths.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/file_path.h" 8 #include "base/file_path.h"
9 #include "base/file_util.h" 9 #include "base/file_util.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after
165 cur = cur.Append(FILE_PATH_LITERAL("plugins")); 165 cur = cur.Append(FILE_PATH_LITERAL("plugins"));
166 cur = cur.Append(FILE_PATH_LITERAL("gears")); 166 cur = cur.Append(FILE_PATH_LITERAL("gears"));
167 cur = cur.Append(FILE_PATH_LITERAL("gears.dll")); 167 cur = cur.Append(FILE_PATH_LITERAL("gears.dll"));
168 } 168 }
169 #else 169 #else
170 // No gears.dll on non-Windows systems. 170 // No gears.dll on non-Windows systems.
171 return false; 171 return false;
172 #endif 172 #endif
173 } 173 }
174 break; 174 break;
175 #if defined(OS_CHROMEOS)
176 case chrome::FILE_CHROMEOS_API:
177 if (!PathService::Get(base::DIR_MODULE, &cur))
178 return false;
179 cur = cur.Append(FILE_PATH_LITERAL("chromeos"));
180 cur = cur.Append(FILE_PATH_LITERAL("libchromeos-power.so"));
181 break;
182 #endif
175 // The following are only valid in the development environment, and 183 // The following are only valid in the development environment, and
176 // will fail if executed from an installed executable (because the 184 // will fail if executed from an installed executable (because the
177 // generated path won't exist). 185 // generated path won't exist).
178 case chrome::DIR_TEST_DATA: 186 case chrome::DIR_TEST_DATA:
179 if (!PathService::Get(base::DIR_SOURCE_ROOT, &cur)) 187 if (!PathService::Get(base::DIR_SOURCE_ROOT, &cur))
180 return false; 188 return false;
181 cur = cur.Append(FILE_PATH_LITERAL("chrome")); 189 cur = cur.Append(FILE_PATH_LITERAL("chrome"));
182 cur = cur.Append(FILE_PATH_LITERAL("test")); 190 cur = cur.Append(FILE_PATH_LITERAL("test"));
183 cur = cur.Append(FILE_PATH_LITERAL("data")); 191 cur = cur.Append(FILE_PATH_LITERAL("data"));
184 if (!file_util::PathExists(cur)) // we don't want to create this 192 if (!file_util::PathExists(cur)) // we don't want to create this
(...skipping 20 matching lines...) Expand all
205 return true; 213 return true;
206 } 214 }
207 215
208 // This cannot be done as a static initializer sadly since Visual Studio will 216 // This cannot be done as a static initializer sadly since Visual Studio will
209 // eliminate this object file if there is no direct entry point into it. 217 // eliminate this object file if there is no direct entry point into it.
210 void RegisterPathProvider() { 218 void RegisterPathProvider() {
211 PathService::RegisterProvider(PathProvider, PATH_START, PATH_END); 219 PathService::RegisterProvider(PathProvider, PATH_START, PATH_END);
212 } 220 }
213 221
214 } // namespace chrome 222 } // namespace chrome
OLDNEW
« no previous file with comments | « chrome/common/chrome_paths.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698