[Mesa-dev] [Bug 83669] fix build with gcc link time optimizer
bugzilla-daemon at freedesktop.org
bugzilla-daemon at freedesktop.org
Wed Sep 10 04:44:54 PDT 2014
https://bugs.freedesktop.org/show_bug.cgi?id=83669
--- Comment #7 from Marc Dietrich <marvin24 at gmx.de> ---
turns out that we need to specify -msse4.1 to certain LDFLAGS (patch below),
but I guess this crashes on platforms not supporting sse4.1.
diff --git a/src/gallium/targets/dri/Makefile.am
b/src/gallium/targets/dri/Makefile.am
index 1c33a91..e8b691f 100644
--- a/src/gallium/targets/dri/Makefile.am
+++ b/src/gallium/targets/dri/Makefile.am
@@ -38,6 +38,10 @@ gallium_dri_la_LDFLAGS += \
-Wl,--dynamic-list=$(top_srcdir)/src/gallium/targets/dri-vdpau.dyn
endif # HAVE_LD_DYNAMIC_LIST
+if SSE41_SUPPORTED
+gallium_dri_la_LDFLAGS += -msse4.1
+endif
+
gallium_dri_la_LIBADD = \
$(top_builddir)/src/mesa/libmesagallium.la \
$(top_builddir)/src/mesa/drivers/dri/common/libdricommon.la \
diff --git a/src/gallium/targets/egl-static/Makefile.am
b/src/gallium/targets/egl-static/Makefile.am
index 84f3338..89d948f 100644
--- a/src/gallium/targets/egl-static/Makefile.am
+++ b/src/gallium/targets/egl-static/Makefile.am
@@ -157,6 +157,10 @@ endif
egl_gallium_la_LDFLAGS = $(AM_LDFLAGS)
egl_gallium_la_CPPFLAGS = $(AM_CPPFLAGS)
+if SSE41_SUPPORTED
+egl_gallium_la_LDFLAGS += -msse4.1
+endif
+
if HAVE_GALLIUM_I915
egl_gallium_la_CPPFLAGS += -DGALLIUM_I915
egl_gallium_la_LIBADD += \
diff --git a/src/gallium/targets/osmesa/Makefile.am
b/src/gallium/targets/osmesa/Makefile.am
index 3a554a9..f0bd7fb 100644
--- a/src/gallium/targets/osmesa/Makefile.am
+++ b/src/gallium/targets/osmesa/Makefile.am
@@ -57,6 +57,10 @@ if HAVE_SHARED_GLAPI
SHARED_GLAPI_LIB = $(top_builddir)/src/mapi/shared-glapi/libglapi.la
endif
+if SSE41_SUPPORTED
+lib at OSMESA_LIB@_la_LDFLAGS += -msse4.1
+endif
+
lib at OSMESA_LIB@_la_LIBADD = \
$(top_builddir)/src/mesa/libmesagallium.la \
$(top_builddir)/src/gallium/auxiliary/libgallium.la \
diff --git a/src/mesa/Makefile.am b/src/mesa/Makefile.am
index e71bccb..fbd133b 100644
--- a/src/mesa/Makefile.am
+++ b/src/mesa/Makefile.am
@@ -153,6 +153,7 @@ libmesagallium_la_LIBADD = \
libmesa_sse41_la_SOURCES = \
main/streaming-load-memcpy.c
libmesa_sse41_la_CFLAGS = $(AM_CFLAGS) -msse4.1
+libmesa_sse41_la_LDFLAGS = $(AM_LDFLAGS) -msse4.1
pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = gl.pc
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20140910/dd043ad3/attachment.html>
More information about the mesa-dev
mailing list