Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fix v8dbg_* symbols not being linked in when statically linking v8

When linking static libraries, linkers usually skip objects which
they consider not to be used by anything else in the final binary.

Fix this by generating a header file instead of a cc file, and
including that in a module which is certainly going to be linked.
  • Loading branch information...
commit f7013f4fcb82a39fb58fa8ac4a3a5c919c52525d 1 parent e2bcff9
@ackalker authored
Showing with 12 additions and 2 deletions.
  1. +4 −0 deps/v8/src/v8.cc
  2. +8 −2 deps/v8/tools/gyp/v8.gyp
View
4 deps/v8/src/v8.cc
@@ -44,6 +44,10 @@
#include "serialize.h"
#include "store-buffer.h"
+#if defined(POSTMORTEM_SUPPORT)
+#include <debug-support.h>
+#endif
+
namespace v8 {
namespace internal {
View
10 deps/v8/tools/gyp/v8.gyp
@@ -744,8 +744,14 @@
],
}],
['v8_postmortem_support=="true"', {
+ 'defines': [
+ 'POSTMORTEM_SUPPORT'
+ ],
+ 'include_dirs': [
+ '<(SHARED_INTERMEDIATE_DIR)'
+ ],
'sources': [
- '<(SHARED_INTERMEDIATE_DIR)/debug-support.cc',
+ '<(SHARED_INTERMEDIATE_DIR)/debug-support.h',
],
'dependencies': ['postmortem-metadata']
}],
@@ -841,7 +847,7 @@
'<@(heapobject_files)',
],
'outputs': [
- '<(SHARED_INTERMEDIATE_DIR)/debug-support.cc',
+ '<(SHARED_INTERMEDIATE_DIR)/debug-support.h',
],
'action': [
'python',
Please sign in to comment.
Something went wrong with that request. Please try again.