diff options
author | scherkus@chromium.org <scherkus@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-11-13 22:10:12 +0000 |
---|---|---|
committer | scherkus@chromium.org <scherkus@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-11-13 22:10:12 +0000 |
commit | 116f3a823b65833ef8a5c56dcf8c2c33a69b914d (patch) | |
tree | c71b3ccdc0bad1bf28d3c0bd4d63d701870e29ee /media | |
parent | 2c56af1a6677c9b1141778173dcb1b3bdb63f14b (diff) | |
download | chromium_src-116f3a823b65833ef8a5c56dcf8c2c33a69b914d.zip chromium_src-116f3a823b65833ef8a5c56dcf8c2c33a69b914d.tar.gz chromium_src-116f3a823b65833ef8a5c56dcf8c2c33a69b914d.tar.bz2 |
Checking in the media project files (layout based on net/base libraries).
Added a dummy media.cc file in order to produce media.lib so there are no
linker errors when building media_unittests.exe. Currently chrome_dll
does NOT depend on media so it will not be linked in, which is OK for now :)
Review URL: http://codereview.chromium.org/10683
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@5389 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'media')
-rw-r--r-- | media/SConstruct | 7 | ||||
-rw-r--r-- | media/base/media.cc | 11 | ||||
-rw-r--r-- | media/base/run_all_unittests.cc | 11 | ||||
-rw-r--r-- | media/build/media.vcproj | 131 | ||||
-rw-r--r-- | media/build/media_unittests.vcproj | 131 | ||||
-rw-r--r-- | media/media.scons | 22 | ||||
-rw-r--r-- | media/media.sln | 67 | ||||
-rw-r--r-- | media/media_lib.scons | 46 | ||||
-rw-r--r-- | media/media_unittests.scons | 52 |
9 files changed, 478 insertions, 0 deletions
diff --git a/media/SConstruct b/media/SConstruct new file mode 100644 index 0000000..5c859c2 --- /dev/null +++ b/media/SConstruct @@ -0,0 +1,7 @@ +# Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. +# Use of this source code is governed by a BSD-style license that can be +# found in the LICENSE file. + +build_component = 'media' +SConscript('../build/SConscript.main', + exports=['build_component']) diff --git a/media/base/media.cc b/media/base/media.cc new file mode 100644 index 0000000..9b92a42 --- /dev/null +++ b/media/base/media.cc @@ -0,0 +1,11 @@ +// Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +namespace media { + +// Dummy function to generate media.lib +void DoNothing() { +} + +} // namespace media diff --git a/media/base/run_all_unittests.cc b/media/base/run_all_unittests.cc new file mode 100644 index 0000000..4ab019a --- /dev/null +++ b/media/base/run_all_unittests.cc @@ -0,0 +1,11 @@ +// Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#include "base/process_util.h" +#include "base/test_suite.h" + +int main(int argc, char** argv) { + process_util::EnableTerminationOnHeapCorruption(); + return TestSuite(argc, argv).Run(); +} diff --git a/media/build/media.vcproj b/media/build/media.vcproj new file mode 100644 index 0000000..c4631e2 --- /dev/null +++ b/media/build/media.vcproj @@ -0,0 +1,131 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="8.00"
+ Name="media"
+ ProjectGUID="{6AE76406-B03B-11DD-94B1-80B556D89593}"
+ RootNamespace="media"
+ Keyword="Win32Proj"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug|Win32"
+ ConfigurationType="4"
+ InheritedPropertySheets="$(SolutionDir)..\build\common.vsprops;$(SolutionDir)..\build\debug.vsprops"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLibrarianTool"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release|Win32"
+ ConfigurationType="4"
+ InheritedPropertySheets="$(SolutionDir)..\build\common.vsprops;$(SolutionDir)..\build\release.vsprops"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLibrarianTool"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <File
+ RelativePath="..\base\media.cc"
+ >
+ </File>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/media/build/media_unittests.vcproj b/media/build/media_unittests.vcproj new file mode 100644 index 0000000..d546615 --- /dev/null +++ b/media/build/media_unittests.vcproj @@ -0,0 +1,131 @@ +<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="8.00"
+ Name="media_unittests"
+ ProjectGUID="{C8C6183C-B03C-11DD-B471-DFD256D89593}"
+ RootNamespace="media_unittests"
+ Keyword="Win32Proj"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug|Win32"
+ ConfigurationType="1"
+ InheritedPropertySheets="$(SolutionDir)..\build\common.vsprops;$(SolutionDir)..\build\debug.vsprops;$(SolutionDir)..\testing\using_gtest.vsprops"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLibrarianTool"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release|Win32"
+ ConfigurationType="1"
+ InheritedPropertySheets="$(SolutionDir)..\build\common.vsprops;$(SolutionDir)..\build\release.vsprops;$(SolutionDir)..\testing\using_gtest.vsprops"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLibrarianTool"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <File
+ RelativePath="..\base\run_all_unittests.cc"
+ >
+ </File>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/media/media.scons b/media/media.scons new file mode 100644 index 0000000..d069121 --- /dev/null +++ b/media/media.scons @@ -0,0 +1,22 @@ +# Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. +# Use of this source code is governed by a BSD-style license that can be +# found in the LICENSE file. + +__doc__ = """ +Master configuration for building media components. +""" + +Import('env') + +# Arrange for Hammer to add all programs to the 'media' Alias. +env.Append( + COMPONENT_PROGRAM_GROUPS = ['media'], + COMPONENT_TEST_PROGRAM_GROUPS = ['media'], +) + +sconscript_files = [ + 'media_lib.scons', + 'media_unittests.scons', +] + +SConscript(sconscript_files, exports=['env']) diff --git a/media/media.sln b/media/media.sln new file mode 100644 index 0000000..607439d --- /dev/null +++ b/media/media.sln @@ -0,0 +1,67 @@ +
+Microsoft Visual Studio Solution File, Format Version 9.00
+# Visual Studio 2005
+Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "dependencies", "dependencies", "{9D67D7CC-B03F-11DD-86F7-FD7F55D89593}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "media", "build\media.vcproj", "{6AE76406-B03B-11DD-94B1-80B556D89593}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "media_unittests", "build\media_unittests.vcproj", "{C8C6183C-B03C-11DD-B471-DFD256D89593}"
+ ProjectSection(ProjectDependencies) = postProject
+ {1832A374-8A74-4F9E-B536-69A699B3E165} = {1832A374-8A74-4F9E-B536-69A699B3E165}
+ {8C27D792-2648-4F5E-9ED0-374276327308} = {8C27D792-2648-4F5E-9ED0-374276327308}
+ {6AE76406-B03B-11DD-94B1-80B556D89593} = {6AE76406-B03B-11DD-94B1-80B556D89593}
+ {BFE8E2A7-3B3B-43B0-A994-3058B852DB8B} = {BFE8E2A7-3B3B-43B0-A994-3058B852DB8B}
+ EndProjectSection
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "base", "..\base\build\base.vcproj", "{1832A374-8A74-4F9E-B536-69A699B3E165}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "gtest", "..\testing\gtest.vcproj", "{BFE8E2A7-3B3B-43B0-A994-3058B852DB8B}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "icu", "..\third_party\icu38\build\icu.vcproj", "{8C27D792-2648-4F5E-9ED0-374276327308}"
+ ProjectSection(ProjectDependencies) = postProject
+ {A0D94973-D355-47A5-A1E2-3456F321F010} = {A0D94973-D355-47A5-A1E2-3456F321F010}
+ EndProjectSection
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "icudt", "..\third_party\icu38\build\icudt.vcproj", "{A0D94973-D355-47A5-A1E2-3456F321F010}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Win32 = Debug|Win32
+ Release|Win32 = Release|Win32
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {1832A374-8A74-4F9E-B536-69A699B3E165}.Debug|Win32.ActiveCfg = Debug|Win32
+ {1832A374-8A74-4F9E-B536-69A699B3E165}.Debug|Win32.Build.0 = Debug|Win32
+ {1832A374-8A74-4F9E-B536-69A699B3E165}.Release|Win32.ActiveCfg = Release|Win32
+ {1832A374-8A74-4F9E-B536-69A699B3E165}.Release|Win32.Build.0 = Release|Win32
+ {6AE76406-B03B-11DD-94B1-80B556D89593}.Debug|Win32.ActiveCfg = Debug|Win32
+ {6AE76406-B03B-11DD-94B1-80B556D89593}.Debug|Win32.Build.0 = Debug|Win32
+ {6AE76406-B03B-11DD-94B1-80B556D89593}.Release|Win32.ActiveCfg = Release|Win32
+ {6AE76406-B03B-11DD-94B1-80B556D89593}.Release|Win32.Build.0 = Release|Win32
+ {8C27D792-2648-4F5E-9ED0-374276327308}.Debug|Win32.ActiveCfg = Debug|Win32
+ {8C27D792-2648-4F5E-9ED0-374276327308}.Debug|Win32.Build.0 = Debug|Win32
+ {8C27D792-2648-4F5E-9ED0-374276327308}.Release|Win32.ActiveCfg = Release|Win32
+ {8C27D792-2648-4F5E-9ED0-374276327308}.Release|Win32.Build.0 = Release|Win32
+ {A0D94973-D355-47A5-A1E2-3456F321F010}.Debug|Win32.ActiveCfg = Debug|Win32
+ {A0D94973-D355-47A5-A1E2-3456F321F010}.Debug|Win32.Build.0 = Debug|Win32
+ {A0D94973-D355-47A5-A1E2-3456F321F010}.Release|Win32.ActiveCfg = Release|Win32
+ {A0D94973-D355-47A5-A1E2-3456F321F010}.Release|Win32.Build.0 = Release|Win32
+ {BFE8E2A7-3B3B-43B0-A994-3058B852DB8B}.Debug|Win32.ActiveCfg = Debug|Win32
+ {BFE8E2A7-3B3B-43B0-A994-3058B852DB8B}.Debug|Win32.Build.0 = Debug|Win32
+ {BFE8E2A7-3B3B-43B0-A994-3058B852DB8B}.Release|Win32.ActiveCfg = Release|Win32
+ {BFE8E2A7-3B3B-43B0-A994-3058B852DB8B}.Release|Win32.Build.0 = Release|Win32
+ {C8C6183C-B03C-11DD-B471-DFD256D89593}.Debug|Win32.ActiveCfg = Debug|Win32
+ {C8C6183C-B03C-11DD-B471-DFD256D89593}.Debug|Win32.Build.0 = Debug|Win32
+ {C8C6183C-B03C-11DD-B471-DFD256D89593}.Release|Win32.ActiveCfg = Release|Win32
+ {C8C6183C-B03C-11DD-B471-DFD256D89593}.Release|Win32.Build.0 = Release|Win32
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(NestedProjects) = preSolution
+ {1832A374-8A74-4F9E-B536-69A699B3E165} = {9D67D7CC-B03F-11DD-86F7-FD7F55D89593}
+ {8C27D792-2648-4F5E-9ED0-374276327308} = {9D67D7CC-B03F-11DD-86F7-FD7F55D89593}
+ {A0D94973-D355-47A5-A1E2-3456F321F010} = {9D67D7CC-B03F-11DD-86F7-FD7F55D89593}
+ {BFE8E2A7-3B3B-43B0-A994-3058B852DB8B} = {9D67D7CC-B03F-11DD-86F7-FD7F55D89593}
+ EndGlobalSection
+EndGlobal
diff --git a/media/media_lib.scons b/media/media_lib.scons new file mode 100644 index 0000000..de42fed --- /dev/null +++ b/media/media_lib.scons @@ -0,0 +1,46 @@ +# Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. +# Use of this source code is governed by a BSD-style license that can be +# found in the LICENSE file. + +__doc__ = """ +Configuration for building media.lib / libmedia.a. +""" + +Import('env') + +env_res = env.Clone() +env_tests = env.Clone() +env = env.Clone() + +env.SConscript([ + '$ICU38_DIR/using_icu38.scons', +], {'env':env}) + +env.Prepend( + CPPPATH = [ + '$CHROME_SRC_DIR', + ], +) + +# These net files work on *all* platforms; files that don't work +# cross-platform live below. +input_files = [ +] + +if env['PLATFORM'] == 'win32': + input_files.extend([ + ]) + +if env['PLATFORM'] == 'darwin': + input_files.extend([ + ]) + +if env['PLATFORM'] == 'posix': + input_files.extend([ + ]) + +if env['PLATFORM'] in ('darwin', 'posix'): + input_files.extend([ + ]) + +env.ChromeStaticLibrary('media', input_files) diff --git a/media/media_unittests.scons b/media/media_unittests.scons new file mode 100644 index 0000000..b6116f7 --- /dev/null +++ b/media/media_unittests.scons @@ -0,0 +1,52 @@ +# Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. +# Use of this source code is governed by a BSD-style license that can be +# found in the LICENSE file. + +__doc__ = """ +Configuration for building the media_unittests{,.exe} executable. +""" + +Import('env') + +env = env.Clone() + +env.SConscript([ + '$BASE_DIR/using_base.scons', + '$GTEST_DIR/../using_gtest.scons', + '$ICU38_DIR/using_icu38.scons', +], {'env':env}) + +env.Prepend( + CPPPATH = [ + '$CHROME_SRC_DIR', + ], +) + +if env['PLATFORM'] == 'win32': + env.Prepend( + CCFLAGS = [ + '/TP', + '/WX', + ], + CPPDEFINES = [ + '_WIN32_WINNT=0x0600', + 'WINVER=0x0600', + '_HAS_EXCEPTIONS=0', + ], + LINKFLAGS = [ + '/DELAYLOAD:"dwmapi.dll"', + '/DELAYLOAD:"uxtheme.dll"', + '/MACHINE:X86', + '/FIXED:No', + '/safeseh', + '/dynamicbase', + '/ignore:4199', + '/nxcompat', + ], + ) + +input_files = [ + 'base/run_all_unittests.cc', +] + +env.ChromeTestProgram('media_unittests', input_files) |