Commit 78f06465 authored by Chad Austin's avatar Chad Austin Committed by Facebook GitHub Bot

split Symbolizer and SignalHandler into their own targets

Summary:
In the interest of using SignalHandler on macOS, which does not use
ELF, break some dependencies and split the targets.

Reviewed By: yfeldblum, luciang

Differential Revision: D22883896

fbshipit-source-id: e576b6e1684522fc1665c864780faea882d0263a
parent 1c320bc9
...@@ -19,6 +19,7 @@ ...@@ -19,6 +19,7 @@
#include <folly/portability/Config.h> #include <folly/portability/Config.h>
#if FOLLY_USE_SYMBOLIZER #if FOLLY_USE_SYMBOLIZER
#include <folly/experimental/symbolizer/ElfCache.h> // @manual
#include <folly/experimental/symbolizer/Symbolizer.h> // @manual #include <folly/experimental/symbolizer/Symbolizer.h> // @manual
#endif #endif
......
...@@ -32,7 +32,6 @@ ...@@ -32,7 +32,6 @@
#include <folly/Conv.h> #include <folly/Conv.h>
#include <folly/ScopeGuard.h> #include <folly/ScopeGuard.h>
#include <folly/experimental/symbolizer/ElfCache.h>
#include <folly/experimental/symbolizer/Symbolizer.h> #include <folly/experimental/symbolizer/Symbolizer.h>
#include <folly/portability/SysSyscall.h> #include <folly/portability/SysSyscall.h>
#include <folly/portability/Unistd.h> #include <folly/portability/Unistd.h>
......
...@@ -17,7 +17,6 @@ ...@@ -17,7 +17,6 @@
#pragma once #pragma once
#include <bitset> #include <bitset>
#include <functional>
namespace folly { namespace folly {
namespace symbolizer { namespace symbolizer {
......
...@@ -16,24 +16,24 @@ ...@@ -16,24 +16,24 @@
#pragma once #pragma once
#include <array>
#include <cstdint> #include <cstdint>
#include <memory> #include <memory>
#include <string> #include <string>
#include <folly/Range.h> #include <folly/Range.h>
#include <folly/experimental/symbolizer/Elf.h>
namespace folly { namespace folly {
namespace symbolizer { namespace symbolizer {
class ElfFile;
/** /**
* Represent a file path a s collection of three parts (base directory, * Represent a file path as a collection of three parts (base directory,
* subdirectory, and file). * subdirectory, and file).
*/ */
class Path { class Path {
public: public:
Path() {} Path() = default;
Path( Path(
folly::StringPiece baseDir, folly::StringPiece baseDir,
...@@ -121,7 +121,7 @@ struct SymbolizedFrame { ...@@ -121,7 +121,7 @@ struct SymbolizedFrame {
template <size_t N> template <size_t N>
struct FrameArray { struct FrameArray {
FrameArray() {} FrameArray() = default;
size_t frameCount = 0; size_t frameCount = 0;
uintptr_t addresses[N]; uintptr_t addresses[N];
......
...@@ -36,6 +36,7 @@ ...@@ -36,6 +36,7 @@
#include <folly/String.h> #include <folly/String.h>
#include <folly/experimental/symbolizer/Dwarf.h> #include <folly/experimental/symbolizer/Dwarf.h>
#include <folly/experimental/symbolizer/Elf.h> #include <folly/experimental/symbolizer/Elf.h>
#include <folly/experimental/symbolizer/ElfCache.h>
#include <folly/experimental/symbolizer/LineReader.h> #include <folly/experimental/symbolizer/LineReader.h>
#include <folly/lang/SafeAssert.h> #include <folly/lang/SafeAssert.h>
#include <folly/portability/SysMman.h> #include <folly/portability/SysMman.h>
......
...@@ -28,8 +28,6 @@ ...@@ -28,8 +28,6 @@
#include <folly/Synchronized.h> #include <folly/Synchronized.h>
#include <folly/container/EvictingCacheMap.h> #include <folly/container/EvictingCacheMap.h>
#include <folly/experimental/symbolizer/Dwarf.h> #include <folly/experimental/symbolizer/Dwarf.h>
#include <folly/experimental/symbolizer/Elf.h>
#include <folly/experimental/symbolizer/ElfCache.h>
#include <folly/experimental/symbolizer/StackTrace.h> #include <folly/experimental/symbolizer/StackTrace.h>
#include <folly/experimental/symbolizer/SymbolizedFrame.h> #include <folly/experimental/symbolizer/SymbolizedFrame.h>
#include <folly/io/IOBuf.h> #include <folly/io/IOBuf.h>
...@@ -37,6 +35,8 @@ ...@@ -37,6 +35,8 @@
namespace folly { namespace folly {
namespace symbolizer { namespace symbolizer {
class ElfCacheBase;
class ElfCache;
class Symbolizer; class Symbolizer;
/** /**
......
...@@ -15,6 +15,7 @@ ...@@ -15,6 +15,7 @@
*/ */
#include <signal.h> #include <signal.h>
#include <array>
#include <folly/experimental/symbolizer/SignalHandler.h> #include <folly/experimental/symbolizer/SignalHandler.h>
......
...@@ -22,6 +22,7 @@ ...@@ -22,6 +22,7 @@
#include <folly/Demangle.h> #include <folly/Demangle.h>
#include <folly/Range.h> #include <folly/Range.h>
#include <folly/String.h> #include <folly/String.h>
#include <folly/experimental/symbolizer/ElfCache.h>
#include <folly/experimental/symbolizer/SymbolizedFrame.h> #include <folly/experimental/symbolizer/SymbolizedFrame.h>
#include <folly/experimental/symbolizer/test/SymbolizerTestUtils.h> #include <folly/experimental/symbolizer/test/SymbolizerTestUtils.h>
#include <folly/portability/GTest.h> #include <folly/portability/GTest.h>
......
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