summaryrefslogtreecommitdiffstats
path: root/chrome/tools
diff options
context:
space:
mode:
authoragl@chromium.org <agl@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2008-11-05 01:44:26 +0000
committeragl@chromium.org <agl@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2008-11-05 01:44:26 +0000
commita793701ef63aacfe41acfd257734eb7877ddf4c7 (patch)
tree324605a410c238bcfd6e6254787368e54d340f62 /chrome/tools
parent016e1ae50526c1795f74cbb0f660ad90d1e00413 (diff)
downloadchromium_src-a793701ef63aacfe41acfd257734eb7877ddf4c7.zip
chromium_src-a793701ef63aacfe41acfd257734eb7877ddf4c7.tar.gz
chromium_src-a793701ef63aacfe41acfd257734eb7877ddf4c7.tar.bz2
Enable building of chrome/tools/test/image_diff in Linux
BUG=3650 Review URL: http://codereview.chromium.org/8065 Patch from James Vega. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@4724 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/tools')
-rw-r--r--chrome/tools/test/image_diff/SConscript39
-rw-r--r--chrome/tools/test/image_diff/image_diff.cc4
2 files changed, 24 insertions, 19 deletions
diff --git a/chrome/tools/test/image_diff/SConscript b/chrome/tools/test/image_diff/SConscript
index 7b1ed3a..826fe0d 100644
--- a/chrome/tools/test/image_diff/SConscript
+++ b/chrome/tools/test/image_diff/SConscript
@@ -27,25 +27,26 @@ env_test.Prepend(
],
)
-env_test.Prepend(
- LINKFLAGS = [
- '/INCREMENTAL',
- '/DEBUG',
-
- '/DELAYLOAD:"dwmapi.dll"',
- '/DELAYLOAD:"uxtheme.dll"',
-
- '/SUBSYSTEM:CONSOLE',
-
- '/MACHINE:X86',
- '/FIXED:No',
-
- '/safeseh',
- '/dynamicbase',
- '/ignore:4199',
- '/nxcompat',
- ],
-)
+if env_test['PLATFORM'] == 'win32':
+ env_test.Prepend(
+ LINKFLAGS = [
+ '/INCREMENTAL',
+ '/DEBUG',
+
+ '/DELAYLOAD:"dwmapi.dll"',
+ '/DELAYLOAD:"uxtheme.dll"',
+
+ '/SUBSYSTEM:CONSOLE',
+
+ '/MACHINE:X86',
+ '/FIXED:No',
+
+ '/safeseh',
+ '/dynamicbase',
+ '/ignore:4199',
+ '/nxcompat',
+ ],
+ )
input_files = [
'image_diff.cc',
diff --git a/chrome/tools/test/image_diff/image_diff.cc b/chrome/tools/test/image_diff/image_diff.cc
index fabd38f..7b696d4 100644
--- a/chrome/tools/test/image_diff/image_diff.cc
+++ b/chrome/tools/test/image_diff/image_diff.cc
@@ -234,7 +234,11 @@ int CompareImages(const char* file1, const char* file2) {
int main(int argc, const char* argv[]) {
process_util::EnableTerminationOnHeapCorruption();
+#if defined(OS_WIN)
CommandLine parsed_command_line;
+#elif defined(OS_POSIX)
+ CommandLine parsed_command_line(argc, argv);
+#endif
if (parsed_command_line.HasSwitch(kOptionPollStdin)) {
// Watch stdin for filenames.
std::string stdin_buffer;