From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Ulrich Mueller Newsgroups: gmane.emacs.devel Subject: Re: No support for ImageMagick 7 in emacs-26 Date: Mon, 26 Nov 2018 23:00:48 +0100 Message-ID: References: <83efb9jf7x.fsf@gnu.org> <83zhtvhh8l.fsf@gnu.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1543269555 2952 195.159.176.226 (26 Nov 2018 21:59:15 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Mon, 26 Nov 2018 21:59:15 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) Cc: emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Nov 26 22:59:11 2018 Return-path: Envelope-to: ged-emacs-devel@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 1gROuK-0000Wi-2a for ged-emacs-devel@m.gmane.org; Mon, 26 Nov 2018 22:59:08 +0100 Original-Received: from localhost ([::1]:39045 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gROwQ-0000MW-8o for ged-emacs-devel@m.gmane.org; Mon, 26 Nov 2018 17:01:18 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:58744) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gROwB-0000KT-Cv for emacs-devel@gnu.org; Mon, 26 Nov 2018 17:01:06 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gROw9-0003dG-6G for emacs-devel@gnu.org; Mon, 26 Nov 2018 17:01:03 -0500 Original-Received: from smtp.gentoo.org ([140.211.166.183]:59998) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gROw2-0003c6-IR; Mon, 26 Nov 2018 17:00:54 -0500 Original-Received: from a1i15 (host2092.kph.uni-mainz.de [134.93.134.92]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: ulm) by smtp.gentoo.org (Postfix) with ESMTPSA id 92DE7335DB7; Mon, 26 Nov 2018 22:00:51 +0000 (UTC) In-Reply-To: <83zhtvhh8l.fsf@gnu.org> (Eli Zaretskii's message of "Mon, 26 Nov 2018 19:38:02 +0200") X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 140.211.166.183 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 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.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:231420 Archived-At: >>>>> On Mon, 26 Nov 2018, Eli Zaretskii wrote: >> Sorry, but where do you see a change that could affect behaviour of >> v6.x? Effectively, the only code change in the consolidated patch is the >> following in image.c: >> >> - MagickRealType color_scale = 65535.0 / QuantumRange; >> + double quantum_range = QuantumRange; >> + MagickRealType color_scale = 65535.0 / quantum_range; > This is one part that I'd rather not do on the release branch We could put a conditional around it (but it looks silly): #ifdef HAVE_IMAGEMAGICK7 double quantum_range = QuantumRange; MagickRealType color_scale = 65535.0 / quantum_range; #else MagickRealType color_scale = 65535.0 / QuantumRange; #fi > (why is it needed, anyway?). According to the commit message (commit 42ed35c68b): * src/image.c (imagemagick_load_image): Use double division, and eliminate a cast. This avoids a -Wdouble-promotion warning with GCC 7.3 on Ubuntu 18.04. > The other one is that inclusion of a header file was moved to a > different place for some reason. (Yes, I'm being paranoid ;-) For v6 it still includes and at the same place and in the same order. So unless I am missing something, nothing was moved at all. IMHO it would be shortsighted to support only a version that ImageMagick upstream considers legacy. (And yes, it can be fixed at the distro level, but that just means duplicate work.)