From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 77260 invoked by alias); 19 Apr 2016 15:23:33 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 77247 invoked by uid 89); 19 Apr 2016 15:23:32 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.3 required=5.0 tests=AWL,BAYES_00,RP_MATCHES_RCVD,SPF_PASS autolearn=ham version=3.3.2 spammy=HX-Received-From:4830, HX-Received-From:134, HX-Received-From:2001, HX-HELO:eggs.gnu.org X-HELO: eggs.gnu.org Received: from eggs.gnu.org (HELO eggs.gnu.org) (208.118.235.92) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-SHA encrypted) ESMTPS; Tue, 19 Apr 2016 15:23:22 +0000 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1asXUg-0006CX-Jm for gdb-patches@sourceware.org; Tue, 19 Apr 2016 11:23:20 -0400 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:48482) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1asXUg-0006CT-G8; Tue, 19 Apr 2016 11:23:14 -0400 Received: from 84.94.185.246.cable.012.net.il ([84.94.185.246]:2502 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_128_CBC_SHA1:128) (Exim 4.82) (envelope-from ) id 1asXUf-0003gz-Ll; Tue, 19 Apr 2016 11:23:14 -0400 Date: Tue, 19 Apr 2016 15:23:00 -0000 Message-Id: <838u098vxk.fsf@gnu.org> From: Eli Zaretskii To: Pedro Alves CC: simon.marchi@ericsson.com, gdb-patches@sourceware.org In-reply-to: <571648CD.7070705@redhat.com> (message from Pedro Alves on Tue, 19 Apr 2016 16:03:41 +0100) Subject: Re: [PATCH 0/1] Build GDB as a C++ program by default Reply-to: Eli Zaretskii References: <1461000466-31668-1-git-send-email-palves@redhat.com> <571633C8.4060803@ericsson.com> <57163E3B.50101@redhat.com> <83d1pl8xje.fsf@gnu.org> <571648CD.7070705@redhat.com> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-IsSubscribed: yes X-SW-Source: 2016-04/txt/msg00453.txt.bz2 > Cc: simon.marchi@ericsson.com, gdb-patches@sourceware.org > From: Pedro Alves > Date: Tue, 19 Apr 2016 16:03:41 +0100 > > On 04/19/2016 03:48 PM, Eli Zaretskii wrote: > >> From: Pedro Alves > >> Date: Tue, 19 Apr 2016 15:18:35 +0100 > >> > >> MinGW (w64) builds and runs cleanly for me too. > > > > Did you look at what libraries it depends on? Doesn't it pull in > > libgcc DLL and libstdc++ DLL? If it does, that'll put a huge damper > > on those who make precompiled binaries of GDB available for Windows > > users, because you need to accompany that with the full GCC source > > tarball, which weighs in at more than 80MB. > > GDB links with libgcc even when built as a C program. Not here, it doesn't. It is linked statically against libgcc. (I don't use MinGW64, but I don't think it matters.) Here's what 'objdump -x | fgrep "DLL Name:"' says about the latest GDB 7.11 I built: (standard input):73: DLL Name: libguile-2.0-22.dll (standard input):204: DLL Name: KERNEL32.dll (standard input):298: DLL Name: msvcrt.dll (standard input):323: DLL Name: msvcrt.dll (standard input):450: DLL Name: libncurses5.dll (standard input):501: DLL Name: USER32.dll (standard input):510: DLL Name: WS2_32.dll (standard input):531: DLL Name: zlib1.dll (standard input):542: DLL Name: python26.dll This is a build that (as you see) supports TUI, Python, and Guile, so it's as full as it gets. > How's C++ any different? With C, you can get away by using "CC='gcc -static-libgcc'" at configure time, but can you do the same with -static-libstdc++? I had bad experience with that in the past (the binary still depended on libstdc++ DLL), but maybe that was when building shared libraries, not .exe programs. Thus my question (sorry, didn't yet have time to build a recent development snapshot of GDB). Thanks.