From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Alan Third Newsgroups: gmane.emacs.bugs Subject: bug#28571: 25.3; Compile error on macOS Sierra Date: Sun, 24 Sep 2017 12:06:58 +0100 Message-ID: <20170924110658.GA30865@breton.holly.idiocy.org> References: <20170923193130.GB6576@breton.holly.idiocy.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="Nq2Wo0NMKNjxTN9z" Content-Transfer-Encoding: 8bit X-Trace: blaine.gmane.org 1506251293 25846 195.159.176.226 (24 Sep 2017 11:08:13 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sun, 24 Sep 2017 11:08:13 +0000 (UTC) User-Agent: Mutt/1.9.0 (2017-09-02) Cc: 28571@debbugs.gnu.org To: Philipp Stephani Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Sep 24 13:08:09 2017 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dw4lc-0006OC-60 for geb-bug-gnu-emacs@m.gmane.org; Sun, 24 Sep 2017 13:08:08 +0200 Original-Received: from localhost ([::1]:37596 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dw4lj-0004x6-Jd for geb-bug-gnu-emacs@m.gmane.org; Sun, 24 Sep 2017 07:08:15 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:56887) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dw4lb-0004qo-3H for bug-gnu-emacs@gnu.org; Sun, 24 Sep 2017 07:08:08 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dw4lW-0008U5-UG for bug-gnu-emacs@gnu.org; Sun, 24 Sep 2017 07:08:06 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:46548) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dw4lW-0008Tv-Nn for bug-gnu-emacs@gnu.org; Sun, 24 Sep 2017 07:08:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1dw4lW-0004Vk-Hg for bug-gnu-emacs@gnu.org; Sun, 24 Sep 2017 07:08:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Alan Third Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 24 Sep 2017 11:08:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 28571 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 28571-submit@debbugs.gnu.org id=B28571.150625122817277 (code B ref 28571); Sun, 24 Sep 2017 11:08:02 +0000 Original-Received: (at 28571) by debbugs.gnu.org; 24 Sep 2017 11:07:08 +0000 Original-Received: from localhost ([127.0.0.1]:55229 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dw4ke-0004Ub-3R for submit@debbugs.gnu.org; Sun, 24 Sep 2017 07:07:08 -0400 Original-Received: from mail-wm0-f47.google.com ([74.125.82.47]:49339) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dw4kb-0004U4-Ha for 28571@debbugs.gnu.org; Sun, 24 Sep 2017 07:07:06 -0400 Original-Received: by mail-wm0-f47.google.com with SMTP id r74so12757336wme.4 for <28571@debbugs.gnu.org>; Sun, 24 Sep 2017 04:07:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=20161025; h=sender:date:from:to:cc:subject:message-id:references:mime-version :content-disposition:content-transfer-encoding:in-reply-to :user-agent; bh=DyFrpY5ENiw0aD5q2N9CuMrfepwX2y2FO/QHO5M9c2E=; b=Veil0hreFU8AjXLbCa+QU34aLIcm4Lb73nObQcDyhXKXdHoNGm1v1FvouxxFXwrdRm UsjTYKX8rhOD+Ucn/drDhlnRCL9lsihf2mTGv9wgEjfN8P5yXXAgFkTxyNNNZ5sfJF9V A2UbjsTzvnAqwdS5shMm7RTojxep++3vuER8qAtru1JkMslvXkzRiGc6EVbiE86cfwf3 HxCPqZ07T9EwbfIJg9NeHoaP7frcPfrTkGqOrObNhqy8P+pnUBJsUr2kShP69OhEd4pr /hKuotF/3qu3UWS6/nVmApn6tK+Ftzw+KFcYyEPDpHmxOcA3yda1vLl2rX5MHW2dxjsj ptcg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:date:from:to:cc:subject:message-id :references:mime-version:content-disposition :content-transfer-encoding:in-reply-to:user-agent; bh=DyFrpY5ENiw0aD5q2N9CuMrfepwX2y2FO/QHO5M9c2E=; b=jRAPvCSBg2dXYaTgAuOg5BObJsAH0LZrV8eQu4wWCDvm3s2Vh9m+YT8d1ORfy0KrlH forCTHzeG6PgLf1Jf/2Bo7O+fVAM8+5UrcEwzzSIRtxYr0/MDMroMJubkhAFZrYUA8db A2wVqjFkTZX5NT++OEpkJIB1yIe4BFYpX8q6aIcVnOJEMalQVN2Hl0tHtpXtdbFW/SKA cU6EkT8lLZ3/n6RCnjvz0cuKQppIPjXLx5jQNLcYCbX9KYczxXV7SxfAj73+6bo3qf2F 769rU9h9fXumXJ8kU25oZN1iBrT6TnDuOxUxyZzgywEK3VtOA/UQAk9XQRus/UN3lI40 qaIw== X-Gm-Message-State: AHPjjUhQZSJQI/gy9gty2UxFlbpyYsvFhjTgfYpE0OdmP/YwJnfXVfgB xyIlTR05riJ5kNeZNJ9aG54= X-Google-Smtp-Source: AOwi7QA5tbLuTiMLq4UwHOXvbIcdlwMFElhDeGMep0Ubstbv56nlODXctzw9+B9c6MrCKp4mpp1oNQ== X-Received: by 10.28.213.79 with SMTP id m76mr7676977wmg.44.1506251219908; Sun, 24 Sep 2017 04:06:59 -0700 (PDT) Original-Received: from breton.holly.idiocy.org (ip6-2001-08b0-03f8-8129-b188-2706-1206-0eea.holly.idiocy.org. [2001:8b0:3f8:8129:b188:2706:1206:eea]) by smtp.gmail.com with ESMTPSA id p46sm7425732wrb.46.2017.09.24.04.06.58 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 24 Sep 2017 04:06:59 -0700 (PDT) Content-Disposition: inline In-Reply-To: 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:137328 Archived-At: --Nq2Wo0NMKNjxTN9z Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit On Sun, Sep 24, 2017 at 07:49:55AM +0000, Philipp Stephani wrote: > Alan Third schrieb am Sa., 23. Sep. 2017 um 21:31 Uhr: > > > > Is there maybe a test in configure that’s incorrectly identifying this > > utimens.c stuff as OK? > > > > > I do have configure output like this: > > checking for futimens... yes > checking for utimensat... yes > > So I think the functions are there, but the compilation shouldn't use them > since they would make the binary incompatible with old versions of macOS. I agree. I’ve attached a patch that should sort it. I’m not 100% sure that DARWIN_OS is the right define to check for, but it seems more appropriate than any others I can think of. -- Alan Third --Nq2Wo0NMKNjxTN9z Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="0001-Fix-build-on-macOS-bug-28571.patch" >From d77a2e45004f5d6d8496e5fed260774205efe42a Mon Sep 17 00:00:00 2001 From: Alan Third Date: Sun, 24 Sep 2017 12:01:03 +0100 Subject: [PATCH] Fix build on macOS (bug#28571) * src/conf_post.h (HAVE_FUTIMENS, HAVE_FUTIMESAT) [DARWIN_OS]: Undefine. --- src/conf_post.h | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/conf_post.h b/src/conf_post.h index febdb8b8bf..dfdb0aa3eb 100644 --- a/src/conf_post.h +++ b/src/conf_post.h @@ -397,3 +397,11 @@ extern int emacs_setenv_TZ (char const *); #else # define UNINIT /* empty */ #endif + +/* macOS 10.13 supports futimens and futimesat, older versions don't + but can appear as though they do. Disable them entirely to avoid + breaking cross-version builds on macOS. */ +#ifdef DARWIN_OS +# undef HAVE_FUTIMENS +# undef HAVE_FUTIMESAT +#endif -- 2.14.1 --Nq2Wo0NMKNjxTN9z--