From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Andy Moreton Newsgroups: gmane.comp.lib.gnulib.bugs,gmane.emacs.devel Subject: Re: Emacs build fails on Windows mingw64 Date: Mon, 25 Oct 2021 22:26:25 +0100 Message-ID: <86ilxkg5j2.fsf@gmail.com> References: <86v91nfp6e.fsf@gmail.com> <349dbe47-58a7-cc27-5dd5-408168820aeb@cs.ucla.edu> <86h7d61f1f.fsf@gmail.com> <4097293.omi8TgXK3m@omega> Mime-Version: 1.0 Content-Type: text/plain; charset=shift_jis Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="16186"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (windows-nt) Cc: emacs-devel@gnu.org To: bug-gnulib@gnu.org Cancel-Lock: sha1:DdmUzvIDgi35Qlxqf5h3+qTlc6c= Original-X-From: bug-gnulib-bounces+gnu-bug-gnulib=m.gmane-mx.org@gnu.org Mon Oct 25 23:26:50 2021 Return-path: Envelope-to: gnu-bug-gnulib@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 1mf7UX-0003yF-IG for gnu-bug-gnulib@m.gmane-mx.org; Mon, 25 Oct 2021 23:26:49 +0200 Original-Received: from localhost ([::1]:48836 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mf7UV-0006YG-Rf for gnu-bug-gnulib@m.gmane-mx.org; Mon, 25 Oct 2021 17:26:47 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:45722) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mf7UT-0006Y6-EG for bug-gnulib@gnu.org; Mon, 25 Oct 2021 17:26:45 -0400 Original-Received: from ciao.gmane.io ([116.202.254.214]:38978) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mf7UQ-0005Od-8b for bug-gnulib@gnu.org; Mon, 25 Oct 2021 17:26:45 -0400 Original-Received: from list by ciao.gmane.io with local (Exim 4.92) (envelope-from ) id 1mf7UN-0003iw-5m for bug-gnulib@gnu.org; Mon, 25 Oct 2021 23:26:39 +0200 X-Injected-Via-Gmane: http://gmane.org/ Received-SPF: pass client-ip=116.202.254.214; envelope-from=gnu-bug-gnulib@m.gmane-mx.org; helo=ciao.gmane.io X-Spam_score_int: 5 X-Spam_score: 0.5 X-Spam_bar: / X-Spam_report: (0.5 / 5.0 requ) BAYES_00=-1.9, DKIM_ADSP_CUSTOM_MED=0.001, FORGED_GMAIL_RCVD=1, FREEMAIL_FORGED_FROMDOMAIN=0.249, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.249, NML_ADSP_CUSTOM_MED=0.9, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: bug-gnulib@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Gnulib discussion list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnulib-bounces+gnu-bug-gnulib=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnulib" Xref: news.gmane.io gmane.comp.lib.gnulib.bugs:45189 gmane.emacs.devel:277799 Archived-At: On Mon 25 Oct 2021, Bruno Haible wrote: > Andy Moreton wrote: >> > Andy suggested a simple fix that I quoted here: >> > >> > https://lists.gnu.org/r/emacs-devel/2021-10/msg01698.html >> > >> > We could apply that patch just to ntlib.c and just in emacs-28 (do not merge >> > to master) as Andy says that works for him; >> >> Yes, that minimal fix bootstraps on emacs-28 and master with 64bit mingw64. > > Thanks for the confirmation that the lack of definitions of > _GL_ATTRIBUTE_MALLOC and _GL_ATTRIBUTE_DEALLOC_FREE was indeed the problem. Glad it was of some help: I was looking for a minimal workaround that would allow the emacs release branch to build. > Although Paul is right in saying that every file that uses Gnulib needs to > , we make compromises regarding this requirement for the *.in.h > files. The commit > https://git.savannah.gnu.org/gitweb/?p=gnulib.git;a=commitdiff;h=354f27fea9bd4ecb53980de6bd374434a204afc5 > from 2021-08-22 "Make generated .in.h files as standalone as possible" > added definitions of _GL_ATTRIBUTE_DEALLOC, _GL_ATTRIBUTE_DEALLOC_FREE, > _GL_ATTRIBUTE_MALLOC to stdlib.h, and assumed that these definitions would > also be visible in string.h, since string.h did a '#include '. > > The commit > https://git.savannah.gnu.org/gitweb/?p=gnulib.git;a=commitdiff;h=a4a2d039a9117266ed8cb1977241e7c34b368993 > from 2021-09-07 then removed this '#include ' from string.in.h. > As a compensation, it added the declaration of free/rpl_free. But it needs > also the macros _GL_ATTRIBUTE_DEALLOC, _GL_ATTRIBUTE_DEALLOC_FREE, > _GL_ATTRIBUTE_MALLOC \ when is not pre-included. > > The issue was also reported to me in private mail by Jan Engelhardt, > regarding the 'cdecl' package, on 2021-09-28, but I didn't have time > to react then; sorry about that. > > This patch should fix it. Emacs now has patches to avoid this issue, but a gnulib fix to solve the problem is also useful. Thanks, AndyM