Hide Forgot
LLVM is not supported on PPC64 http://llvm.org/bugs/show_bug.cgi?id=3729 with following patch I am able to build mesa for ppc and ppc64 diff --git a/mesa.spec b/mesa.spec index 34fb028..78323ee 100644 --- a/mesa.spec +++ b/mesa.spec @@ -6,6 +6,14 @@ %define with_hardware 1 %endif +%ifarch ppc64 +# LLVM is not supported on PPC64 +# http://llvm.org/bugs/show_bug.cgi?id=3729 +%define with_llvm 0 +%else +%define with_llvm 1 +%endif + %define _default_patch_fuzz 2 %define manpages gl-manpages-1.0.1 @@ -64,7 +72,9 @@ BuildRequires: libXi-devel BuildRequires: libXmu-devel BuildRequires: elfutils BuildRequires: python +%if %{with_llvm} BuildRequires: llvm-static +%endif BuildRequires: libxml2-python BuildRequires: libudev-devel BuildRequires: libtalloc-devel @@ -114,6 +124,7 @@ Group: User Interface/X Hardware Support %description dri-filesystem Mesa DRI driver filesystem +%if %{with_llvm} %package dri-llvmcore Summary: Mesa common LLVM support Group: User Interface/X Hardware Support @@ -122,6 +133,7 @@ Requires: mesa-dri-filesystem%{?_isa} Common DSO for LLVM support for gallium-based DRI drivers. This package exists solely as a disk space hack for Mesa. Do not link against this library if you are not Mesa. You have been warned. +%endif %package dri-drivers Summary: Mesa-based DRI drivers @@ -251,10 +263,12 @@ make clean # just to be sure... [ `find . -name \*.o | wc -l` -eq 0 ] || exit 1 +%if %{with_llvm} # build llvmcore TOP=`pwd` make -f %{SOURCE4} llvmcore mkdir -p %{_lib} mv libllvmcore*.so %{_lib} +%endif # now build the rest of mesa %configure %{common_flags} \ @@ -267,7 +281,9 @@ mv libllvmcore*.so %{_lib} --enable-egl \ --enable-gles1 \ --enable-gles2 \ +%if %{with_llvm} --enable-gallium-llvm \ +%endif --disable-gallium-intel \ --disable-gallium-svga \ --disable-gallium-egl \ @@ -298,7 +314,9 @@ make install DESTDIR=$RPM_BUILD_ROOT DRI_DIRS= # just the DRI drivers that are sane install -d $RPM_BUILD_ROOT%{_libdir}/dri +%if %{with_llvm} install -m 0755 -t $RPM_BUILD_ROOT%{_libdir}/dri %{_lib}/libllvmcore-2.8.so >& /dev/null +%endif # use gallium driver iff built [ -f %{_lib}/gallium/r300_dri.so ] && cp %{_lib}/gallium/r300_dri.so %{_lib}/r300_dri.so [ -f %{_lib}/gallium/r600_dri.so ] && cp %{_lib}/gallium/r600_dri.so %{_lib}/r600_dri.so @@ -376,9 +394,11 @@ rm -rf $RPM_BUILD_ROOT %doc docs/COPYING %dir %{_libdir}/dri +%if %{with_llvm} %files dri-llvmcore %defattr(-,root,root,-) %{_libdir}/dri/libllvmcore-2.8.so +%endif %files dri-drivers %defattr(-,root,root,-) @@ -387,8 +407,10 @@ rm -rf $RPM_BUILD_ROOT %{_libdir}/dri/r200_dri.so %{_libdir}/dri/r300_dri.so %{_libdir}/dri/r600_dri.so +%ifnarch ppc ppc64 %{_libdir}/dri/i915_dri.so %{_libdir}/dri/i965_dri.so +%endif %{_libdir}/dri/nouveau_dri.so %{_libdir}/dri/nouveau_vieux_dri.so %endif @@ -402,13 +424,13 @@ rm -rf $RPM_BUILD_ROOT %ifarch %{ix86} %{_libdir}/dri/i810_dri.so %{_libdir}/dri/sis_dri.so -%endif %{_libdir}/dri/mga_dri.so -%{_libdir}/dri/r128_dri.so %{_libdir}/dri/savage_dri.so -%{_libdir}/dri/tdfx_dri.so %{_libdir}/dri/unichrome_dri.so %endif +%{_libdir}/dri/r128_dri.so +%{_libdir}/dri/tdfx_dri.so +%endif %files libGL-devel %defattr(-,root,root,-) @@ -473,6 +495,10 @@ rm -rf $RPM_BUILD_ROOT %{_libdir}/libOSMesa.so %changelog +* Mon Feb 07 2011 Adrian Reber <adrian> 7.10-0.25 +- build without llvm on ppc64 +- exclude i915_dri, i965_dri, mga_dri, savage_dri, unichrome_dri on ppc/ppc64 + * Thu Jan 20 2011 Ben Skeggs <bskeggs> 7.10-0.24 - nouveau: move out of -experimental
*** This bug has been marked as a duplicate of bug 678933 ***
*** Bug 678933 has been marked as a duplicate of this bug. ***
other way around
we now have llvm on ppc and ppc64, closing