Community
Participate
Working Groups
I'm using Eclipse 4.6.2 with CDT 9.2. When trying to debug a hello world binary on my computer, if I use a GDB located in a path with spaces, Gdb fails: Error with command: /tmp/dir spaces/gdb --version Cannot run program "/tmp/dir": Unknown reason If I add double quotes on the path from the UI, It works.
Salut Vincent, I can confirm that I see the launch failing, in the case where there is a space in GDB's path. As reported, it works if the path is surrounded by double-quotes, in the launch configuration However, reading the following discussion, it seems that this behavior (having to use the double-quotes around the path when spaces are present, was intended: https://bugs.eclipse.org/bugs/show_bug.cgi?id=458499 I think we missed Elena's suggestion ( https://bugs.eclipse.org/bugs/show_bug.cgi?id=458499#c9 ) , to have the launch configuration add the double quotes around GDB's path when it contains a space, when the user uses the "browse" button to set the path. I think that at least this way, the user can "learn" how to format the path, by looking how CDT does it. Thoughts?
Bonjour Marc, I agree. I've read the Elena suggestion, but didn't find anything in the code about that. I think this is the good way. By the way, I don't understand why it still working in win32 without quotes.
Salut Vincent, I'd like to get your opinion. I have a patch that makes the situation better, when the user uses the "Browser" button to select the path to GDB (based Alena's suggestion). However, I think we could keep the current bug, since the problem still happens when the user enters the path manually or pastes it from somewhere else. So I could create a new bug, for my fix, linking to this one here in the description. Else I could rephrase the current bug to reflect what was improved. What do you think? Thanks, Marc
New Gerrit change created: https://git.eclipse.org/r/89388
Marc, you can use this bugzilla number. No troubles. Thanks for your work.
Gerrit change https://git.eclipse.org/r/89388 was merged to [master]. Commit: http://git.eclipse.org/c/cdt/org.eclipse.cdt.git/commit/?id=7f6e7f8c9b5785a2e219d1fb030a3a197bedb665
Do you want this in 9.2.1?
Bonjour, Why not, I can wait for the 9.3, if it's too risky. Thanks for your work !
New Gerrit change created: https://git.eclipse.org/r/90568
Gerrit change https://git.eclipse.org/r/90568 was merged to [cdt_9_2]. Commit: http://git.eclipse.org/c/cdt/org.eclipse.cdt.git/commit/?id=0e074ad3c1c3e1fe83501d97845c291ea7df0876