Skip to content

Commit

Permalink
deps: cherry-pick 1383d00 from v8 upstream
Browse files Browse the repository at this point in the history
Original commit message:

    tools: fix tickprocessor Cpp symbols on mac

    Despite man page documentation:

        -f Display the symbol table of a dynamic library flat (as one
           file not separate modules).

    `nm` on mac treats `-f` as a shorthand for `-format`. The `-f` argument
    does not seem to be required, so just remove it completely.

    (For `-format` documentation - see `nm --help` on mac).

    BUG=

    Review URL: https://codereview.chromium.org/1840633002

    Cr-Commit-Position: refs/heads/master@{#35445}

Fix: #5903
PR-URL: #6179
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Michaël Zasso <mic.besace@gmail.com>
  • Loading branch information
indutny authored and Myles Borins committed May 3, 2016
1 parent ad91bed commit 6416ebb
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion deps/v8/tools/tickprocessor.js
Original file line number Diff line number Diff line change
Expand Up @@ -750,8 +750,11 @@ inherits(MacCppEntriesProvider, UnixCppEntriesProvider);
MacCppEntriesProvider.prototype.loadSymbols = function(libName) {
this.parsePos = 0;
libName = this.targetRootFS + libName;

// It seems that in OS X `nm` thinks that `-f` is a format option, not a
// "flat" display option flag.
try {
this.symbols = [os.system(this.nmExec, ['-n', '-f', libName], -1, -1), ''];
this.symbols = [os.system(this.nmExec, ['-n', libName], -1, -1), ''];
} catch (e) {
// If the library cannot be found on this system let's not panic.
this.symbols = '';
Expand Down

0 comments on commit 6416ebb

Please sign in to comment.