blob: fb31a330517d850a1f2e2a49c01398648fdb2562 [file] [log] [blame]
# Copyright 2018 The Fuchsia Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
# This file is compiled with the target toolchain. It is not actually used for
# the device, but is read by the zxdb tests on the host to test the symbol
# handling code.
# This should be the shared library toolchain only. Normally one could
# reference this in the default toolchain and that will redirect to the shared
# one.
assert(current_toolchain == "${default_toolchain}-shared")
# This rule will be called as a dependency of the zxdb tests.
shared_library("zxdb_symbol_test") {
sources = [
"line_lookup_symbol_test.cc",
"type_test.cc",
"zxdb_symbol_test.cc",
"zxdb_symbol_test2.cc",
]
}
# NOT RUN BY BUILD, REFERENCE ONLY ---------------------------------------------
# Generates a static line_lookup_test used in the ModuleSymbols tests.
# This output should not change, as the tests heavily rely on the binary layout
# being the same. Ideally, we would have a way of extracting only the debug
# information and test against that, instead on relying on pre-compiled
# binaries.
#
# This rule is run offline for the x64 architecture and the result is checked
# in for the testing.
#
# TO UPDATE
#
# - Uncomment this target.
# - Add a reference to it from some target that is in the build (one of the
# above ones is fine).
# - Build an x64 build. As of this writing it will generate
# "<out_dir>/x64-shared/lib.unstripped/libsymbol_test_so.so".
# - Copy that file to "libsymbol_test_so.targetso" in this directory.
#
# shared_library("symbol_test_so") {
# sources = [
# "line_lookup_symbol_test.cc",
# "zxdb_symbol_test.cc",
# "zxdb_symbol_test2.cc",
# ]
# }