tools/profiler/moz.build

Wed, 31 Dec 2014 06:09:35 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Wed, 31 Dec 2014 06:09:35 +0100
changeset 0
6474c204b198
permissions
-rw-r--r--

Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.

michael@0 1 # -*- Mode: python; c-basic-offset: 4; indent-tabs-mode: nil; tab-width: 40 -*-
michael@0 2 # vim: set filetype=python:
michael@0 3 # This Source Code Form is subject to the terms of the Mozilla Public
michael@0 4 # License, v. 2.0. If a copy of the MPL was not distributed with this
michael@0 5 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
michael@0 6
michael@0 7 if CONFIG['MOZ_ENABLE_PROFILER_SPS']:
michael@0 8 FAIL_ON_WARNINGS = True
michael@0 9
michael@0 10 XPIDL_MODULE = 'profiler'
michael@0 11 XPIDL_SOURCES += [
michael@0 12 'nsIProfiler.idl',
michael@0 13 'nsIProfileSaveEvent.idl',
michael@0 14 ]
michael@0 15 EXPORTS += [
michael@0 16 'GeckoProfilerFunc.h',
michael@0 17 'GeckoProfilerImpl.h',
michael@0 18 'ProfilerMarkers.h',
michael@0 19 'PseudoStack.h',
michael@0 20 'shared-libraries.h',
michael@0 21 ]
michael@0 22 EXTRA_JS_MODULES = [
michael@0 23 'Profiler.jsm',
michael@0 24 ]
michael@0 25 UNIFIED_SOURCES += [
michael@0 26 'BreakpadSampler.cpp',
michael@0 27 'JSStreamWriter.cpp',
michael@0 28 'nsProfiler.cpp',
michael@0 29 'nsProfilerFactory.cpp',
michael@0 30 'platform.cpp',
michael@0 31 'ProfileEntry.cpp',
michael@0 32 'ProfilerBacktrace.cpp',
michael@0 33 'ProfilerIOInterposeObserver.cpp',
michael@0 34 'ProfilerMarkers.cpp',
michael@0 35 'SaveProfileTask.cpp',
michael@0 36 'SyncProfile.cpp',
michael@0 37 'TableTicker.cpp',
michael@0 38 'UnwinderThread2.cpp',
michael@0 39 ]
michael@0 40
michael@0 41 # This file cannot be built in unified mode because of name clashes with mozglue headers on Android.
michael@0 42 SOURCES += [
michael@0 43 'local_debug_info_symbolizer.cc',
michael@0 44 ]
michael@0 45
michael@0 46 if CONFIG['OS_TARGET'] in ('Android', 'Linux'):
michael@0 47 UNIFIED_SOURCES += [
michael@0 48 'AutoObjectMapper.cpp',
michael@0 49 'LulCommon.cpp',
michael@0 50 'LulDwarf.cpp',
michael@0 51 'LulDwarfSummariser.cpp',
michael@0 52 'LulElf.cpp',
michael@0 53 'LulMain.cpp',
michael@0 54 'LulRWLock.cpp',
michael@0 55 ]
michael@0 56 # These files cannot be built in unified mode because of name clashes with mozglue headers on Android.
michael@0 57 SOURCES += [
michael@0 58 'platform-linux.cc',
michael@0 59 'shared-libraries-linux.cc',
michael@0 60 ]
michael@0 61 if CONFIG['CPU_ARCH'] == 'arm':
michael@0 62 UNIFIED_SOURCES += [
michael@0 63 'LulExidx.cpp',
michael@0 64 ]
michael@0 65 SOURCES += [
michael@0 66 'EHABIStackWalk.cpp',
michael@0 67 ]
michael@0 68 elif CONFIG['OS_TARGET'] == 'Darwin':
michael@0 69 UNIFIED_SOURCES += [
michael@0 70 'platform-macos.cc',
michael@0 71 'shared-libraries-macos.cc',
michael@0 72 'shim_mac_dump_syms.mm',
michael@0 73 ]
michael@0 74 elif CONFIG['OS_TARGET'] == 'WINNT':
michael@0 75 SOURCES += [
michael@0 76 'IntelPowerGadget.cpp',
michael@0 77 'platform-win32.cc',
michael@0 78 'shared-libraries-win32.cc',
michael@0 79 ]
michael@0 80
michael@0 81 LOCAL_INCLUDES += [
michael@0 82 '/ipc/chromium/src',
michael@0 83 '/mozglue/linker',
michael@0 84 '/toolkit/crashreporter/google-breakpad/src',
michael@0 85 ]
michael@0 86
michael@0 87 # We need access to Breakpad's getcontext(3) which is suitable for Android
michael@0 88 if CONFIG['OS_TARGET'] == 'Android':
michael@0 89 LOCAL_INCLUDES += [
michael@0 90 '/toolkit/crashreporter/google-breakpad/src/common/android/include',
michael@0 91 ]
michael@0 92
michael@0 93 if CONFIG['ANDROID_CPU_ARCH'] == 'armeabi':
michael@0 94 DEFINES['ARCH_ARMV6'] = True
michael@0 95
michael@0 96 if CONFIG['ENABLE_TESTS']:
michael@0 97 DIRS += ['tests/gtest']
michael@0 98
michael@0 99 FINAL_LIBRARY = 'xul'
michael@0 100
michael@0 101 EXPORTS += [
michael@0 102 'GeckoProfiler.h',
michael@0 103 ]
michael@0 104
michael@0 105 if CONFIG['MOZ_TASK_TRACER']:
michael@0 106 EXPORTS += [
michael@0 107 'GeckoTaskTracer.h',
michael@0 108 'GeckoTaskTracerImpl.h',
michael@0 109 'TracedTaskCommon.h',
michael@0 110 ]
michael@0 111 UNIFIED_SOURCES += [
michael@0 112 'GeckoTaskTracer.cpp',
michael@0 113 'TracedTaskCommon.cpp',
michael@0 114 ]
michael@0 115
michael@0 116 XPCSHELL_TESTS_MANIFESTS += ['tests/xpcshell.ini']

mercurial