Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 814824 - media-libs/mesa-21: Allow disabling sse2
Summary: media-libs/mesa-21: Allow disabling sse2
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Gentoo X packagers
URL:
Whiteboard:
Keywords: PATCH
Depends on:
Blocks:
 
Reported: 2021-09-25 16:29 UTC by Calvin Walton
Modified: 2021-10-30 23:04 UTC (History)
3 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
mesa 21.2.1 add sse option patch (mesa-21.2.1-sse2.diff,694 bytes, patch)
2021-09-25 18:12 UTC, Calvin Walton
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Calvin Walton 2021-09-25 16:29:10 UTC
As of mesa 21.x, the meson build system is adding the flags "-msse2 -mfpmath=sse" to compilation commands on all x86 builds.

This causes problems for systems without sse2, including my i586 system, and processors such as Pentium 3 and Athlon.

An option is provided in the meson build system to disable sse2: 
https://cgit.freedesktop.org/mesa/mesa/tree/meson_options.txt?h=21.2#n502

Please add an option CPU_FLAGS_X86="sse2" to the mesa ebuild that controls the "sse2" option.
Comment 1 Calvin Walton 2021-09-25 18:12:05 UTC
Created attachment 741303 [details, diff]
mesa 21.2.1 add sse option patch

I've attached an example patch to add the option to the mesa 21.2.1 ebuild, which fixes illegal instruction issues on my i586 test system. Similar patches are suitable for all of the mesa 21.* and 9999 ebuilds.
Comment 2 Larry the Git Cow gentoo-dev 2021-10-30 23:04:26 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ff813645a6e8b86962dbb4152a6cafa00035a2bb

commit ff813645a6e8b86962dbb4152a6cafa00035a2bb
Author:     Matt Turner <mattst88@gentoo.org>
AuthorDate: 2021-10-30 20:28:58 +0000
Commit:     Matt Turner <mattst88@gentoo.org>
CommitDate: 2021-10-30 23:04:12 +0000

    media-libs/mesa: Add CPU_FLAGS_X86=sse2 option
    
    Thanks to Calvin Walton for the suggestion and the patch!
    
    Closes: https://bugs.gentoo.org/814824
    Signed-off-by: Matt Turner <mattst88@gentoo.org>

 media-libs/mesa/mesa-21.1.8-r1.ebuild | 3 ++-
 media-libs/mesa/mesa-9999.ebuild      | 3 ++-
 2 files changed, 4 insertions(+), 2 deletions(-)