unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
* [bug#44681] [PATCH] gnu: gnubg: Prevent building with avx instructions.
@ 2020-11-16 12:17 Michael Rohleder
  2020-11-18  2:27 ` Kei Kebreau
  0 siblings, 1 reply; 4+ messages in thread
From: Michael Rohleder @ 2020-11-16 12:17 UTC (permalink / raw)
  To: 44681; +Cc: Michael Rohleder

* gnu/packages/games.scm (gnubg): Prevent building with avx instructions.
[arguments]: Add configure-flags for Intel systems.
---
 gnu/packages/games.scm | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/games.scm b/gnu/packages/games.scm
index 97b0cb976d..12cc64fefa 100644
--- a/gnu/packages/games.scm
+++ b/gnu/packages/games.scm
@@ -1605,7 +1605,14 @@ such as chess or stockfish.")
     (native-inputs `(("python-2" ,python-2)
                      ("pkg-config" ,pkg-config)))
     (arguments
-     `(#:phases
+     `(#:configure-flags
+       ;; SSE instructions are available on Intel systems only.
+       (list ,@(if (any (cute string-prefix? <> (or (%current-target-system)
+                                                    (%current-system)))
+                        '("x86_64" "i686"))
+                   '("--enable-simd=sse2") ; prevent avx instructions
+                   '()))
+       #:phases
        (modify-phases %standard-phases
          (add-after 'install 'install-desktop-file
            (lambda* (#:key outputs #:allow-other-keys)
-- 
2.29.2





^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [bug#44681] [PATCH] gnu: gnubg: Prevent building with avx instructions.
  2020-11-16 12:17 [bug#44681] [PATCH] gnu: gnubg: Prevent building with avx instructions Michael Rohleder
@ 2020-11-18  2:27 ` Kei Kebreau
  2020-11-18  6:53   ` Michael Rohleder
  0 siblings, 1 reply; 4+ messages in thread
From: Kei Kebreau @ 2020-11-18  2:27 UTC (permalink / raw)
  To: Michael Rohleder; +Cc: 44681

[-- Attachment #1: Type: text/plain, Size: 1702 bytes --]

Hi Michael!

Michael Rohleder <mike@rohleder.de> writes:

> * gnu/packages/games.scm (gnubg): Prevent building with avx instructions.
> [arguments]: Add configure-flags for Intel systems.

I'd modify the commit message to be a bit shorter, like so:

gnu: gnubg: Prevent building with AVX instructions.

* gnu/packages/games.scm (gnubg)[arguments]: Add configure-flags for Intel
systems to build without AVX instructions.

> ---
>  gnu/packages/games.scm | 9 ++++++++-
>  1 file changed, 8 insertions(+), 1 deletion(-)
>
> diff --git a/gnu/packages/games.scm b/gnu/packages/games.scm
> index 97b0cb976d..12cc64fefa 100644
> --- a/gnu/packages/games.scm
> +++ b/gnu/packages/games.scm
> @@ -1605,7 +1605,14 @@ such as chess or stockfish.")
>      (native-inputs `(("python-2" ,python-2)
>                       ("pkg-config" ,pkg-config)))
>      (arguments
> -     `(#:phases
> +     `(#:configure-flags
> +       ;; SSE instructions are available on Intel systems only.
> +       (list ,@(if (any (cute string-prefix? <> (or (%current-target-system)
> +                                                    (%current-system)))
> +                        '("x86_64" "i686"))
> +                   '("--enable-simd=sse2") ; prevent avx instructions
> +                   '()))
> +       #:phases
>         (modify-phases %standard-phases
>           (add-after 'install 'install-desktop-file
>             (lambda* (#:key outputs #:allow-other-keys)

Otherwise, the patch looks and works fine.  I didn't even know that GNU
Backgammon didn't work on my machine until I tested this patch!

Please let me know whether you're okay with the commit message
modification, and I'll push this for you.

Thanks,
Kei

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [bug#44681] [PATCH] gnu: gnubg: Prevent building with avx instructions.
  2020-11-18  2:27 ` Kei Kebreau
@ 2020-11-18  6:53   ` Michael Rohleder
  2020-11-18 14:05     ` bug#44681: " Kei Kebreau
  0 siblings, 1 reply; 4+ messages in thread
From: Michael Rohleder @ 2020-11-18  6:53 UTC (permalink / raw)
  To: Kei Kebreau; +Cc: 44681

[-- Attachment #1: Type: text/plain, Size: 382 bytes --]

Hi Kei!

Kei Kebreau <kkebreau@posteo.net> writes:
> Please let me know whether you're okay with the commit message
> modification, and I'll push this for you.

This is perfectly fine!
Thank you very much for reviewing, testing, rewriting, asking and
pushing ;)

-- 
Some people claim that the UNIX learning curve is steep, but at least you
only have to climb it once.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 511 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* bug#44681: [PATCH] gnu: gnubg: Prevent building with avx instructions.
  2020-11-18  6:53   ` Michael Rohleder
@ 2020-11-18 14:05     ` Kei Kebreau
  0 siblings, 0 replies; 4+ messages in thread
From: Kei Kebreau @ 2020-11-18 14:05 UTC (permalink / raw)
  To: Michael Rohleder; +Cc: 44681-done

[-- Attachment #1: Type: text/plain, Size: 398 bytes --]

Michael Rohleder <mike@rohleder.de> writes:

> Hi Kei!
>
> Kei Kebreau <kkebreau@posteo.net> writes:
>> Please let me know whether you're okay with the commit message
>> modification, and I'll push this for you.
>
> This is perfectly fine!
> Thank you very much for reviewing, testing, rewriting, asking and
> pushing ;)

You're welcome!  This patch has been pushed to master as commit
82df93e27c.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2020-11-18 14:07 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-11-16 12:17 [bug#44681] [PATCH] gnu: gnubg: Prevent building with avx instructions Michael Rohleder
2020-11-18  2:27 ` Kei Kebreau
2020-11-18  6:53   ` Michael Rohleder
2020-11-18 14:05     ` bug#44681: " Kei Kebreau

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).