From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:470:142:3::10]:39886) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1i2jcH-0002EA-Mo for guix-patches@gnu.org; Tue, 27 Aug 2019 18:07:06 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1i2jcG-0005Eq-Kc for guix-patches@gnu.org; Tue, 27 Aug 2019 18:07:05 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:40704) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1i2jcG-0005El-Hk for guix-patches@gnu.org; Tue, 27 Aug 2019 18:07:04 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1i2jcF-0002LE-Aw for guix-patches@gnu.org; Tue, 27 Aug 2019 18:07:03 -0400 Subject: [bug#37027] [PATCH] gnu: zlib: Add support for MinGW targets. Resent-Message-ID: From: Ludovic =?UTF-8?Q?Court=C3=A8s?= References: <20190814125853.18488-1-dthompson2@worcester.edu> Date: Wed, 28 Aug 2019 00:06:26 +0200 In-Reply-To: <20190814125853.18488-1-dthompson2@worcester.edu> (David Thompson's message of "Wed, 14 Aug 2019 08:58:53 -0400") Message-ID: <87a7bumffh.fsf@gnu.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+kyle=kyleam.com@gnu.org Sender: "Guix-patches" To: David Thompson Cc: 37027@debbugs.gnu.org Hi David, David Thompson skribis: > --- > gnu/packages/compression.scm | 55 +++++++++++++++++++++++------------- > 1 file changed, 36 insertions(+), 19 deletions(-) Please add a commit log. :-) > + `((delete 'configure) > + (add-before 'install 'set-install-paths > + (lambda* (#:key outputs #:allow-other-keys) > + (let ((out (assoc-ref outputs "out"))) > + (setenv "INCLUDE_PATH" (string-append o= ut "/include")) > + (setenv "LIBRARY_PATH" (string-append o= ut "/lib")) > + (setenv "BINARY_PATH" (string-append ou= t "/bin")) > + #t)))) > + `((replace 'configure > + (lambda* (#:key outputs #:allow-other-keys) Minor issue: could you adjust indentation to look like: (add-before 'x 'y (lambda* =E2=80=A6 ? guix.el should take care of that. > - (with-directory-excursion (string-append out "/lib") > - (install-file "libz.a" (string-append static "/lib")) > - (delete-file "libz.a") > - #t))))))) > + (lambda* (#:key outputs #:allow-other-keys) > + (let ((out (assoc-ref outputs "out")) > + (static (assoc-ref outputs "static"))) > + (with-directory-excursion (string-append out "/l= ib") > + (install-file "libz.a"= (string-append static "/lib")) The =E2=80=98with-directory-excursion=E2=80=99 indentation went off here. > + ,@(if (target-mingw?) > + `(#:make-flags > + '("-fwin32/Makefile.gcc" > + "SHARED_MODE=3D1" > + ,(string-append "CC=3D" (%current-target-system) "-gcc") > + ,(string-append "RC=3D" (%current-target-system) "-wind= res") > + ,(string-append "AR=3D" (%current-target-system) "-ar")= )) > + '()))) I wonder if we could have a single =E2=80=98if=E2=80=99: (arguments (if (target-mingw?) =E2=80=A6 )) ? Thoughts? Otherwise LGTM, thanks! Ludo=E2=80=99.