Skip to content

Commit

Permalink
Revert 198495 "Build libpeerconnection as a loadable module for ..."
Browse files Browse the repository at this point in the history
> Build libpeerconnection as a loadable module for win, mac and linux by default. Also remove the allocator shim variable since it's no longer needed.
> 
> This requires updating .isolate files for some try bots.
> In practice, I've only seen failures in interactive_ui_tests because of this change, but I'm being a bit proactive here and making sure that libpeerconnection.so exists with test hosts that have tests that depend on it.
> 
> BUG=238207
> R=csharp@chromium.org, ronghuawu@chromium.org
> 
> Review URL: https://codereview.chromium.org/14907003

TBR=tommi@chromium.org

Review URL: https://codereview.chromium.org/15005004

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@198503 0039d316-1c4b-4281-b951-d872f2087c98
  • Loading branch information
tommi@chromium.org committed May 6, 2013
1 parent 01c7e7c commit 77bb500
Show file tree
Hide file tree
Showing 9 changed files with 14 additions and 55 deletions.
15 changes: 6 additions & 9 deletions chrome/browser_tests.isolate
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,15 @@
],
'isolate_dependency_tracked': [
'../testing/xvfb.py',
'<(PRODUCT_DIR)/DumpRenderTree<(EXECUTABLE_SUFFIX)',
'<(PRODUCT_DIR)/chrome.pak',
'<(PRODUCT_DIR)/chrome<(EXECUTABLE_SUFFIX)',
'<(PRODUCT_DIR)/DumpRenderTree<(EXECUTABLE_SUFFIX)',
'<(PRODUCT_DIR)/lib/libpeerconnection.so',
'<(PRODUCT_DIR)/libclearkeycdm.so',
'<(PRODUCT_DIR)/libclearkeycdmadapter.so',
'<(PRODUCT_DIR)/libffmpegsumo.so',
'<(PRODUCT_DIR)/libosmesa.so',
'<(PRODUCT_DIR)/libppapi_tests.so',
'<(PRODUCT_DIR)/libppGoogleNaClPluginChrome.so',
'<(PRODUCT_DIR)/libppapi_tests.so',
'<(PRODUCT_DIR)/nacl_helper<(EXECUTABLE_SUFFIX)',
'<(PRODUCT_DIR)/nacl_helper_bootstrap<(EXECUTABLE_SUFFIX)',
'<(PRODUCT_DIR)/xdisplaycheck<(EXECUTABLE_SUFFIX)',
Expand Down Expand Up @@ -101,11 +100,10 @@
'variables': {
'isolate_dependency_tracked': [
'<(PRODUCT_DIR)/ffmpegsumo.so',
'<(PRODUCT_DIR)/libpeerconnection.so',
'<(PRODUCT_DIR)/plugins/npapi_test_plugin.plugin/Contents/Info.plist',
'<(PRODUCT_DIR)/plugins/npapi_test_plugin.plugin/Contents/MacOS/npapi_test_plugin',
'<(PRODUCT_DIR)/plugins/TestNetscapePlugIn.plugin/Contents/Info.plist',
'<(PRODUCT_DIR)/plugins/TestNetscapePlugIn.plugin/Contents/MacOS/TestNetscapePlugIn',
'<(PRODUCT_DIR)/plugins/npapi_test_plugin.plugin/Contents/Info.plist',
'<(PRODUCT_DIR)/plugins/npapi_test_plugin.plugin/Contents/MacOS/npapi_test_plugin',
'<(PRODUCT_DIR)/ppapi_nacl_tests_pnacl_newlib_x32.nexe',
'<(PRODUCT_DIR)/ppapi_tests.plugin/Contents/MacOS/ppapi_tests',
],
Expand All @@ -131,19 +129,18 @@
'../native_client/build/build_nexe.py',
'../third_party/cygwin/bin/bash.exe',
'../third_party/cygwin/setup_mount.bat',
'<(PRODUCT_DIR)/D3DCompiler_43.dll',
'<(PRODUCT_DIR)/clearkeycdm.dll',
'<(PRODUCT_DIR)/clearkeycdmadapter.dll',
'<(PRODUCT_DIR)/D3DCompiler_43.dll',
'<(PRODUCT_DIR)/d3dcompiler_46.dll',
'<(PRODUCT_DIR)/ffmpegsumo.dll',
'<(PRODUCT_DIR)/icudt.dll',
'<(PRODUCT_DIR)/libEGL.dll',
'<(PRODUCT_DIR)/libGLESv2.dll',
'<(PRODUCT_DIR)/libpeerconnection.dll',
'<(PRODUCT_DIR)/nacl64<(EXECUTABLE_SUFFIX)',
'<(PRODUCT_DIR)/osmesa.dll',
'<(PRODUCT_DIR)/ppapi_tests.dll',
'<(PRODUCT_DIR)/ppGoogleNaClPluginChrome.dll',
'<(PRODUCT_DIR)/ppapi_tests.dll',
'<(PRODUCT_DIR)/security_tests.dll',
'tools/build/repack_locales.py',
],
Expand Down
4 changes: 1 addition & 3 deletions chrome/chrome.isolate
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
'variables': {
'isolate_dependency_tracked': [
'<(PRODUCT_DIR)/chrome.pak',
'<(PRODUCT_DIR)/lib/libpeerconnection.so',
'<(PRODUCT_DIR)/libclearkeycdm.so',
'<(PRODUCT_DIR)/libclearkeycdmadapter.so',
'<(PRODUCT_DIR)/libffmpegsumo.so',
Expand Down Expand Up @@ -52,16 +51,15 @@
['OS=="win"', {
'variables': {
'isolate_dependency_tracked': [
'<(PRODUCT_DIR)/D3DCompiler_43.dll',
'<(PRODUCT_DIR)/chrome.dll',
'<(PRODUCT_DIR)/clearkeycdm.dll',
'<(PRODUCT_DIR)/clearkeycdmadapter.dll',
'<(PRODUCT_DIR)/D3DCompiler_43.dll',
'<(PRODUCT_DIR)/d3dcompiler_46.dll',
'<(PRODUCT_DIR)/ffmpegsumo.dll',
'<(PRODUCT_DIR)/icudt.dll',
'<(PRODUCT_DIR)/libEGL.dll',
'<(PRODUCT_DIR)/libGLESv2.dll',
'<(PRODUCT_DIR)/libpeerconnection.dll',
'<(PRODUCT_DIR)/nacl64<(EXECUTABLE_SUFFIX)',
'<(PRODUCT_DIR)/osmesa.dll',
'<(PRODUCT_DIR)/ppGoogleNaClPluginChrome.dll',
Expand Down
3 changes: 0 additions & 3 deletions chrome/interactive_ui_tests.isolate
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
'isolate_dependency_tracked': [
'../testing/xvfb.py',
'<(PRODUCT_DIR)/chrome.pak',
'<(PRODUCT_DIR)/lib/libpeerconnection.so',
'<(PRODUCT_DIR)/libffmpegsumo.so',
'<(PRODUCT_DIR)/locales/fr.pak',
'<(PRODUCT_DIR)/pyproto/google/__init__.py',
Expand Down Expand Up @@ -63,7 +62,6 @@
'variables': {
'isolate_dependency_tracked': [
'<(PRODUCT_DIR)/ffmpegsumo.so',
'<(PRODUCT_DIR)/libpeerconnection.so',
],
'isolate_dependency_untracked': [
'<(PRODUCT_DIR)/Chromium Framework.framework/',
Expand Down Expand Up @@ -91,7 +89,6 @@
'<(PRODUCT_DIR)/icudt.dll',
'<(PRODUCT_DIR)/libEGL.dll',
'<(PRODUCT_DIR)/libGLESv2.dll',
'<(PRODUCT_DIR)/libpeerconnection.dll',
'<(PRODUCT_DIR)/ppGoogleNaClPluginChrome.dll',
],
'isolate_dependency_untracked': [
Expand Down
2 changes: 0 additions & 2 deletions chrome/sync_integration_tests.isolate
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
'../testing/xvfb.py',
'<(PRODUCT_DIR)/chrome.pak',
'<(PRODUCT_DIR)/chrome_100_percent.pak',
'<(PRODUCT_DIR)/lib/libpeerconnection.so',
'<(PRODUCT_DIR)/libffmpegsumo.so',
'<(PRODUCT_DIR)/libppGoogleNaClPluginChrome.so',
'<(PRODUCT_DIR)/locales/en-US.pak',
Expand Down Expand Up @@ -58,7 +57,6 @@
'<(PRODUCT_DIR)/sync_integration_tests<(EXECUTABLE_SUFFIX)',
],
'isolate_dependency_tracked': [
'<(PRODUCT_DIR)/libpeerconnection.so',
'<(PRODUCT_DIR)/ffmpegsumo.so',
],
'isolate_dependency_untracked': [
Expand Down
3 changes: 0 additions & 3 deletions chrome/unit_tests.isolate
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
'isolate_dependency_tracked': [
'../testing/xvfb.py',
'<(PRODUCT_DIR)/chrome.pak',
'<(PRODUCT_DIR)/lib/libpeerconnection.so',
'<(PRODUCT_DIR)/libffmpegsumo.so',
'<(PRODUCT_DIR)/locales/fr.pak',
'<(PRODUCT_DIR)/xdisplaycheck<(EXECUTABLE_SUFFIX)',
Expand Down Expand Up @@ -65,7 +64,6 @@
'variables': {
'isolate_dependency_tracked': [
'<(PRODUCT_DIR)/ffmpegsumo.so',
'<(PRODUCT_DIR)/libpeerconnection.so',
],
'isolate_dependency_untracked': [
'<(PRODUCT_DIR)/Chromium Framework.framework/',
Expand All @@ -91,7 +89,6 @@
'isolate_dependency_tracked': [
'<(PRODUCT_DIR)/ffmpegsumo.dll',
'<(PRODUCT_DIR)/icudt.dll',
'<(PRODUCT_DIR)/libpeerconnection.dll',
],
'isolate_dependency_untracked': [
'../ppapi/lib/gl/include/KHR/',
Expand Down
5 changes: 1 addition & 4 deletions content/content_browsertests.isolate
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@
'isolate_dependency_tracked': [
'<(PRODUCT_DIR)/content_shell.pak',
'<(PRODUCT_DIR)/fonts.conf',
'<(PRODUCT_DIR)/lib/libpeerconnection.so',
'<(PRODUCT_DIR)/libclearkeycdm.so',
'<(PRODUCT_DIR)/libclearkeycdmadapter.so',
'<(PRODUCT_DIR)/libffmpegsumo.so',
Expand All @@ -51,10 +50,9 @@
'variables': {
'isolate_dependency_untracked': [
'<(PRODUCT_DIR)/clearkeycdmadapter.plugin',
'<(PRODUCT_DIR)/Content Shell.app/',
'<(PRODUCT_DIR)/content_resources.pak',
'<(PRODUCT_DIR)/Content Shell.app/',
'<(PRODUCT_DIR)/ffmpegsumo.so',
'<(PRODUCT_DIR)/libpeerconnection.so',
'<(PRODUCT_DIR)/plugins/npapi_test_plugin.plugin',
'<(PRODUCT_DIR)/plugins/TestNestscapePlugin.plugin',
],
Expand All @@ -64,7 +62,6 @@
'variables': {
'isolate_dependency_tracked': [
'<(PRODUCT_DIR)/ffmpegsumo.dll',
'<(PRODUCT_DIR)/libpeerconnection.dll',
],
'isolate_dependency_untracked': [
# The two directories below are only needed for
Expand Down
3 changes: 0 additions & 3 deletions content/content_unittests.isolate
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
'<(PRODUCT_DIR)/content_unittests<(EXECUTABLE_SUFFIX)',
],
'isolate_dependency_untracked': [
'<(PRODUCT_DIR)/lib/libpeerconnection.so',
'<(PRODUCT_DIR)/libffmpegsumo.so',
'<(PRODUCT_DIR)/test_data/',
],
Expand All @@ -38,7 +37,6 @@
'isolate_dependency_untracked': [
'<(PRODUCT_DIR)/content_resources.pak',
'<(PRODUCT_DIR)/ffmpegsumo.so',
'<(PRODUCT_DIR)/libpeerconnection.so',
],
},
}],
Expand All @@ -56,7 +54,6 @@
'isolate_dependency_untracked': [
'<(PRODUCT_DIR)/ffmpegsumo.dll',
'<(PRODUCT_DIR)/icudt.dll',
'<(PRODUCT_DIR)/libpeerconnection.dll',
],
},
}],
Expand Down
15 changes: 6 additions & 9 deletions third_party/libjingle/libjingle.gyp
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,8 @@
'libjingle_additional_deps%': [],
'libjingle_peerconnection_additional_deps%': [],
'libjingle_source%': "source",
'conditions': [
['OS=="win" or OS=="mac" or OS=="linux"', {
'libpeer_target_type%': 'loadable_module',
}, {
'libpeer_target_type%': 'static_library',
}],
],
'libpeer_target_type%': 'static_library',
'libpeer_allocator_shim%': 0,
},
'target_defaults': {
'defines': [
Expand Down Expand Up @@ -765,7 +760,8 @@
'<(libjingle_source)/talk/session/tunnel/tunnelsessionclient.h',
],
'conditions': [
['libpeer_target_type!="static_library" and OS!="mac"', {
['libpeer_allocator_shim==1 and '
'libpeer_target_type!="static_library" and OS!="mac"', {
'sources': [
'overrides/allocator_shim/allocator_stub.cc',
'overrides/allocator_shim/allocator_stub.h',
Expand Down Expand Up @@ -870,7 +866,8 @@
'libjingle_webrtc',
],
'conditions': [
['libpeer_target_type!="static_library"', {
['libpeer_allocator_shim==1 and '
'libpeer_target_type!="static_library"', {
'sources': [
'overrides/initialize_module.cc',
],
Expand Down
19 changes: 0 additions & 19 deletions third_party/libjingle/overrides/init_webrtc.cc
Original file line number Diff line number Diff line change
Expand Up @@ -51,21 +51,6 @@ static base::FilePath GetLibPeerConnectionPath() {
return path;
}

#if !defined(OS_WIN)
// On platforms other than Windows (i.e. mac and linux based ones),
// the location of the .so in the installed layout will be different relative
// to the loading module than it is in the build directory.
// GetLibPeerConnectionPath returns the path as it will be in the installed
// layout, but to support isolated tests, we need to also support loading the
// so in the build layout, which we do here.
// On Windows, these layouts are the same.
static base::FilePath GetLibPeerConnectionPathForTests() {
base::FilePath path;
CHECK(PathService::Get(base::DIR_MODULE, &path));
return path.Append(FILE_PATH_LITERAL("libpeerconnection.so"));
}
#endif

bool InitializeWebRtcModule() {
if (g_create_webrtc_media_engine)
return true; // InitializeWebRtcModule has already been called.
Expand All @@ -76,10 +61,6 @@ bool InitializeWebRtcModule() {
std::string error;
static base::NativeLibrary lib =
base::LoadNativeLibrary(path, &error);
#if !defined(OS_WIN)
if (!lib)
lib = base::LoadNativeLibrary(GetLibPeerConnectionPathForTests(), &error);
#endif
CHECK(lib);

InitializeModuleFunction initialize_module =
Expand Down

0 comments on commit 77bb500

Please sign in to comment.