From unknown Sat Jun 21 10:33:00 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#37012 <37012@debbugs.gnu.org> To: bug#37012 <37012@debbugs.gnu.org> Subject: Status: [PATCH] gnu: mingw: Add x86_64 support. Reply-To: bug#37012 <37012@debbugs.gnu.org> Date: Sat, 21 Jun 2025 17:33:00 +0000 retitle 37012 [PATCH] gnu: mingw: Add x86_64 support. reassign 37012 guix-patches submitter 37012 Carl Dong severity 37012 normal tag 37012 patch thanks From debbugs-submit-bounces@debbugs.gnu.org Mon Aug 12 16:46:58 2019 Received: (at submit) by debbugs.gnu.org; 12 Aug 2019 20:46:58 +0000 Received: from localhost ([127.0.0.1]:47450 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hxHDV-0002Ww-Te for submit@debbugs.gnu.org; Mon, 12 Aug 2019 16:46:58 -0400 Received: from lists.gnu.org ([209.51.188.17]:46144) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hxHDT-0002Wo-9V for submit@debbugs.gnu.org; Mon, 12 Aug 2019 16:46:56 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:37176) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hxHDR-0007ql-95 for guix-patches@gnu.org; Mon, 12 Aug 2019 16:46:54 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.1 required=5.0 tests=BAYES_50,RCVD_IN_DNSWL_LOW, URIBL_BLOCKED autolearn=disabled version=3.3.2 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hxHDP-0001Nv-AG for guix-patches@gnu.org; Mon, 12 Aug 2019 16:46:53 -0400 Received: from mail2.protonmail.ch ([185.70.40.22]:34954) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hxHDN-0001Lc-9x for guix-patches@gnu.org; Mon, 12 Aug 2019 16:46:51 -0400 Date: Mon, 12 Aug 2019 20:46:27 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=carldong.me; s=protonmail; t=1565642798; bh=txHAlWhU8Xm/777BY5jOOXuLKlbdS36QNjQkSksYI+s=; h=Date:To:From:Reply-To:Subject:Feedback-ID:From; b=lqSpbK5ZKvbgz6OKbR+YfRfdHSrm2p6nKurcbCTIww8ZACIvXDyQcjEOwNkadBmJ6 ZZIBrKXUzCmRoE1ksdZ6jS04y6x7sOSFX5jMUEW3wRzaxOFVfzOtcgMwJ+v8Ec3und 0DYCudcLwyUmgFdCIQ/T893W6pkI9YUJCe5s3HII= To: "guix-patches@gnu.org" From: Carl Dong Subject: [PATCH] gnu: mingw: Add x86_64 support. Message-ID: Feedback-ID: a8j8tDUaJ4AYuDVBywMTwsJebN4w8TVXadJLsJb8td3t3dZi9RdXFlPaQvoFKnI9KgXySsPXcRkajVyY0cGTcA==:Ext:ProtonMail MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 185.70.40.22 X-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Carl Dong Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.3 (--) This patch parameterizes previously hard-coded instances of i686-w64-mingw32, adding support for x86_64-w64-mingw32. * gnu/packages/mingw.scm (make-mingw-w64): New procedure. (mingw-w64-i686, mingw-w64-x86_64): New variables. (%mingw-triplet): Remove. (mingw-w64): Update to point to 'mingw-w64-i686'. * gnu/packages/cross-base.scm (cross-gcc): Use 'libc' keyword argument if specified, instead of treating it as a boolean. (native-libc): Return the correct mingw-w64 depending on machine specified in target. * gnu/packages/bootstrap.scm (glibc-dynamic-linker): Add "x86_64-mingw". * gnu/build/cross-toolchain.scm (set-cross-path/mingw): Replace hardcoded 'i686-w64-mingw32' instances with 'target' keyword argument. (cross-gcc-build-phases): Update accordingly; use 'target-mingw?' helper. * gnu/ci.scm (%cross-targets): Add "x86_64-w64-mingw32". --- gnu/build/cross-toolchain.scm | 11 ++-- gnu/ci.scm | 3 +- gnu/packages/bootstrap.scm | 1 + gnu/packages/cross-base.scm | 5 +- gnu/packages/mingw.scm | 120 ++++++++++++++++++---------------- 5 files changed, 76 insertions(+), 64 deletions(-) diff --git a/gnu/build/cross-toolchain.scm b/gnu/build/cross-toolchain.scm index d430b8afc4..77e279f07d 100644 --- a/gnu/build/cross-toolchain.scm +++ b/gnu/build/cross-toolchain.scm @@ -22,6 +22,7 @@ (define-module (gnu build cross-toolchain) #:use-module (guix build utils) #:use-module (guix build gnu-build-system) + #:use-module (guix utils) #:use-module (srfi srfi-1) #:use-module (srfi srfi-26) #:use-module (ice-9 match) @@ -95,7 +96,7 @@ C_INCLUDE_PATH et al." ;; We're building the sans-libc cross-compiler, so nothing to do. #t))) -(define* (set-cross-path/mingw #:key inputs #:allow-other-keys) +(define* (set-cross-path/mingw #:key inputs target #:allow-other-keys) "Add the cross MinGW headers to CROSS_C_*_INCLUDE_PATH, and remove them = from C_*INCLUDE_PATH." (let ((libc (assoc-ref inputs "libc")) @@ -112,7 +113,7 @@ C_*INCLUDE_PATH." (if libc (let ((cpath (string-append libc "/include" - ":" libc "/i686-w64-mingw32/include"))= ) + ":" libc "/" target "/include"))) (for-each (cut setenv <> cpath) %gcc-cross-include-paths)) @@ -142,7 +143,7 @@ C_*INCLUDE_PATH." (when libc (setenv "CROSS_LIBRARY_PATH" (string-append libc "/lib" - ":" libc "/i686-w64-mingw32/lib"))) + ":" libc "/" target "/lib"))) (setenv "CPP" (string-append gcc "/bin/cpp")) (for-each (lambda (var) @@ -168,8 +169,8 @@ C_*INCLUDE_PATH." a target triplet." (modify-phases phases (add-before 'configure 'set-cross-path - (if (string-contains target "mingw") - set-cross-path/mingw + (if (target-mingw? target) + (cut set-cross-path/mingw #:target target <...>) set-cross-path)) (add-after 'install 'make-cross-binutils-visible (cut make-cross-binutils-visible #:target target <...>)) diff --git a/gnu/ci.scm b/gnu/ci.scm index 4885870e16..aeebd4f14b 100644 --- a/gnu/ci.scm +++ b/gnu/ci.scm @@ -130,7 +130,8 @@ SYSTEM." "aarch64-linux-gnu" "powerpc-linux-gnu" "i586-pc-gnu" ;aka. GNU/Hurd - "i686-w64-mingw32")) + "i686-w64-mingw32" + "x86_64-w64-mingw32")) (define %guixsd-supported-systems '("x86_64-linux" "i686-linux" "armhf-linux")) diff --git a/gnu/packages/bootstrap.scm b/gnu/packages/bootstrap.scm index 5030b815b9..13a7ef5cc5 100644 --- a/gnu/packages/bootstrap.scm +++ b/gnu/packages/bootstrap.scm @@ -187,6 +187,7 @@ return value is ignored." ((string=3D? system "avr") "no-ld.so") ((string=3D? system "propeller-elf") "no-ld.so") ((string=3D? system "i686-mingw") "no-ld.so") + ((string=3D? system "x86_64-mingw") "no-ld.so") ((string=3D? system "vc4-elf") "no-ld.so") (else (error "dynamic linker name not known for this system" diff --git a/gnu/packages/cross-base.scm b/gnu/packages/cross-base.scm index a0341ebc5d..35cb2ab25f 100644 --- a/gnu/packages/cross-base.scm +++ b/gnu/packages/cross-base.scm @@ -249,7 +249,7 @@ target that libc." (cond ((target-mingw? target) (if libc - `(("libc" ,mingw-w64) + `(("libc" ,libc) ,@inputs) `(("mingw-source" ,(package-source mingw-w64)) ,@inputs))) @@ -509,7 +509,8 @@ and the cross tool chain." #:optional (libc glibc)) (if (target-mingw? target) - mingw-w64 + (let ((machine (substring target 0 (string-index target #\-)))) + (make-mingw-w64 machine)) libc)) (define* (cross-newlib? target diff --git a/gnu/packages/mingw.scm b/gnu/packages/mingw.scm index 3e96f2c475..907f2c3c35 100644 --- a/gnu/packages/mingw.scm +++ b/gnu/packages/mingw.scm @@ -31,62 +31,70 @@ #:use-module (guix utils) #:use-module (ice-9 match)) -(define %mingw-triplet - "i686-w64-mingw32") +(define-public (make-mingw-w64 machine) + (let ((triplet (string-append machine "-" "w64-mingw32"))) + (package + (name (string-append "mingw-w64" "-" machine)) + (version "5.0.4") + (source (origin + (method url-fetch) + (uri (string-append + "https://sourceforge.net/projects/mingw-w64/files/mi= ngw-w64/" + "mingw-w64-release/mingw-w64-v" version ".tar.bz2")) + (sha256 + (base32 "00zq3z1hbzd5yzmskskjg79xrzwsqx7ihyprfaxy4hb897vf= 29sm")) + (patches (search-patches "mingw-w64-5.0rc2-gcc-4.9.3.patch= ")))) + (native-inputs `(("xgcc-core" ,(cross-gcc triplet)) + ("xbinutils" ,(cross-binutils triplet)))) + (build-system gnu-build-system) + (search-paths + (list (search-path-specification + (variable "CROSS_C_INCLUDE_PATH") + (files `("include" ,(string-append triplet "/include")))) + (search-path-specification + (variable "CROSS_LIBRARY_PATH") + (files + `("lib" "lib64" + ,(string-append triplet "/lib") + ,(string-append triplet "/lib64")))))) + (arguments + `(#:configure-flags '(,(string-append "--host=3D" triplet)) + #:phases + (modify-phases %standard-phases + (add-before 'configure 'setenv + (lambda* (#:key inputs #:allow-other-keys) + (let ((xgcc-core (assoc-ref inputs "xgcc-core")) + (mingw-headers (string-append (getcwd) "/mingw-w64-he= aders"))) + (setenv "CPP" + (string-append xgcc-core ,(string-append "/bin/" = triplet "-cpp"))) + (setenv "CROSS_C_INCLUDE_PATH" + (string-append + mingw-headers + ":" mingw-headers "/include" + ":" mingw-headers "/crt" + ":" mingw-headers "/defaults/include" + ":" mingw-headers "/direct-x/include")))))) + #:make-flags (list "DEFS=3D-DHAVE_CONFIG_H -D__MINGW_HAS_DXSDK=3D= 1") + #:tests? #f ; compiles and includes glibc headers + #:strip-binaries? #f)) + (home-page "https://mingw-w64.org") + (synopsis "Minimalist GNU for Windows") + (description + "Minimalist GNU for Windows (@dfn{MinGW}) is a complete software +de velopment environment for creating native Microsoft Windows applicatio= ns. -(define-public mingw-w64 - (package - (name "mingw-w64") - (version "5.0.4") - (source (origin - (method url-fetch) - (uri (string-append - "https://sourceforge.net/projects/mingw-w64/files/ming= w-w64/" - "mingw-w64-release/mingw-w64-v" version ".tar.bz2")) - (sha256 - (base32 "00zq3z1hbzd5yzmskskjg79xrzwsqx7ihyprfaxy4hb897vf29= sm")) - (patches (search-patches "mingw-w64-5.0rc2-gcc-4.9.3.patch")= ))) - (native-inputs `(("xgcc-core" ,(cross-gcc %mingw-triplet)) - ("xbinutils" ,(cross-binutils %mingw-triplet)))) - (build-system gnu-build-system) - (search-paths - (list (search-path-specification - (variable "CROSS_C_INCLUDE_PATH") - (files '("include" "i686-w64-mingw32/include"))) - (search-path-specification - (variable "CROSS_LIBRARY_PATH") - (files - '("lib" "lib64" "i686-w64-mingw32/lib" "i686-w64-mingw32/lib6= 4"))))) - (arguments - `(#:configure-flags '("--host=3Di686-w64-mingw32") - #:phases - (modify-phases %standard-phases - (add-before 'configure 'setenv - (lambda* (#:key inputs #:allow-other-keys) - (let ((xgcc-core (assoc-ref inputs "xgcc-core")) - (mingw-headers (string-append (getcwd) "/mingw-w64-head= ers"))) - (setenv "CPP" - (string-append xgcc-core "/bin/i686-w64-mingw32-cpp= ")) - (setenv "CROSS_C_INCLUDE_PATH" - (string-append - mingw-headers - ":" mingw-headers "/include" - ":" mingw-headers "/crt" - ":" mingw-headers "/defaults/include" - ":" mingw-headers "/direct-x/include")))))) - #:make-flags (list "DEFS=3D-DHAVE_CONFIG_H -D__MINGW_HAS_DXSDK=3D1"= ) - #:tests? #f ; compiles and includes glibc headers - #:strip-binaries? #f)) - (home-page "https://mingw-w64.org") - (synopsis "Minimalist GNU for Windows") - (description - "Minimalist GNU for Windows (@dfn{MinGW}) is a complete software -development environment for creating native Microsoft Windows applications= . +It includes a set of Windows-specific header files and static import lib= raries +wh ich enable the use of the Windows API. It does not rely on any third-= party C +ru ntime dynamic-link libraries (@dfn{DLL}s). -It includes a set of Windows-specific header files and static import libra= ries -which enable the use of the Windows API. It does not rely on any third-pa= rty C -runtime dynamic-link libraries (@dfn{DLL}s). +Mi ngw-w64 is an advancement of the original mingw.org project and provid= es +se veral new APIs such as DirectX and DDK, and 64-bit support.") + (license license:fdl1.3+)))) -Mingw-w64 is an advancement of the original mingw.org project and provides -several new APIs such as DirectX and DDK, and 64-bit support.") - (license license:fdl1.3+))) +(define-public mingw-w64-i686 + (make-mingw-w64 "i686")) + +(define-public mingw-w64-x86_64 + (make-mingw-w64 "x86_64")) + +(define-public mingw-w64 mingw-w64-i686) -- 2.22.0 From debbugs-submit-bounces@debbugs.gnu.org Tue Aug 13 18:27:27 2019 Received: (at 37012) by debbugs.gnu.org; 13 Aug 2019 22:27:28 +0000 Received: from localhost ([127.0.0.1]:48755 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hxfGJ-0004SW-Gi for submit@debbugs.gnu.org; Tue, 13 Aug 2019 18:27:27 -0400 Received: from eggs.gnu.org ([209.51.188.92]:41060) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hxfGH-0004SK-C2 for 37012@debbugs.gnu.org; Tue, 13 Aug 2019 18:27:26 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:46256) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hxfGB-000503-T4; Tue, 13 Aug 2019 18:27:19 -0400 Received: from [2001:980:1b4f:1:42d2:832d:bb59:862] (port=51782 helo=dundal.peder.onsbrabantnet.nl) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1hxfGA-0002cO-Qz; Tue, 13 Aug 2019 18:27:19 -0400 From: Jan Nieuwenhuizen To: Carl Dong Subject: Re: [bug#37012] [PATCH] gnu: mingw: Add x86_64 support. Organization: AvatarAcademy.nl References: X-Url: http://AvatarAcademy.nl Date: Wed, 14 Aug 2019 00:27:13 +0200 In-Reply-To: (Carl Dong's message of "Mon, 12 Aug 2019 20:46:27 +0000") Message-ID: <87o90sitvi.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 37012 Cc: 37012@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Carl Dong writes: Hi Carl! > This patch parameterizes previously hard-coded instances of > i686-w64-mingw32, adding support for x86_64-w64-mingw32. That would be great. When I try it, I get --8<---------------cut here---------------start------------->8--- $ ./pre-inst-env guix build --target=3Di686-w64-mingw32 hello --no-build-ho= ok building /gnu/store/b3qq8g6lhwgadp09vwwmnyd91bvll3s3-module-import-compiled= .drv... Backtrace: In ice-9/boot-9.scm: 841:4 19 (with-throw-handler _ _ _) In system/base/compile.scm: 59:11 18 (_) 155:11 17 (_ #) 235:18 16 (read-and-compile # ?) 183:32 15 (compile-fold (#) ?) In ice-9/boot-9.scm: 2312:4 14 (save-module-excursion _) In language/scheme/compile-tree-il.scm: 31:15 13 (_) In ice-9/psyntax.scm: 1235:36 12 (expand-top-sequence _ _ _ #f _ _ _) 1182:24 11 (parse _ (("placeholder" placeholder)) ((top) #(# # ?)) ?) 285:10 10 (parse _ (("placeholder" placeholder)) (()) _ c&e (# #) #) In ice-9/eval.scm: 293:34 9 (_ #) In ice-9/boot-9.scm: 2874:4 8 (define-module* _ #:filename _ #:pure _ #:version _ # _ ?) 2071:24 7 (call-with-deferred-observers _) 2887:24 6 (_) 222:29 5 (map1 _) 222:29 4 (map1 (((guix build gnu-build-system)) ((guix utils)) ?)) 222:17 3 (map1 (((guix utils)) ((srfi srfi-1)) ((srfi #)) ((?)) ?)) 2803:6 2 (resolve-interface _ #:select _ #:hide _ #:prefix _ # _ ?) In unknown file: 1 (scm-error misc-error #f "~A ~S" ("no code for modu?" ?) ?) In ice-9/boot-9.scm: 752:25 0 (dispatch-exception _ _ _) ice-9/boot-9.scm:752:25: In procedure dispatch-exception: no code for module (guix utils) --8<---------------cut here---------------end--------------->8--- Does this it work for you, can you verify? > diff --git a/gnu/build/cross-toolchain.scm b/gnu/build/cross-toolchain.scm > index d430b8afc4..77e279f07d 100644 > --- a/gnu/build/cross-toolchain.scm > +++ b/gnu/build/cross-toolchain.scm > @@ -22,6 +22,7 @@ > (define-module (gnu build cross-toolchain) > #:use-module (guix build utils) > #:use-module (guix build gnu-build-system) > + #:use-module (guix utils) I am suspecting this one here, in which case > @@ -168,8 +169,8 @@ C_*INCLUDE_PATH." > a target triplet." > (modify-phases phases > (add-before 'configure 'set-cross-path > - (if (string-contains target "mingw") > - set-cross-path/mingw > + (if (target-mingw? target) > + (cut set-cross-path/mingw #:target target <...>) > set-cross-path)) > (add-after 'install 'make-cross-binutils-visible > (cut make-cross-binutils-visible #:target target <...>)) this would need to change. > diff --git a/gnu/packages/mingw.scm b/gnu/packages/mingw.scm > index 3e96f2c475..907f2c3c35 100644 > --- a/gnu/packages/mingw.scm > +++ b/gnu/packages/mingw.scm ... > + (description > + "Minimalist GNU for Windows (@dfn{MinGW}) is a complete software > +de velopment environment for creating native Microsoft Windows applicat= ions. ^^ What happened here? > +It includes a set of Windows-specific header files and static import l= ibraries > +wh ich enable the use of the Windows API. It does not rely on any thir= d-party C > +ru ntime dynamic-link libraries (@dfn{DLL}s). ^^ Otherwise, LGTM. Greetings, janneke --=20 Jan Nieuwenhuizen | GNU LilyPond http://lilypond.org Freelance IT http://JoyofSource.com | Avatar=C2=AE http://AvatarAcademy.com From debbugs-submit-bounces@debbugs.gnu.org Wed Aug 14 02:57:46 2019 Received: (at 37012) by debbugs.gnu.org; 14 Aug 2019 06:57:46 +0000 Received: from localhost ([127.0.0.1]:48886 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hxnEA-00023E-5S for submit@debbugs.gnu.org; Wed, 14 Aug 2019 02:57:46 -0400 Received: from eggs.gnu.org ([209.51.188.92]:45178) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hxnE7-00022z-TV for 37012@debbugs.gnu.org; Wed, 14 Aug 2019 02:57:45 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:51645) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hxnE1-0004uK-Oq; Wed, 14 Aug 2019 02:57:37 -0400 Received: from [2001:980:1b4f:1:42d2:832d:bb59:862] (port=50372 helo=dundal.peder.onsbrabantnet.nl) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1hxnE0-0000sj-Ip; Wed, 14 Aug 2019 02:57:37 -0400 From: Jan Nieuwenhuizen To: Carl Dong Subject: Re: [bug#37012] [PATCH] gnu: mingw: Add x86_64 support. Organization: AvatarAcademy.nl References: <87o90sitvi.fsf@gnu.org> X-Url: http://AvatarAcademy.nl Date: Wed, 14 Aug 2019 08:57:33 +0200 In-Reply-To: <87o90sitvi.fsf@gnu.org> (Jan Nieuwenhuizen's message of "Wed, 14 Aug 2019 00:27:13 +0200") Message-ID: <874l2kmdya.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 37012 Cc: 37012@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Jan Nieuwenhuizen writes: Hello again, >> This patch parameterizes previously hard-coded instances of >> i686-w64-mingw32, adding support for x86_64-w64-mingw32. > > That would be great. Just before you create a new patch, please also add some copyright headers. Thanks! janneke --=20 Jan Nieuwenhuizen | GNU LilyPond http://lilypond.org Freelance IT http://JoyofSource.com | Avatar=C2=AE http://AvatarAcademy.com From debbugs-submit-bounces@debbugs.gnu.org Wed Aug 14 08:09:48 2019 Received: (at 37012) by debbugs.gnu.org; 14 Aug 2019 12:09:48 +0000 Received: from localhost ([127.0.0.1]:48995 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hxs68-000337-BQ for submit@debbugs.gnu.org; Wed, 14 Aug 2019 08:09:48 -0400 Received: from mail-vs1-f67.google.com ([209.85.217.67]:44931) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hxs66-00032u-H7 for 37012@debbugs.gnu.org; Wed, 14 Aug 2019 08:09:47 -0400 Received: by mail-vs1-f67.google.com with SMTP id c7so6669089vse.11 for <37012@debbugs.gnu.org>; Wed, 14 Aug 2019 05:09:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=worcester-edu.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=q/tsfcY0bG/9GP+y/CyyUCF1+07DFf1HkaRlvHVhOHY=; b=NEB9mLp84HOCZLGYgmW03JI8tExl/bgFPJOp6jLI2VE/1LdYOT10jlU1MQYBuJxMXS 5egZFxfGHi5vM3EspqwQH3w9PyY+SjQt6MlHDhnxaFH9mW2DjKwWkaI11ByqBZc//UP8 Go+OA/HyweufnBCkrTJVhmiFnxlLpjWNuhyGVGrviXfkD3BdqmJWoQjJ51jAMQ3+qWbx 4leh9sez11CjfVG8V9Mss8KlDR0JYeimhJQ1VOC4z+9A+1qb/8RJm0CPSdY2HoqIq969 EFvPNEksrgMkd9Y4qAHDaCsikOcZwfIV4TulspfU7nmgZwN+e56RK5l0FlAr+qj5/la5 Yj0A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=q/tsfcY0bG/9GP+y/CyyUCF1+07DFf1HkaRlvHVhOHY=; b=GchacLZ6XrLu5KuhTFvTsLN657u6ON9B4YzfgmbVJ9SCc4S40g6A+ryGX63EsKJHFF 9FEQ/AWns/IW0WGPlB2vTTwy9tvgf2QCMpXcunJsGPnF2poj996jxCLctbQ7uxZHX4Gi ObotQEGMjxxCs7DlyAHtrOF+hwISZu2oAgVWKOIX6VztgScNEdZeDEIp1T8ST4OpOXXT /XSPUjQ494vMRCdwE7CqNkecVrstAtdV4mQqGNa8zfqguKpEGOiC86l2H1GK0J+GcZ0W P0lriIR2orVlTKiayJFq5H4cC+FU3ay0oEDJ8DVkSFW2+WwrpPfqfYuGCK69mPhnLOQK 8EOw== X-Gm-Message-State: APjAAAVr30GP3cI3O/QNMjK02cIGlQI3bKl0qmWnvD/lRbAxSPrHT1zS c+D22Czl2UZv4S+2YglyYUO1wd1DQCtbjnm+qt/cZ/q9WPc= X-Google-Smtp-Source: APXvYqxVfF+pN9S/TuYcxG8lblaDS/BVI9h/lJtcbQJbsSGQ1SUABmx8s33Gkm647P9AOkmIA6Sc0NNn3f65bIYOsKY= X-Received: by 2002:a67:ed87:: with SMTP id d7mr30837505vsp.130.1565784580890; Wed, 14 Aug 2019 05:09:40 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: "Thompson, David" Date: Wed, 14 Aug 2019 08:09:29 -0400 Message-ID: Subject: Re: [bug#37012] [PATCH] gnu: mingw: Add x86_64 support. To: Carl Dong Content-Type: text/plain; charset="UTF-8" X-Spam-Score: -0.2 (/) X-Debbugs-Envelope-To: 37012 Cc: 37012@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.2 (-) Hi Carl, On Mon, Aug 12, 2019 at 4:47 PM Carl Dong wrote: > > This patch parameterizes previously hard-coded instances of > i686-w64-mingw32, adding support for x86_64-w64-mingw32. Thanks for doing this! I've been experimenting with building Guile projects for Windows and this was on my wishlist. Which reminds me, I have a patch series that updates to the latest version of MinGW that I should share. - Dave From debbugs-submit-bounces@debbugs.gnu.org Wed Aug 14 13:55:19 2019 Received: (at 37012) by debbugs.gnu.org; 14 Aug 2019 17:55:19 +0000 Received: from localhost ([127.0.0.1]:49639 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hxxUO-0003DL-Kx for submit@debbugs.gnu.org; Wed, 14 Aug 2019 13:55:19 -0400 Received: from mail1.protonmail.ch ([185.70.40.18]:41933) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hxxUK-0003D0-PM for 37012@debbugs.gnu.org; Wed, 14 Aug 2019 13:55:11 -0400 Date: Wed, 14 Aug 2019 17:54:59 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=carldong.me; s=protonmail; t=1565805300; bh=wOJsX4VuZMCNyhBuAYudZoL5Qe4/moL+qf13QoaC9f4=; h=Date:To:From:Cc:Reply-To:Subject:In-Reply-To:References: Feedback-ID:From; b=ao2wwfY2vjlqLL8MVCitQ/+6lPV4ECiW2WMEIuJLev4oey81wJHBLK1v6U6SQdWWF a0pjqmAbvksRn92LKWQ3cJVsQT4TiWqK07XNdzp8qHz+AoKm42D82J58GFF9mD4nJr FrXqDaXYIJD18rZj6mddneJsas4/0f8ZVYezamiw= To: Jan Nieuwenhuizen From: Carl Dong Subject: Re: [bug#37012] [PATCH] gnu: mingw: Add x86_64 support. Message-ID: In-Reply-To: <874l2kmdya.fsf@gnu.org> References: <87o90sitvi.fsf@gnu.org> <874l2kmdya.fsf@gnu.org> Feedback-ID: a8j8tDUaJ4AYuDVBywMTwsJebN4w8TVXadJLsJb8td3t3dZi9RdXFlPaQvoFKnI9KgXySsPXcRkajVyY0cGTcA==:Ext:ProtonMail MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-1.2 required=7.0 tests=ALL_TRUSTED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on mail.protonmail.ch X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 37012 Cc: "37012@debbugs.gnu.org" <37012@debbugs.gnu.org> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Carl Dong Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Here's the updated patch that I've tested. Let me know if this works for yo= u! :-) >From e6df2d6f9b47b02abec01a16f2d0b1271dcec1d2 Mon Sep 17 00:00:00 2001 From: Carl Dong Date: Wed, 14 Aug 2019 13:46:53 -0400 Subject: [PATCH] gnu: mingw: Add x86_64 support. This patch parameterizes previously hard-coded instances of i686-w64-mingw32, adding support for x86_64-w64-mingw32. * gnu/packages/mingw.scm (make-mingw-w64): New procedure. (mingw-w64-i686, mingw-w64-x86_64): New variables. (%mingw-triplet): Remove. (mingw-w64): Update to point to 'mingw-w64-i686'. * gnu/packages/cross-base.scm (cross-gcc): Use 'libc' keyword argument if specified, instead of treating it as a boolean. (native-libc): Return the correct mingw-w64 depending on machine specified in target. * gnu/packages/bootstrap.scm (glibc-dynamic-linker): Add "x86_64-mingw". * gnu/build/cross-toolchain.scm (set-cross-path/mingw): Replace hardcoded 'i686-w64-mingw32' instances with 'target' keyword argument. (cross-gcc-build-phases): Update accordingly; use 'target-mingw?' implementation of target checking and add commentary. * gnu/ci.scm (%cross-targets): Add "x86_64-w64-mingw32". --- gnu/build/cross-toolchain.scm | 15 +++-- gnu/ci.scm | 3 +- gnu/packages/bootstrap.scm | 2 + gnu/packages/cross-base.scm | 6 +- gnu/packages/mingw.scm | 111 ++++++++++++++++++---------------- 5 files changed, 78 insertions(+), 59 deletions(-) diff --git a/gnu/build/cross-toolchain.scm b/gnu/build/cross-toolchain.scm index d430b8afc4..201b36ff7c 100644 --- a/gnu/build/cross-toolchain.scm +++ b/gnu/build/cross-toolchain.scm @@ -3,6 +3,7 @@ ;;; Copyright =C2=A9 2014, 2015, 2018 Mark H Weaver ;;; Copyright =C2=A9 2016 Jan Nieuwenhuizen ;;; Copyright =C2=A9 2016 Manolis Fragkiskos Ragkousis +;;; Copyright =C2=A9 2019 Carl Dong ;;; ;;; This file is part of GNU Guix. ;;; @@ -95,7 +96,7 @@ C_INCLUDE_PATH et al." ;; We're building the sans-libc cross-compiler, so nothing to do. #t))) -(define* (set-cross-path/mingw #:key inputs #:allow-other-keys) +(define* (set-cross-path/mingw #:key inputs target #:allow-other-keys) "Add the cross MinGW headers to CROSS_C_*_INCLUDE_PATH, and remove them = from C_*INCLUDE_PATH." (let ((libc (assoc-ref inputs "libc")) @@ -112,7 +113,7 @@ C_*INCLUDE_PATH." (if libc (let ((cpath (string-append libc "/include" - ":" libc "/i686-w64-mingw32/include"))= ) + ":" libc "/" target "/include"))) (for-each (cut setenv <> cpath) %gcc-cross-include-paths)) @@ -142,7 +143,7 @@ C_*INCLUDE_PATH." (when libc (setenv "CROSS_LIBRARY_PATH" (string-append libc "/lib" - ":" libc "/i686-w64-mingw32/lib"))) + ":" libc "/" target "/lib"))) (setenv "CPP" (string-append gcc "/bin/cpp")) (for-each (lambda (var) @@ -168,8 +169,12 @@ C_*INCLUDE_PATH." a target triplet." (modify-phases phases (add-before 'configure 'set-cross-path - (if (string-contains target "mingw") - set-cross-path/mingw + ;; This mingw32 target checking logic should match that of target-mi= ngw? + ;; in (guix utils), but (guix utils) is too large too copy over to t= he + ;; build side entirely and for now we have no way to select variable= s to + ;; copy over. See (gnu packages cross-base) for more details. + (if (string-suffix? "-mingw32" target) + (cut set-cross-path/mingw #:target target <...>) set-cross-path)) (add-after 'install 'make-cross-binutils-visible (cut make-cross-binutils-visible #:target target <...>)) diff --git a/gnu/ci.scm b/gnu/ci.scm index 4885870e16..aeebd4f14b 100644 --- a/gnu/ci.scm +++ b/gnu/ci.scm @@ -130,7 +130,8 @@ SYSTEM." "aarch64-linux-gnu" "powerpc-linux-gnu" "i586-pc-gnu" ;aka. GNU/Hurd - "i686-w64-mingw32")) + "i686-w64-mingw32" + "x86_64-w64-mingw32")) (define %guixsd-supported-systems '("x86_64-linux" "i686-linux" "armhf-linux")) diff --git a/gnu/packages/bootstrap.scm b/gnu/packages/bootstrap.scm index 5030b815b9..cd99425379 100644 --- a/gnu/packages/bootstrap.scm +++ b/gnu/packages/bootstrap.scm @@ -2,6 +2,7 @@ ;;; Copyright =C2=A9 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019 Ludovi= c Court=C3=A8s ;;; Copyright =C2=A9 2014, 2015, 2018 Mark H Weaver ;;; Copyright =C2=A9 2017 Efraim Flashner +;;; Copyright =C2=A9 2019 Carl Dong ;;; ;;; This file is part of GNU Guix. ;;; @@ -187,6 +188,7 @@ return value is ignored." ((string=3D? system "avr") "no-ld.so") ((string=3D? system "propeller-elf") "no-ld.so") ((string=3D? system "i686-mingw") "no-ld.so") + ((string=3D? system "x86_64-mingw") "no-ld.so") ((string=3D? system "vc4-elf") "no-ld.so") (else (error "dynamic linker name not known for this system" diff --git a/gnu/packages/cross-base.scm b/gnu/packages/cross-base.scm index a0341ebc5d..e277139f25 100644 --- a/gnu/packages/cross-base.scm +++ b/gnu/packages/cross-base.scm @@ -4,6 +4,7 @@ ;;; Copyright =C2=A9 2016 Jan Nieuwenhuizen ;;; Copyright =C2=A9 2016 Manolis Fragkiskos Ragkousis ;;; Copyright =C2=A9 2018 Tobias Geerinckx-Rice +;;; Copyright =C2=A9 2019 Carl Dong ;;; ;;; This file is part of GNU Guix. ;;; @@ -249,7 +250,7 @@ target that libc." (cond ((target-mingw? target) (if libc - `(("libc" ,mingw-w64) + `(("libc" ,libc) ,@inputs) `(("mingw-source" ,(package-source mingw-w64)) ,@inputs))) @@ -509,7 +510,8 @@ and the cross tool chain." #:optional (libc glibc)) (if (target-mingw? target) - mingw-w64 + (let ((machine (substring target 0 (string-index target #\-)))) + (make-mingw-w64 machine)) libc)) (define* (cross-newlib? target diff --git a/gnu/packages/mingw.scm b/gnu/packages/mingw.scm index 3e96f2c475..017f9453ab 100644 --- a/gnu/packages/mingw.scm +++ b/gnu/packages/mingw.scm @@ -1,6 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright =C2=A9 2016 Jan Nieuwenhuizen ;;; Copyright =C2=A9 2018 Tobias Geerinckx-Rice +;;; Copyright =C2=A9 2019 Carl Dong ;;; ;;; This file is part of GNU Guix. ;;; @@ -31,56 +32,56 @@ #:use-module (guix utils) #:use-module (ice-9 match)) -(define %mingw-triplet - "i686-w64-mingw32") - -(define-public mingw-w64 - (package - (name "mingw-w64") - (version "5.0.4") - (source (origin - (method url-fetch) - (uri (string-append - "https://sourceforge.net/projects/mingw-w64/files/ming= w-w64/" - "mingw-w64-release/mingw-w64-v" version ".tar.bz2")) - (sha256 - (base32 "00zq3z1hbzd5yzmskskjg79xrzwsqx7ihyprfaxy4hb897vf29= sm")) - (patches (search-patches "mingw-w64-5.0rc2-gcc-4.9.3.patch")= ))) - (native-inputs `(("xgcc-core" ,(cross-gcc %mingw-triplet)) - ("xbinutils" ,(cross-binutils %mingw-triplet)))) - (build-system gnu-build-system) - (search-paths - (list (search-path-specification - (variable "CROSS_C_INCLUDE_PATH") - (files '("include" "i686-w64-mingw32/include"))) - (search-path-specification - (variable "CROSS_LIBRARY_PATH") - (files - '("lib" "lib64" "i686-w64-mingw32/lib" "i686-w64-mingw32/lib6= 4"))))) - (arguments - `(#:configure-flags '("--host=3Di686-w64-mingw32") - #:phases - (modify-phases %standard-phases - (add-before 'configure 'setenv - (lambda* (#:key inputs #:allow-other-keys) - (let ((xgcc-core (assoc-ref inputs "xgcc-core")) - (mingw-headers (string-append (getcwd) "/mingw-w64-head= ers"))) - (setenv "CPP" - (string-append xgcc-core "/bin/i686-w64-mingw32-cpp= ")) - (setenv "CROSS_C_INCLUDE_PATH" - (string-append - mingw-headers - ":" mingw-headers "/include" - ":" mingw-headers "/crt" - ":" mingw-headers "/defaults/include" - ":" mingw-headers "/direct-x/include")))))) - #:make-flags (list "DEFS=3D-DHAVE_CONFIG_H -D__MINGW_HAS_DXSDK=3D1"= ) - #:tests? #f ; compiles and includes glibc headers - #:strip-binaries? #f)) - (home-page "https://mingw-w64.org") - (synopsis "Minimalist GNU for Windows") - (description - "Minimalist GNU for Windows (@dfn{MinGW}) is a complete software +(define-public (make-mingw-w64 machine) + (let ((triplet (string-append machine "-" "w64-mingw32"))) + (package + (name (string-append "mingw-w64" "-" machine)) + (version "5.0.4") + (source (origin + (method url-fetch) + (uri (string-append + "https://sourceforge.net/projects/mingw-w64/files/mi= ngw-w64/" + "mingw-w64-release/mingw-w64-v" version ".tar.bz2")) + (sha256 + (base32 "00zq3z1hbzd5yzmskskjg79xrzwsqx7ihyprfaxy4hb897vf= 29sm")) + (patches (search-patches "mingw-w64-5.0rc2-gcc-4.9.3.patch= ")))) + (native-inputs `(("xgcc-core" ,(cross-gcc triplet)) + ("xbinutils" ,(cross-binutils triplet)))) + (build-system gnu-build-system) + (search-paths + (list (search-path-specification + (variable "CROSS_C_INCLUDE_PATH") + (files `("include" ,(string-append triplet "/include")))) + (search-path-specification + (variable "CROSS_LIBRARY_PATH") + (files + `("lib" "lib64" + ,(string-append triplet "/lib") + ,(string-append triplet "/lib64")))))) + (arguments + `(#:configure-flags '(,(string-append "--host=3D" triplet)) + #:phases + (modify-phases %standard-phases + (add-before 'configure 'setenv + (lambda* (#:key inputs #:allow-other-keys) + (let ((xgcc-core (assoc-ref inputs "xgcc-core")) + (mingw-headers (string-append (getcwd) "/mingw-w64-he= aders"))) + (setenv "CPP" + (string-append xgcc-core ,(string-append "/bin/" = triplet "-cpp"))) + (setenv "CROSS_C_INCLUDE_PATH" + (string-append + mingw-headers + ":" mingw-headers "/include" + ":" mingw-headers "/crt" + ":" mingw-headers "/defaults/include" + ":" mingw-headers "/direct-x/include")))))) + #:make-flags (list "DEFS=3D-DHAVE_CONFIG_H -D__MINGW_HAS_DXSDK=3D= 1") + #:tests? #f ; compiles and includes glibc headers + #:strip-binaries? #f)) + (home-page "https://mingw-w64.org") + (synopsis "Minimalist GNU for Windows") + (description + "Minimalist GNU for Windows (@dfn{MinGW}) is a complete software development environment for creating native Microsoft Windows applications= . It includes a set of Windows-specific header files and static import libra= ries @@ -89,4 +90,12 @@ runtime dynamic-link libraries (@dfn{DLL}s). Mingw-w64 is an advancement of the original mingw.org project and provides several new APIs such as DirectX and DDK, and 64-bit support.") - (license license:fdl1.3+))) + (license license:fdl1.3+)))) + +(define-public mingw-w64-i686 + (make-mingw-w64 "i686")) + +(define-public mingw-w64-x86_64 + (make-mingw-w64 "x86_64")) + +(define-public mingw-w64 mingw-w64-i686) -- 2.22.0 Cheers, Carl Dong contact@carldong.me "I fight for the users" From debbugs-submit-bounces@debbugs.gnu.org Wed Aug 14 13:56:39 2019 Received: (at 37012) by debbugs.gnu.org; 14 Aug 2019 17:56:39 +0000 Received: from localhost ([127.0.0.1]:49643 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hxxVm-0003FJ-S6 for submit@debbugs.gnu.org; Wed, 14 Aug 2019 13:56:39 -0400 Received: from mail1.protonmail.ch ([185.70.40.18]:55504) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hxxVl-0003F4-Ri for 37012@debbugs.gnu.org; Wed, 14 Aug 2019 13:56:38 -0400 Date: Wed, 14 Aug 2019 17:56:26 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=carldong.me; s=protonmail; t=1565805390; bh=kS8YU8k2Xq74SVbp8xbGqzUpxNMHPxJc66WQoNO3qFI=; h=Date:To:From:Cc:Reply-To:Subject:In-Reply-To:References: Feedback-ID:From; b=Z08QiehuN+Twc1l3kzPVKADfVpstEXL0d4JXi3Xns57S0GLB6oa1Qlagb49uR9ke0 ZhQofMj7Xe+2rTGpolheyrTcKaKu8fhEKTOh/aapBM/TnOoKinx3ql3GdETx4uxwQi WWaXnrlzigjcDPF3wVm1OsLg9gUre73dvCDlB6K8= To: "Thompson, David" From: Carl Dong Subject: Re: [bug#37012] [PATCH] gnu: mingw: Add x86_64 support. Message-ID: <9wfR-EPJQK4vTppzl9yieynFry2GoHZQvzZNFva5NLc5AuTT620JctolB3v38prYdt6AIcxpry5EM8oKll23WoZGCbSdf4n4tI7rCVnZHTE=@carldong.me> In-Reply-To: References: Feedback-ID: a8j8tDUaJ4AYuDVBywMTwsJebN4w8TVXadJLsJb8td3t3dZi9RdXFlPaQvoFKnI9KgXySsPXcRkajVyY0cGTcA==:Ext:ProtonMail MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-1.2 required=7.0 tests=ALL_TRUSTED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on mail.protonmail.ch X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 37012 Cc: "37012@debbugs.gnu.org" <37012@debbugs.gnu.org> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Carl Dong Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) Dave, That's fantastic news :-) I also have a preliminary version of the nsis installer packager, please le= t me know if you'd have use for it! Cheers, Carl Dong contact@carldong.me "I fight for the users" From debbugs-submit-bounces@debbugs.gnu.org Wed Aug 14 14:41:04 2019 Received: (at 37012) by debbugs.gnu.org; 14 Aug 2019 18:41:04 +0000 Received: from localhost ([127.0.0.1]:49657 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hxyCh-0004ep-VF for submit@debbugs.gnu.org; Wed, 14 Aug 2019 14:41:03 -0400 Received: from eggs.gnu.org ([209.51.188.92]:60947) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hxyCe-0004ea-Sd for 37012@debbugs.gnu.org; Wed, 14 Aug 2019 14:40:58 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:32787) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hxyCX-0001ys-CH; Wed, 14 Aug 2019 14:40:51 -0400 Received: from [2001:980:1b4f:1:42d2:832d:bb59:862] (port=47054 helo=dundal.peder.onsbrabantnet.nl) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1hxyCW-0007Ch-Tn; Wed, 14 Aug 2019 14:40:49 -0400 From: Jan Nieuwenhuizen To: Carl Dong Subject: Re: [bug#37012] [PATCH] gnu: mingw: Add x86_64 support. Organization: AvatarAcademy.nl References: <87o90sitvi.fsf@gnu.org> <874l2kmdya.fsf@gnu.org> X-Url: http://AvatarAcademy.nl Date: Wed, 14 Aug 2019 20:40:46 +0200 In-Reply-To: (Carl Dong's message of "Wed, 14 Aug 2019 17:54:59 +0000") Message-ID: <87pnl7d1zl.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 37012 Cc: "37012@debbugs.gnu.org" <37012@debbugs.gnu.org> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Carl Dong writes: Hello Carl, > Here's the updated patch that I've tested. Let me know if this works for = you! :-) Thanks! > From e6df2d6f9b47b02abec01a16f2d0b1271dcec1d2 Mon Sep 17 00:00:00 2001 > From: Carl Dong > Date: Wed, 14 Aug 2019 13:46:53 -0400 > Subject: [PATCH] gnu: mingw: Add x86_64 support. It looks good and I can compile `hello'; the traditional 32 bit version: ./pre-inst-env guix build --target=3Di686-w64-mingw32 hello and now also ./pre-inst-env guix build --target=3Dx86_64-w64-mingw32 hello However, while the 32 bit still works for me, the 64 bit version does not. How is that for you? Do you have any idea how to verify if the x86_64 hello.exe is OK or how to debug that? --8<---------------cut here---------------start------------->8--- 20:33:04 janneke@dundal:~/src/guix/wip [env] $ file /gnu/store/4hayc4wmxz0b0bw555n5gny7xkhg7w6y-hello-2.10/bin/hello.exe /gnu/store/4hayc4wmxz0b0bw555n5gny7xkhg7w6y-hello-2.10/bin/hello.exe: PE32 = executable (console) Intel 80386, for MS Windows 20:34:04 janneke@dundal:~/src/guix/wip [env] $ guix environment --ad-hoc wine -- wine /gnu/store/4hayc4wmxz0b0bw555n5gny= 7xkhg7w6y-hello-2.10/bin/hello.exe=20 Hello, world! 20:34:14 janneke@dundal:~/src/guix/wip [env] $ file /gnu/store/v83ag9ahcg5g5qp06rlvjmvrydyriv7p-hello-2.10/bin/hello.exe= =20 /gnu/store/v83ag9ahcg5g5qp06rlvjmvrydyriv7p-hello-2.10/bin/hello.exe: PE32+= executable (console) x86-64, for MS Windows 20:34:22 janneke@dundal:~/src/guix/wip [env] $ guix environment --ad-hoc wine -- wine /gnu/store/v83ag9ahcg5g5qp06rlvjmv= rydyriv7p-hello-2.10/bin/hello.exe wine: Bad EXE format for Z:\gnu\store\v83ag9ahcg5g5qp06rlvjmvrydyriv7p-hell= o-2.10\bin\hello.exe. [193] --8<---------------cut here---------------end--------------->8--- Possibly I'm even using wine wrong? Other than that the patch looks fine. It would be nice if we knew wether the 64bit version can produce something useful, though. Can you/someone please shed some light on that? Greetings, janneke --=20 Jan Nieuwenhuizen | GNU LilyPond http://lilypond.org Freelance IT http://JoyofSource.com | Avatar=C2=AE http://AvatarAcademy.com From debbugs-submit-bounces@debbugs.gnu.org Wed Aug 14 14:50:18 2019 Received: (at 37012) by debbugs.gnu.org; 14 Aug 2019 18:50:18 +0000 Received: from localhost ([127.0.0.1]:49665 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hxyLh-0004t8-VJ for submit@debbugs.gnu.org; Wed, 14 Aug 2019 14:50:18 -0400 Received: from mail4.protonmail.ch ([185.70.40.27]:29271) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hxyLg-0004sq-1c for 37012@debbugs.gnu.org; Wed, 14 Aug 2019 14:50:16 -0400 Date: Wed, 14 Aug 2019 18:50:04 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=carldong.me; s=protonmail; t=1565808608; bh=b8SIe5LpgdcLExW+W8yvRjpegC5uGWD9QpVEozLIL34=; h=Date:To:From:Cc:Reply-To:Subject:In-Reply-To:References: Feedback-ID:From; b=DOotZw7EfaWc6KUckm7FEzQY30aVoEohKdQvHYASmSQDnt1f3lfSFMgawRDWOONNS qdAmVE+aI6vcglrDAT4QICMln5BEnAepYVoWGm/bEwpKSeI+5d1hViGwhrlR7flpvb N8Lmc7bG5U2RiG+VtErVHZskaGYCBb7VD8MRuG8g= To: Jan Nieuwenhuizen From: Carl Dong Subject: Re: [bug#37012] [PATCH] gnu: mingw: Add x86_64 support. Message-ID: In-Reply-To: <87pnl7d1zl.fsf@gnu.org> References: <87o90sitvi.fsf@gnu.org> <874l2kmdya.fsf@gnu.org> <87pnl7d1zl.fsf@gnu.org> Feedback-ID: a8j8tDUaJ4AYuDVBywMTwsJebN4w8TVXadJLsJb8td3t3dZi9RdXFlPaQvoFKnI9KgXySsPXcRkajVyY0cGTcA==:Ext:ProtonMail MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-1.2 required=7.0 tests=ALL_TRUSTED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on mail.protonmail.ch X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 37012 Cc: "37012\\@debbugs.gnu.org" <37012@debbugs.gnu.org> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Carl Dong Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) Hey janneke! It would seem from the synopsis that the version of wine packaged with Guix= is 32-bit only. I will test out the 64-bit hello binary when I get home on= my Windows machine! Cheers, Carl Dong contact@carldong.me "I fight for the users" =E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90 Original Me= ssage =E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90 On Wednesday, August 14, 2019 6:40 PM, Jan Nieuwenhuizen = wrote: > Carl Dong writes: > > Hello Carl, > > > Here's the updated patch that I've tested. Let me know if this works fo= r you! :-) > > Thanks! > > > From e6df2d6f9b47b02abec01a16f2d0b1271dcec1d2 Mon Sep 17 00:00:00 2001 > > From: Carl Dong contact@carldong.me > > Date: Wed, 14 Aug 2019 13:46:53 -0400 > > Subject: [PATCH] gnu: mingw: Add x86_64 support. > > It looks good and I can compile `hello'; the traditional 32 bit version: > > ./pre-inst-env guix build --target=3Di686-w64-mingw32 hello > > and now also > > ./pre-inst-env guix build --target=3Dx86_64-w64-mingw32 hello > > However, while the 32 bit still works for me, the 64 bit version does > not. How is that for you? Do you have any idea how to verify if the > x86_64 hello.exe is OK or how to debug that? > > --8<---------------cut here---------------start------------->8--- > 20:33:04 janneke@dundal:~/src/guix/wip [env] > $ file /gnu/store/4hayc4wmxz0b0bw555n5gny7xkhg7w6y-hello-2.10/bin/hello.e= xe > /gnu/store/4hayc4wmxz0b0bw555n5gny7xkhg7w6y-hello-2.10/bin/hello.exe: PE3= 2 executable (console) Intel 80386, for MS Windows > 20:34:04 janneke@dundal:~/src/guix/wip [env] > $ guix environment --ad-hoc wine -- wine /gnu/store/4hayc4wmxz0b0bw555n5g= ny7xkhg7w6y-hello-2.10/bin/hello.exe > Hello, world! > 20:34:14 janneke@dundal:~/src/guix/wip [env] > $ file /gnu/store/v83ag9ahcg5g5qp06rlvjmvrydyriv7p-hello-2.10/bin/hello.e= xe > /gnu/store/v83ag9ahcg5g5qp06rlvjmvrydyriv7p-hello-2.10/bin/hello.exe: PE3= 2+ executable (console) x86-64, for MS Windows > 20:34:22 janneke@dundal:~/src/guix/wip [env] > $ guix environment --ad-hoc wine -- wine /gnu/store/v83ag9ahcg5g5qp06rlvj= mvrydyriv7p-hello-2.10/bin/hello.exe > wine: Bad EXE format for Z:\gnu\store\v83ag9ahcg5g5qp06rlvjmvrydyriv7p-he= llo-2.10\bin\hello.exe. > [193] > --8<---------------cut here---------------end--------------->8--- > > Possibly I'm even using wine wrong? > > Other than that the patch looks fine. It would be nice if we knew > wether the 64bit version can produce something useful, though. Can > you/someone please shed some light on that? > > Greetings, > janneke > > -------------------------------------------------------------------------= ---------------------------------------------------------------------------= ---------------------------------------------------------------------------= ------------- > > Jan Nieuwenhuizen janneke@gnu.org | GNU LilyPond http://lilypond.org > Freelance IT http://JoyofSource.com | Avatar=C2=AE http://AvatarAcademy.c= om From debbugs-submit-bounces@debbugs.gnu.org Wed Aug 14 15:34:09 2019 Received: (at 37012-done) by debbugs.gnu.org; 14 Aug 2019 19:34:09 +0000 Received: from localhost ([127.0.0.1]:49696 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hxz28-00063A-Mv for submit@debbugs.gnu.org; Wed, 14 Aug 2019 15:34:09 -0400 Received: from eggs.gnu.org ([209.51.188.92]:42026) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hxz26-00062S-1f for 37012-done@debbugs.gnu.org; Wed, 14 Aug 2019 15:34:06 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:33588) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hxz1z-00022C-QX; Wed, 14 Aug 2019 15:33:59 -0400 Received: from [2001:980:1b4f:1:42d2:832d:bb59:862] (port=48014 helo=dundal.peder.onsbrabantnet.nl) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1hxz1z-0001ss-C1; Wed, 14 Aug 2019 15:33:59 -0400 From: Jan Nieuwenhuizen To: Carl Dong Subject: Re: [bug#37012] [PATCH] gnu: mingw: Add x86_64 support. Organization: AvatarAcademy.nl References: <87o90sitvi.fsf@gnu.org> <874l2kmdya.fsf@gnu.org> <87pnl7d1zl.fsf@gnu.org> X-Url: http://AvatarAcademy.nl Date: Wed, 14 Aug 2019 21:33:56 +0200 In-Reply-To: (Carl Dong's message of "Wed, 14 Aug 2019 18:50:04 +0000") Message-ID: <87lfvvcziz.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 37012-done Cc: "37012@debbugs.gnu.org" <37012-done@debbugs.gnu.org> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Carl Dong writes: Hello Carl, > It would seem from the synopsis that the version of wine packaged with > Guix is 32-bit only. 'Doh! > I will test out the 64-bit hello binary when I get home on my Windows > machine! Thanks, but no pressing need for that now, look: --8<---------------cut here---------------start------------->8--- 21:27:49 janneke@dundal:~/src/guix/wip [env] $ guix environment --ad-hoc wine64 -- wine64 /gnu/store/v83ag9ahcg5g5qp06rl= vjmvrydyriv7p-hello-2.10/bin/hello.exe Hello, world! --8<---------------cut here---------------end--------------->8--- Pushed to master as 67dac6b8920755cb011047157bb7b4fae4760143 Thanks again! janneke --=20 Jan Nieuwenhuizen | GNU LilyPond http://lilypond.org Freelance IT http://JoyofSource.com | Avatar=C2=AE http://AvatarAcademy.com From unknown Sat Jun 21 10:33:00 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Thu, 12 Sep 2019 11:24:04 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator