[gnome-continuous] Untag mesa and get it building against LLVM 3.3
- From: Owen Taylor <otaylor src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-continuous] Untag mesa and get it building against LLVM 3.3
- Date: Wed, 12 Oct 2016 23:09:46 +0000 (UTC)
commit 6f3d1b3b80b538923ac6bef3c75b339a39c716d5
Author: Owen W. Taylor <otaylor fishsoup net>
Date: Wed Oct 12 13:32:18 2016 -0400
Untag mesa and get it building against LLVM 3.3
In order to find the 3.3 of LLVM that is build in our yocto base,
it's necessary to patch mesa's configure.ac so that it can be
made to look in /usr/bin/llvm3.3 for llvm-config. It's also necessary
to pass a --host value, since llvm config is installed as
x86_64-gnomeostree-linux. If we start building on other architectures
this will need to adjustment.
(Before the Yocto rebase, we had a LLVM 3.4 custom recipe, that stopped
working; LLVM 3.3 and 3.4 are both sufficient to get llvmpipe working, but
not new enough for some other parts of Mesa like amdgpu, the radv Vulkan support,
etc. If we want those, we'll need to update to something considerably
newer.)
manifest.json | 6 ++--
patches/mesa-llvm-config-dir.patch | 46 ++++++++++++++++++++++++++++++++++++
2 files changed, 49 insertions(+), 3 deletions(-)
---
diff --git a/manifest.json b/manifest.json
index d912248..2821de9 100644
--- a/manifest.json
+++ b/manifest.json
@@ -373,14 +373,13 @@
"patches": ["python-mako-buildsys.patch"]},
{"src": "fd-mesa:mesa",
- "tag": "11.1-branchpoint-1703-g4e59362d1b8846371f12252c49b87f6f7080967b",
- "tag-reason": "intel driver compilation error, not reported yet AFAIK",
"cflags": {
"x86_64": "-g -m64 -mtune=generic -fno-rtti",
"i686": "-g -m32 -march=i686 -mtune=atom -fasynchronous-unwind-tables -fno-rtti"
},
- "patches": ["mesa-nv50-fix-build.patch"],
+ "patches": ["mesa-nv50-fix-build.patch", "mesa-llvm-config-dir.patch"],
"config-opts": [
+ "--host=x86_64-gnomeostree-linux",
"--enable-pic",
"--disable-asm",
"--disable-glw",
@@ -396,6 +395,7 @@
"--enable-gallium-gbm",
"--enable-gallium-egl",
"--enable-xa",
+ "--with-llvm-config-dir=/usr/bin/llvm3.3",
"--with-gallium-drivers=svga,r300,r600,nouveau,swrast,virgl",
"--enable-gallium-llvm",
"--with-dri-drivers=nouveau,radeon,r200,i915,i965,swrast"
diff --git a/patches/mesa-llvm-config-dir.patch b/patches/mesa-llvm-config-dir.patch
new file mode 100644
index 0000000..6c68300
--- /dev/null
+++ b/patches/mesa-llvm-config-dir.patch
@@ -0,0 +1,46 @@
+From 9eed2c3153d8f0e8b01b55b9c6c10030434a588e Mon Sep 17 00:00:00 2001
+From: Owen W. Taylor <otaylor fishsoup net>
+Date: Tue, 11 Oct 2016 18:53:14 +0000
+Subject: [PATCH] Add a --llvm-config-dir option
+
+The --llvm-prefix option doesn't quite work when building against
+a yocto base, because the llvm-config-binary is in
+$bindir/llvm3.3/<targetname>-llvm-config, which is not $prefix/bin
+for any prefix.
+---
+ configure.ac | 12 ++++++++++--
+ 1 files changed, 10 insertions(+), 2 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index b414edd..f02ff89 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -2162,6 +2162,11 @@ AC_ARG_WITH([llvm-prefix],
+ [llvm_prefix="$withval"],
+ [llvm_prefix=''])
+
++AC_ARG_WITH([llvm-config-dir],
++ [AS_HELP_STRING([--with-llvm-config-dir],
++ [Directory where llvm-config binary lives])],
++ [llvm_config_dir="$withval"],
++ [llvm_config_dir=''])
+
+ # Call this inside ` ` to get the return value.
+ # $1 is the llvm-config command with arguments.
+@@ -2207,8 +2212,11 @@ if test "x$enable_gallium_llvm" = xauto; then
+ esac
+ fi
+ if test "x$enable_gallium_llvm" = xyes || test "x$HAVE_RADEON_VULKAN" = xyes; then
+- if test -n "$llvm_prefix"; then
+- AC_PATH_TOOL([LLVM_CONFIG], [llvm-config], [no], ["$llvm_prefix/bin"])
++ if test -n "$llvm_prefix" -a -z "$llvm_config_dir" ; then
++ llvm_config_dir="$llvm_prefix/bin"
++ fi
++ if test -n "$llvm_config_dir"; then echo ============== $llvm_config_dir/${ac_tool_prefix}llvm-config
++ AC_PATH_TOOL([LLVM_CONFIG], [llvm-config], [no], ["$llvm_config_dir"])
+ else
+ AC_PATH_TOOL([LLVM_CONFIG], [llvm-config], [no])
+ fi
+--
+1.7.1
+
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]