From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: Current master doesn't build on Win10 (nor does emacs-28) Date: Sun, 24 Oct 2021 21:54:34 +0300 Message-ID: <83fssq2qz9.fsf@gnu.org> References: <86mtn1nkz6.fsf@gnu.org> <838ryl6nff.fsf@gnu.org> <86o87glimf.fsf@gmail.com> <86ee8bef2f.fsf_-_@gmail.com> <83k0i22t6i.fsf@gnu.org> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="11658"; mail-complaints-to="usenet@ciao.gmane.io" Cc: andrewjmoreton@gmail.com, emacs-devel@gnu.org To: "H. Dieter Wilhelm" Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sun Oct 24 20:55:36 2021 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1meiee-0002or-2l for ged-emacs-devel@m.gmane-mx.org; Sun, 24 Oct 2021 20:55:36 +0200 Original-Received: from localhost ([::1]:46150 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1meiec-0005QL-7T for ged-emacs-devel@m.gmane-mx.org; Sun, 24 Oct 2021 14:55:34 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:41172) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1meido-0004lR-7U for emacs-devel@gnu.org; Sun, 24 Oct 2021 14:54:44 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:42698) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1meidn-0003YN-8u; Sun, 24 Oct 2021 14:54:43 -0400 Original-Received: from [87.69.77.57] (port=4232 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1meidm-0006UR-R1; Sun, 24 Oct 2021 14:54:43 -0400 In-Reply-To: (dieter@duenenhof-wilhelm.de) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:277679 Archived-At: > From: "H. Dieter Wilhelm" > Cc: andrewjmoreton@gmail.com, emacs-devel@gnu.org > Date: Sun, 24 Oct 2021 20:31:55 +0200 > > Eli Zaretskii writes: > > >> From: "H. Dieter Wilhelm" > >> Date: Sun, 24 Oct 2021 19:56:26 +0200 > >> Cc: emacs-devel@gnu.org > >> > >> >> # if __GNUC__ >= 11 && !defined strdup > >> >> /* For -Wmismatched-dealloc: Associate strdup with free or rpl_free. */ > >> >> _GL_FUNCDECL_SYS (strdup, char *, > >> >> (char const *__s) > >> >> _GL_ARG_NONNULL ((1)) > >> >> _GL_ATTRIBUTE_MALLOC _GL_ATTRIBUTE_DEALLOC_FREE); > >> >> # endif > >> >> > >> >> > >> >> Hopefully Paul Eggert will be along soon to come up with a proper fix in > >> >> gnulib. > >> > > >> > Note that this problem also occurs on emacs-28, and the workaround above > >> > also works. Thus this needs a gnulib fix before the release. > >> > >> I can't reproduce this for the emacs-28 branch with a pull from > >> yesterday evening! It seems that > >> > >> make bootstrap > >> > >> make install > >> > >> is running through without any errors. The MSYS2 and MinGW collections > >> are quite recent, but it seems gcc 11 is not installed. gcc --version > >> => 10.3.0 > > > > It only happens with GCC 11, that's why you don't see it. > > I see, thanks. Is it possible to install both versions of gcc and the > necessary libraries? It's possible, but not necessarily easy. You rename the original gcc.exe to gcc10.exe, and all the rest should "just work" as long as the MinGW installation doesn't remove the old version. (I have no idea how to tell pacman not to do that, but maybe someone else here would know.) You then invoke GCC 10 as "gcc10" instead of "gcc" (so you should reconfigure Emacs to use that when compiling). But I think all of this should now be unnecessary, since fixes have been installed on both branches.