Fix missing of symbols issue on Release build
This commit is contained in:
parent
41f356a94d
commit
82d796ded4
5 changed files with 23 additions and 3 deletions
|
@ -6,6 +6,9 @@
|
|||
|
||||
#include <io.h>
|
||||
|
||||
#include "v8-profiler.h"
|
||||
#include "v8-inspector.h"
|
||||
|
||||
namespace node {
|
||||
|
||||
int open_osfhandle(intptr_t osfhandle, int flags) {
|
||||
|
@ -16,4 +19,12 @@ int close(int fd) {
|
|||
return _close(fd);
|
||||
}
|
||||
|
||||
void ReferenceSymbols() {
|
||||
// Following symbols are used by electron.exe but got stripped by compiler,
|
||||
// for some reason, adding them to ForceSymbolReferences does not work,
|
||||
// probably because of VC++ bugs.
|
||||
v8::TracingCpuProfiler::Create(nullptr);
|
||||
reinterpret_cast<v8_inspector::V8InspectorClient*>(nullptr)->unmuteMetrics(0);
|
||||
}
|
||||
|
||||
} // namespace node
|
||||
|
|
|
@ -21,6 +21,9 @@ namespace node {
|
|||
__declspec(dllexport) int open_osfhandle(intptr_t osfhandle, int flags);
|
||||
__declspec(dllexport) int close(int fd);
|
||||
|
||||
// A trick to force referencing symbols.
|
||||
__declspec(dllexport) void ReferenceSymbols();
|
||||
|
||||
} // namespace node
|
||||
|
||||
#endif // ATOM_NODE_OSFHANDLE_H_
|
||||
|
|
|
@ -155,13 +155,15 @@
|
|||
'-ldbghelp.lib',
|
||||
'-lshlwapi.lib',
|
||||
],
|
||||
# Fix the linking error with icu.
|
||||
# Force referencing symbols of ICU and v8_inspector to make sure
|
||||
# they are included in the final DLL.
|
||||
'conditions': [
|
||||
['libchromiumcontent_component==0', {
|
||||
'variables': {
|
||||
'conditions': [
|
||||
['target_arch=="ia32"', {
|
||||
'reference_symbols': [
|
||||
# ICU symbols:
|
||||
'_u_errorName_58',
|
||||
'_ubidi_setPara_58',
|
||||
'_ucsdet_getName_58',
|
||||
|
@ -177,6 +179,7 @@
|
|||
],
|
||||
}, {
|
||||
'reference_symbols': [
|
||||
# ICU symbols:
|
||||
'u_errorName_58',
|
||||
'ubidi_setPara_58',
|
||||
'ucsdet_getName_58',
|
||||
|
@ -188,6 +191,9 @@
|
|||
'usearch_setPattern_58',
|
||||
'?createInstance@Transliterator@icu_58@@SAPEAV12@AEBVUnicodeString@2@W4UTransDirection@@AEAW4UErrorCode@@@Z',
|
||||
'??0MeasureFormat@icu_58@@QEAA@AEBVLocale@1@W4UMeasureFormatWidth@@AEAW4UErrorCode@@@Z',
|
||||
# v8_inspector symbols:
|
||||
'?DOM@ReasonEnum@Paused@API@Debugger@protocol@v8_inspector@@3PEBDEB',
|
||||
'?canDispatchMethod@V8InspectorSession@v8_inspector@@SA_NAEBVStringView@2@@Z',
|
||||
],
|
||||
}],
|
||||
],
|
||||
|
|
|
@ -9,7 +9,7 @@ import sys
|
|||
BASE_URL = os.getenv('LIBCHROMIUMCONTENT_MIRROR') or \
|
||||
'https://s3.amazonaws.com/github-janky-artifacts/libchromiumcontent'
|
||||
LIBCHROMIUMCONTENT_COMMIT = os.getenv('LIBCHROMIUMCONTENT_COMMIT') or \
|
||||
'0360b49dc59dcaad80bc056c9c9678273d4200e6'
|
||||
'628ae34823d133842faf8f45c2b2741e4ca74e53'
|
||||
|
||||
PLATFORM = {
|
||||
'cygwin': 'win32',
|
||||
|
|
2
vendor/brightray
vendored
2
vendor/brightray
vendored
|
@ -1 +1 @@
|
|||
Subproject commit e7ef0ea4e7d45549128d6304c2faf732daedca2d
|
||||
Subproject commit 280492556cfcdf56274d18bccb4f9560f43a2a91
|
Loading…
Reference in a new issue