summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMilian Wolff <milian.wolff@kdab.com>2017-03-14 23:51:58 +0100
committerMilian Wolff <milian.wolff@kdab.com>2017-03-21 14:46:39 +0000
commit2f1f3e46942b6bdd2c69e3057de19118cc6f3bb7 (patch)
tree67035910d5091a20e406e868fa9164957c8c6451
parentb6abdc12b61525e961a5d9c83d7829eab26a184b (diff)
Use ~/.debug as default debug path
The previous default of .debug/ tried to look for a folder called .debug in the current working directory. That usually does not exist, the .debug cache folder usually resides in your home folder. This path is now searched by default. Change-Id: I86f86743d2b3bde00dd210ef7802c8079d27b5ce Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
-rw-r--r--app/main.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/app/main.cpp b/app/main.cpp
index c929627..e679f0c 100644
--- a/app/main.cpp
+++ b/app/main.cpp
@@ -27,6 +27,7 @@
#include "perfstdin.h"
#include <QFile>
+#include <QDir>
#include <QDebug>
#include <QtEndian>
#include <QCoreApplication>
@@ -112,9 +113,9 @@ int main(int argc, char *argv[])
"Look for debug information in <path>. "
"You can specify multiple paths separated by ':'. "
"Relative paths are relative to the original file's path. "
- "The default is: <sysroot>/usr/lib/debug:.debug/ ."),
+ "The default is: <sysroot>/usr/lib/debug:~/.debug:.debug ."),
QLatin1String("path"),
- QLatin1String("/usr/lib/debug:.debug/"));
+ QString("/usr/lib/debug:%1/.debug:.debug").arg(QDir::homePath()));
parser.addOption(debug);
QCommandLineOption extra(QLatin1String("extra"),