From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2980 invoked by alias); 27 Apr 2016 19:39:02 -0000 Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org Received: (qmail 2937 invoked by uid 89); 27 Apr 2016 19:39:01 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.9 required=5.0 tests=BAYES_00,RP_MATCHES_RCVD,SPF_HELO_PASS autolearn=ham version=3.3.2 spammy=junior X-HELO: mx1.redhat.com Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-GCM-SHA384 encrypted) ESMTPS; Wed, 27 Apr 2016 19:38:51 +0000 Received: from int-mx10.intmail.prod.int.phx2.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 66DBC12B23; Wed, 27 Apr 2016 19:38:50 +0000 (UTC) Received: from localhost (unused-10-15-17-51.yyz.redhat.com [10.15.17.51]) by int-mx10.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id u3RJcnLR019680 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Wed, 27 Apr 2016 15:38:50 -0400 From: Sergio Durigan Junior To: Antoine Tremblay Cc: Pedro Alves , "gdb\@sourceware.org" Subject: Re: 32-bit buildbot builders broken [Re: Your commit 'Build GDB as a C++ program by default' broke GDB] References: <571898CF.6060906@redhat.com> <877ffqr89o.fsf@sergiodj.net> X-URL: http://blog.sergiodj.net Date: Wed, 27 Apr 2016 19:39:00 -0000 In-Reply-To: (Antoine Tremblay's message of "Wed, 27 Apr 2016 15:06:24 -0400") Message-ID: <87potalu46.fsf@redhat.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-IsSubscribed: yes X-SW-Source: 2016-04/txt/msg00053.txt.bz2 On Wednesday, April 27 2016, Antoine Tremblay wrote: > Sergio Durigan Junior writes: > >> On Thursday, April 21 2016, Pedro Alves wrote: >> >>>> g++ -g -O2 -I. -I../../binutils-gdb/gdb -I../../binutils-gdb/gdb/common >>>> -I../../binutils-gdb/gdb/config >>> ... >>>> -I../../binutils-gdb/gdb/../libdecnumber >>>> -I../../binutils-gdb/gdb/gnulib/import -Ibuild-gnulib/import -DTUI=1 >>>> -I/usr/include/python2.7 -I/usr/include/python2.7 -Wall >>>> -Wpointer-arith -Wno-unused -Wunused-value -Wunused-function >>>> -Wno-switch -Wno-char-subscripts -Wempty-body -Wno-sign-compare >>>> -Wno-write-strings -Wno-narrowing -Wformat-nonliteral -Werror -c -o >>>> linux-thread-db.o -MT linux-thread-db.o -MMD -MP -MF >>>> .deps/linux-thread-db.Tpo ../../binutils-gdb/gdb/linux-thread-db.c >>>> In file included from ../../binutils-gdb/gdb/i386-linux-nat.c:25:0: >>>> ../../binutils-gdb/gdb/i386-linux-nat.c: In function void fetch_regs(regcache*, int): >>>> ../../binutils-gdb/gdb/i386-linux-nat.c:207:46: error: cast from elf_greg_t (*)[27] {aka long long unsigned int (*)[27]} to int loses precision [-fpermissive] >>>> if (ptrace (PTRACE_GETREGS, tid, 0, (int) ®s) < 0) >>> >>> >>> ... however this error is exactly what you get if you compile with a >>> 64-bit compiler, and forget to pass -m32 to gcc/g++. IOW, >>> it compiles i386-linux-nat.c as if for a 64-bit host, which fails. >>> >>> So I suspect the builder is using CC="gcc -m32", and now that a C++ compiler >>> is involved, it needs to be updated to pass CXX="g++ -m32" as well. >> >> Yeah, actually I was setting CFLAGS without setting CXXFLAGS for these >> builders, so I fixed that now. Thanks for letting me know, and sorry >> about that. > > I was looking at > http://gdb-build.sergiodj.net/builders/Fedora-x86_64-m32/builds/3499/steps/configure%20gdb/logs/stdio > > And it seems it builds in 64 bit, there's no --host=i386... or -m32 ? Hey Antoine, Thanks for the message. So, as I said on IRC, the purpose of this builder is to perform a 64-bit compilation of GDB (i.e., without -m32), but run the testsuite on 32-bit mode (i.e., passing --target_board=unix/-m32 to runtest). Maybe the builder's name is confusing, and I apologize for that. I could try to add a better description of it on the page. Cheers, -- Sergio GPG key ID: 237A 54B1 0287 28BF 00EF 31F4 D0EB 7628 65FC 5E36 Please send encrypted e-mail if possible http://sergiodj.net/