From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#22959: Emacs on Windows depends on libwinpthreads Date: Sun, 17 Apr 2016 17:37:38 +0300 Message-ID: <837ffwb8st.fsf@gnu.org> References: <87egbj4sbh.fsf@russet.org.uk> Reply-To: Eli Zaretskii NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1460903962 20712 80.91.229.3 (17 Apr 2016 14:39:22 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 17 Apr 2016 14:39:22 +0000 (UTC) Cc: 22959@debbugs.gnu.org To: Fabrice Popineau Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Apr 17 16:39:11 2016 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1arnqv-0004tL-Rs for geb-bug-gnu-emacs@m.gmane.org; Sun, 17 Apr 2016 16:39:09 +0200 Original-Received: from localhost ([::1]:47097 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1arnqv-0005IA-6V for geb-bug-gnu-emacs@m.gmane.org; Sun, 17 Apr 2016 10:39:09 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:47367) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1arnqs-0005Ff-0J for bug-gnu-emacs@gnu.org; Sun, 17 Apr 2016 10:39:06 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1arnqo-0002KD-Q8 for bug-gnu-emacs@gnu.org; Sun, 17 Apr 2016 10:39:05 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:54452) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1arnqo-0002K9-MR for bug-gnu-emacs@gnu.org; Sun, 17 Apr 2016 10:39:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1arnqo-0007id-Hi for bug-gnu-emacs@gnu.org; Sun, 17 Apr 2016 10:39:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 17 Apr 2016 14:39:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 22959 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 22959-submit@debbugs.gnu.org id=B22959.146090388529603 (code B ref 22959); Sun, 17 Apr 2016 14:39:02 +0000 Original-Received: (at 22959) by debbugs.gnu.org; 17 Apr 2016 14:38:05 +0000 Original-Received: from localhost ([127.0.0.1]:38556 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1arnpt-0007hP-JA for submit@debbugs.gnu.org; Sun, 17 Apr 2016 10:38:05 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:56272) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1arnpr-0007go-8R for 22959@debbugs.gnu.org; Sun, 17 Apr 2016 10:38:03 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1arnpi-0001wq-Pj for 22959@debbugs.gnu.org; Sun, 17 Apr 2016 10:37:57 -0400 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:49882) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1arnpi-0001wm-Ls; Sun, 17 Apr 2016 10:37:54 -0400 Original-Received: from 84.94.185.246.cable.012.net.il ([84.94.185.246]:4597 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_128_CBC_SHA1:128) (Exim 4.82) (envelope-from ) id 1arnpi-0007oK-0Z; Sun, 17 Apr 2016 10:37:54 -0400 In-reply-to: (message from Fabrice Popineau on Sat, 16 Apr 2016 23:48:35 +0200) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:116561 Archived-At: > From: Fabrice Popineau > Date: Sat, 16 Apr 2016 23:48:35 +0200 > > At this point, when I build emacs for w64 using msys2, > emacs.exe depends on libwinpthread for only one symbol > which is clock_gettime(). > This is called from lib/gettime.c:gettime(). This is not supposed to happen. I don't see this on my system. There's some factor at work here that I cannot figure out: the configure-time test for clock_gettime doesn't try to look for that function in the pthreads library, it only tries the "normal" link without any extra libraries, and if that fails, tries 2 extra libraries: librt and libposix4, none of which I'd expect to see on MS-Windows in a MinGW installation. It could be something peculiar to MinGW64/MSYS2 build. Are you sure libwinpthread dependency is not a requirement of the MinGW64 GCC port? So please look in config.log, and tell how did pthreads get into this test. > It may be possible to remove this dependency for w64 > and switch to gettimeofday(). No idea if we would lose > something in doing so. Probably nothing at all, as the 32-build AFAIK doesn't depend on libwinpthread (at least mine doesn't). > There is another dependency which is libdbus.dll, which > is automatically found. I have no idea if dbus is useful > for w64/msys2. If you don't wand D-Bus, you can configure with --without-dbus. > I may add that a full blown emacs compiled with msys2 > needs up to 57 dlls to run ( that is : all image formats dll, > gnutls, etc.) and this is what I copy in my emacs/bin directory. 57 DLLs sounds excessive. I counted the ones I think Emacs uses on my system, and only got as far as 32. Can you show a list of those 57 libraries?