Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tools: install gdbinit from v8 to $PREFIX/share #2123

Closed
wants to merge 1 commit into from

Conversation

ofrobots
Copy link
Contributor

@ofrobots ofrobots commented Jul 7, 2015

gdbinit provided by V8 can be very useful for low-level debugging of crashes in node and in binary addons. Most useful commands at 'jst' for JS stack traces and 'job' for printing a heap object.

This patch installs the file at $PREFIX/share/tools/gdbinit making it available on installed Node.js binaries too.

Here's a sample session that uses these gdb macros: https://gist.github.com/ofrobots/0bdcab89771221ace68d

@ofrobots
Copy link
Contributor Author

ofrobots commented Jul 7, 2015

This was suggested in #2076 (comment)

@@ -149,6 +149,8 @@ def files(action):
# behave similarly for systemtap
action(['src/node.stp'], 'share/systemtap/tapset/')

action(['deps/v8/tools/gdbinit'], 'share/tools/')
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Isn't /usr/share/node or /usr/share/doc/node a more logical place?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes indeed. Fixed.

@ofrobots ofrobots force-pushed the install-gdbinit branch 2 times, most recently from 4b66274 to 6aac5d7 Compare July 7, 2015 14:35
@bnoordhuis
Copy link
Member

LGTM

@Fishrock123 Fishrock123 added the build Issues and PRs related to build files or the CI. label Jul 7, 2015
@bnoordhuis
Copy link
Member

On second thought, I think this should also be added to the %files section in tools/rpm/iojs.spec.

@ofrobots
Copy link
Contributor Author

ofrobots commented Jul 7, 2015

Done. I am not too familiar with rpm packaging, so PTAL.

@bnoordhuis
Copy link
Member

I try to keep them in alphabetical order but that's nitpicking. LGTM.

gdbinit provided by V8 can be very useful for low-level debugging of
crashes in node and in binary addons. Most useful commands at 'jst'
for JS stack traces and 'job' for printing a heap object.

This patch installs the file at $PREFIX/share/tools/gdbinit.
@ofrobots
Copy link
Contributor Author

ofrobots commented Jul 7, 2015

Fixed.

ofrobots added a commit that referenced this pull request Jul 7, 2015
gdbinit provided by V8 can be very useful for low-level debugging of
crashes in node and in binary addons. Most useful commands at 'jst'
for JS stack traces and 'job' for printing a heap object.

This patch installs the file at $PREFIX/share/doc/node/gdbinit.

Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
PR-URL: #2123
@ofrobots
Copy link
Contributor Author

ofrobots commented Jul 7, 2015

Landed in ee3ce2e.

@ofrobots ofrobots closed this Jul 7, 2015
@ofrobots ofrobots deleted the install-gdbinit branch July 7, 2015 22:15
mscdex pushed a commit to mscdex/io.js that referenced this pull request Jul 9, 2015
gdbinit provided by V8 can be very useful for low-level debugging of
crashes in node and in binary addons. Most useful commands at 'jst'
for JS stack traces and 'job' for printing a heap object.

This patch installs the file at $PREFIX/share/doc/node/gdbinit.

Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
PR-URL: nodejs#2123
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build Issues and PRs related to build files or the CI.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants