• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (C) 2015 The Android Open Source Project
2#
3# Licensed under the Apache License, Version 2.0 (the "License");
4# you may not use this file except in compliance with the License.
5# You may obtain a copy of the License at
6#
7#      http://www.apache.org/licenses/LICENSE-2.0
8#
9# Unless required by applicable law or agreed to in writing, software
10# distributed under the License is distributed on an "AS IS" BASIS,
11# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12# See the License for the specific language governing permissions and
13# limitations under the License.
14
15LOCAL_PATH := $(call my-dir)
16
17# Static library.
18# =================================================
19include $(CLEAR_VARS)
20
21LOCAL_MODULE := breakpad_client
22
23LOCAL_CPP_EXTENSION := .cc
24
25LOCAL_SRC_FILES := \
26    src/client/linux/dump_writer_common/seccomp_unwinder.cc \
27    src/client/linux/dump_writer_common/thread_info.cc \
28    src/client/linux/dump_writer_common/ucontext_reader.cc \
29    src/client/linux/handler/minidump_descriptor.cc \
30    src/client/linux/minidump_writer/linux_core_dumper.cc \
31    src/client/linux/minidump_writer/linux_dumper.cc \
32    src/client/linux/minidump_writer/linux_ptrace_dumper.cc \
33    src/client/linux/minidump_writer/minidump_writer.cc \
34    src/client/minidump_file_writer.cc \
35    src/common/convert_UTF.c \
36    src/common/linux/elf_core_dump.cc \
37    src/common/linux/elfutils.cc \
38    src/common/linux/file_id.cc \
39    src/common/linux/guid_creator.cc \
40    src/common/linux/linux_libc_support.cc \
41    src/common/linux/memory_mapped_file.cc \
42    src/common/linux/safe_readlink.cc \
43    src/common/string_conversion.cc \
44
45LOCAL_C_INCLUDES := \
46    $(LOCAL_PATH)/src/common/android/include \
47    $(LOCAL_PATH)/src \
48
49LOCAL_CFLAGS := \
50    -Wno-unused-parameter \
51    -Wno-tautological-compare
52
53LOCAL_EXPORT_C_INCLUDE_DIRS := $(LOCAL_C_INCLUDES)
54
55# Work around b/25435766 core2md segfault.
56LOCAL_CLANG_CFLAGS_x86 += -mno-stackrealign
57LOCAL_CLANG := true
58
59include $(BUILD_STATIC_LIBRARY)
60
61# core2md binary.
62# =================================================
63include $(CLEAR_VARS)
64
65LOCAL_MODULE := core2md
66
67LOCAL_CPP_EXTENSION := .cc
68
69LOCAL_SRC_FILES := src/tools/linux/core2md/core2md.cc
70
71LOCAL_STATIC_LIBRARIES := breakpad_client
72
73# Work around b/25435766 core2md segfault.
74LOCAL_CLANG_CFLAGS_x86 += -mno-stackrealign
75LOCAL_CLANG := true
76
77include $(BUILD_EXECUTABLE)
78
79# dump_syms host tool.
80# =================================================
81include $(CLEAR_VARS)
82LOCAL_MODULE := dump_syms
83LOCAL_MODULE_HOST_OS := linux
84LOCAL_CLANG := true
85LOCAL_CPPFLAGS_linux := -DHAVE_A_OUT_H -Wno-unused-parameter
86LOCAL_CPP_EXTENSION := .cc
87LOCAL_C_INCLUDES := \
88    $(LOCAL_PATH)/src
89LOCAL_SRC_FILES := \
90    src/common/dwarf/bytereader.cc \
91    src/common/dwarf/dwarf2diehandler.cc \
92    src/common/dwarf/dwarf2reader.cc \
93    src/common/dwarf_cfi_to_module.cc \
94    src/common/dwarf_cu_to_module.cc \
95    src/common/dwarf_line_to_module.cc \
96    src/common/language.cc \
97    src/common/module.cc \
98    src/common/stabs_reader.cc \
99    src/common/stabs_to_module.cc
100LOCAL_SRC_FILES_linux := \
101    src/common/linux/crc32.cc \
102    src/common/linux/dump_symbols.cc \
103    src/common/linux/elfutils.cc \
104    src/common/linux/elf_symbols_to_module.cc \
105    src/common/linux/file_id.cc \
106    src/common/linux/linux_libc_support.cc \
107    src/common/linux/memory_mapped_file.cc \
108    src/tools/linux/dump_syms/dump_syms.cc
109include $(BUILD_HOST_EXECUTABLE)
110
111# sym_upload host tool.
112# =================================================
113include $(CLEAR_VARS)
114LOCAL_MODULE := sym_upload
115LOCAL_MODULE_HOST_OS := linux
116LOCAL_CLANG := true
117LOCAL_LDLIBS := -ldl
118LOCAL_CPP_EXTENSION := .cc
119LOCAL_C_INCLUDES := \
120    $(LOCAL_PATH)/src
121LOCAL_SRC_FILES_linux := \
122    src/common/linux/http_upload.cc \
123    src/tools/linux/symupload/sym_upload.cc
124include $(BUILD_HOST_EXECUTABLE)
125