Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Marco Bubke
flatpak-qt-creator
Commits
a10e3a04
Commit
a10e3a04
authored
Apr 18, 2011
by
Friedemann Kleint
Browse files
Debugger[gdb]: Locate objdump in MinGW for release build check.
parent
6630908b
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/plugins/debugger/gdb/localplaingdbadapter.cpp
View file @
a10e3a04
...
...
@@ -38,6 +38,8 @@
#include "debuggercore.h"
#include "debuggerstringutils.h"
#include <projectexplorer/abi.h>
#include <utils/qtcassert.h>
#include <QtCore/QFileInfo>
...
...
@@ -126,6 +128,18 @@ void LocalPlainGdbAdapter::shutdownAdapter()
void
LocalPlainGdbAdapter
::
checkForReleaseBuild
()
{
QString
objDump
=
_
(
"objdump"
);
// Windows: Locate objdump in the debuggee's (MinGW) environment
if
(
ProjectExplorer
::
Abi
::
hostAbi
().
os
()
==
ProjectExplorer
::
Abi
::
WindowsOS
&&
startParameters
().
environment
.
size
())
{
objDump
=
startParameters
().
environment
.
searchInPath
(
objDump
);
}
else
{
objDump
=
Utils
::
Environment
::
systemEnvironment
().
searchInPath
(
objDump
);
}
if
(
objDump
.
isEmpty
())
{
showMessage
(
_
(
"Could not locate objdump command for release build check"
),
LogWarning
);
return
;
}
// Quick check for a "release" build
QProcess
proc
;
QStringList
args
;
...
...
@@ -133,7 +147,7 @@ void LocalPlainGdbAdapter::checkForReleaseBuild()
args
.
append
(
_
(
"-j"
));
args
.
append
(
_
(
".debug_info"
));
args
.
append
(
startParameters
().
executable
);
proc
.
start
(
_
(
"
obj
d
ump
"
)
,
args
);
proc
.
start
(
obj
D
ump
,
args
);
proc
.
closeWriteChannel
();
if
(
!
proc
.
waitForStarted
())
{
showMessage
(
_
(
"OBJDUMP PROCESS COULD NOT BE STARTED. "
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment