Index | Thread | Search

From:
Stuart Henderson <stu@spacehopper.org>
Subject:
sdl2 vs llvm22 on i386
To:
Thomas Frohwein <tfrohwein@fastmail.com>
Cc:
ports <ports@openbsd.org>
Date:
Sat, 30 May 2026 14:59:02 +0100

Download raw body.

Thread
similar to the issue with libpixman, devel/sdl2 fails on i386 with LLVM 22.
from naddy's comment:

| LLVM has dropped the ability to generate vectorized code using compiler
| intrinsics for chips with MMX but without SSE2.

presumably this applies to SSE as well.

I've committed already to unbreak my bulk (the list of ports depending
on this is pretty long), but mailing to let you know in case you would
like to do something different longer-term.

Index: Makefile
===================================================================
RCS file: /cvs/ports/devel/sdl2/Makefile,v
diff -u -p -r1.69 Makefile
--- Makefile	22 Feb 2026 18:26:23 -0000	1.69
+++ Makefile	30 May 2026 13:56:12 -0000
@@ -1,6 +1,7 @@
 COMMENT=	cross-platform multimedia library
 
 V=		2.32.10
+REVISION=	0
 DISTNAME=	SDL2-${V}
 PKGNAME=	sdl2-${V}
 
@@ -53,6 +54,12 @@ CONFIGURE_ENV+=	CPPFLAGS="-I${LOCALBASE}
 
 .if ${MACHINE_ARCH} == "hppa"
 CONFIGURE_ARGS+= --disable-atomic
+.endif
+
+.if ${MACHINE_ARCH} == "i386"
+CONFIGURE_ARGS+= --disable-mmx \
+		--disable-sse \
+		--enable-sse2
 .endif
 
 # The assembly code contains AltiVec instructions, whose support is not