Commit 3225ffb5 authored by Ken Rockot's avatar Ken Rockot Committed by Commit Bot

Ensure libmojo_core.so is built for Chrome OS builds

Makes the mojo_core shared library a data dependency of the chrome
binary target on Chrome OS to ensure that it gets built whenever chrome
gets built. A follow-up change to chromite will cause this to be
included in device deployments.

Also adds a linker script to ensure that symbol exports are limited to
MojoGetSystemThunks.

Bug: 822034
Change-Id: Iad03f28377ecc5094c2019b22c723d7705242230
Reviewed-on: https://chromium-review.googlesource.com/1024750Reviewed-by: default avatarJay Civelli <jcivelli@chromium.org>
Reviewed-by: default avatarDirk Pranke <dpranke@chromium.org>
Commit-Queue: Ken Rockot <rockot@chromium.org>
Cr-Commit-Position: refs/heads/master@{#552901}
parent 5029dde2
...@@ -298,6 +298,10 @@ if (!is_android && !is_mac) { ...@@ -298,6 +298,10 @@ if (!is_android && !is_mac) {
} }
} }
if (is_chromeos) {
data_deps += [ "//mojo/edk:mojo_core" ]
}
# These files are used by the installer so we need a public dep. # These files are used by the installer so we need a public dep.
public_deps += [ ":packed_resources" ] public_deps += [ ":packed_resources" ]
......
...@@ -220,9 +220,12 @@ if (is_chromeos || is_linux) { ...@@ -220,9 +220,12 @@ if (is_chromeos || is_linux) {
"//build/config:exe_and_shlib_deps", "//build/config:exe_and_shlib_deps",
"//mojo/public/c/system:headers", "//mojo/public/c/system:headers",
] ]
if (!is_component_build) { configs += [ ":export_only_thunks_api" ]
public_configs = [ "//build/config/gcc:rpath_for_built_shared_libraries" ] }
}
config("export_only_thunks_api") {
ldflags = [ "-Wl,--version-script=" +
rebase_path("//mojo/edk/export_only_thunks_api.lst") ]
} }
test("mojo_core_unittests") { test("mojo_core_unittests") {
......
# Copyright 2018 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.
# Linker script that ensures only MojoGetSystemThunks is exposed from the
# mojo_core library.
{
global:
MojoGetSystemThunks;
local:
*;
};
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment