summaryrefslogtreecommitdiffstats
path: root/mkspecs/features
diff options
context:
space:
mode:
authorJoerg Bornemann <joerg.bornemann@nokia.com>2011-11-10 11:43:51 (GMT)
committerJoerg Bornemann <joerg.bornemann@nokia.com>2011-11-10 11:45:39 (GMT)
commit122fa6b53c33364a4687919191e55899acb43797 (patch)
tree77a861c4fd56c282652b21edec932a76e82898bd /mkspecs/features
parent7eb770aed35fee50ff98c12e390dcb02c72b5132 (diff)
downloadQt-122fa6b53c33364a4687919191e55899acb43797.zip
Qt-122fa6b53c33364a4687919191e55899acb43797.tar.gz
Qt-122fa6b53c33364a4687919191e55899acb43797.tar.bz2
fix gdb_dwarf_index.prf for applications, take two
Handle the case of an empty DESTDIR. Done-with: ossi
Diffstat (limited to 'mkspecs/features')
-rw-r--r--mkspecs/features/unix/gdb_dwarf_index.prf5
1 files changed, 3 insertions, 2 deletions
diff --git a/mkspecs/features/unix/gdb_dwarf_index.prf b/mkspecs/features/unix/gdb_dwarf_index.prf
index 7771ed4..e3f79cd 100644
--- a/mkspecs/features/unix/gdb_dwarf_index.prf
+++ b/mkspecs/features/unix/gdb_dwarf_index.prf
@@ -4,12 +4,13 @@
QMAKE_GDB_INDEX = { test -z \"$(DESTDIR)\" || cd \"$(DESTDIR)\"; } &&
QMAKE_GDB_DIR = .
} else {
- QMAKE_GDB_DIR = $(DESTDIR)
+ QMAKE_GDB_INDEX = { test -n \"$(DESTDIR)\" && DESTDIR=\"$(DESTDIR)\" || DESTDIR=.; } &&
+ QMAKE_GDB_DIR = \$\$DESTDIR
}
QMAKE_GDB_INDEX += \
test \$\$(gdb --version | sed -e \'s,[^0-9]\\+\\([0-9]\\)\\.\\([0-9]\\).*,\\1\\2,;q\') -gt 72 && \
- gdb --nx --batch --quiet -ex \'set confirm off\' -ex \'save gdb-index $$QMAKE_GDB_DIR\' -ex quit \'$(TARGET)\' && \
+ gdb --nx --batch --quiet -ex \'set confirm off\' -ex \"save gdb-index $$QMAKE_GDB_DIR\" -ex quit \'$(TARGET)\' && \
test -f $(TARGET).gdb-index && \
$$QMAKE_OBJCOPY --add-section \'.gdb_index=$(TARGET).gdb-index\' --set-section-flags \'.gdb_index=readonly\' \'$(TARGET)\' \'$(TARGET)\' && \
$$QMAKE_DEL_FILE $(TARGET).gdb-index || true