This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
[patch] babeltrace compilation regression [Re: [PATCH] Avoid non-C++-enabled babeltrace versions]
- From: Jan Kratochvil <jan dot kratochvil at redhat dot com>
- To: Andreas Arnez <arnez at linux dot vnet dot ibm dot com>
- Cc: Pedro Alves <palves at redhat dot com>, gdb-patches at sourceware dot org
- Date: Sun, 3 Jul 2016 17:43:33 +0200
- Subject: [patch] babeltrace compilation regression [Re: [PATCH] Avoid non-C++-enabled babeltrace versions]
- Authentication-results: sourceware.org; auth=none
- References: <m3twinuxbs dot fsf at oc1027705133 dot ibm dot com> <5720AA62 dot 7040505 at redhat dot com> <m3potbuo2w dot fsf at oc1027705133 dot ibm dot com>
On Wed, 27 Apr 2016 16:24:23 +0200, Andreas Arnez wrote:
> Thanks, pushed after adjusting the commit message.
Since:
commit 2d681be471cf8aff8f296cb7713c39e9aa4fc2bb
Author: Andreas Arnez <arnez@linux.vnet.ibm.com>
Date: Wed Apr 27 15:52:16 2016 +0200
Avoid non-C++-enabled babeltrace versions
tested with:
libbabeltrace-devel-1.2.4-4.fc24.x86_64
libbabeltrace-devel-1.4.0-2.fc25.x86_64
it can no longer build due to:
configure:16435: gcc -o conftest -m64 -g3 -pipe -Wall -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -fno-diagnostics-show-caret -Werror -static-libstdc++ -static-libgcc conftest.c -ldl -ldl -lncurses -lm -ldl -lbabeltrace -lbabeltrace-ctf >&5
conftest.c: In function 'main':
conftest.c:208:7: error: 'pos' is a pointer; did you mean to use '->'?
Have you tested that your line
pos.type = BT_SEEK_BEGIN;
with some libbabeltrace version or was that just a typo?
OK for check-in?
Thanks,
Jan
gdb/ChangeLog
2016-07-03 Jan Kratochvil <jan.kratochvil@redhat.com>
* configure: Regenerate.
* configure.ac (HAVE_LIBBABELTRACE): Fix pos variable dereference.
diff --git a/gdb/configure.ac b/gdb/configure.ac
index 920c228..5e2e938 100644
--- a/gdb/configure.ac
+++ b/gdb/configure.ac
@@ -2309,7 +2309,7 @@ else
struct bt_ctf_event *event = NULL;
const struct bt_definition *scope;
- pos.type = BT_SEEK_BEGIN;
+ pos->type = BT_SEEK_BEGIN;
bt_iter_set_pos (bt_ctf_get_iter (NULL), pos);
scope = bt_ctf_get_top_level_scope (event,
BT_STREAM_EVENT_HEADER);