summaryrefslogtreecommitdiff
path: root/community-testing/llvm
diff options
context:
space:
mode:
authorroot <root@rshg047.dnsready.net>2011-04-08 04:18:44 +0000
committerroot <root@rshg047.dnsready.net>2011-04-08 04:18:44 +0000
commit59075f0265483f32e9ac4c67ba9e69cb019ba044 (patch)
treed0384b724b17b888dcd1cf06dce9bc25655d1ba1 /community-testing/llvm
parent3b216f42d91b33161572550f4556a9ba93d1cecb (diff)
Fri Apr 8 04:18:44 UTC 2011
Diffstat (limited to 'community-testing/llvm')
-rw-r--r--community-testing/llvm/PKGBUILD48
-rw-r--r--community-testing/llvm/cindexer-clang-path.patch10
-rw-r--r--community-testing/llvm/clang-toolchains-gcc-versions.patch12
3 files changed, 42 insertions, 28 deletions
diff --git a/community-testing/llvm/PKGBUILD b/community-testing/llvm/PKGBUILD
index 5021689f7..641daa196 100644
--- a/community-testing/llvm/PKGBUILD
+++ b/community-testing/llvm/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 43553 2011-03-27 15:18:02Z foutrelis $
+# $Id: PKGBUILD 44509 2011-04-07 21:22:51Z foutrelis $
# Maintainer: Evangelos Foutras <foutrelis@gmail.com>
# Contributor: Sebastian Nowicki <sebnow@gmail.com>
# Contributor: Devin Cofer <ranguvar{AT]archlinux[DOT}us>
@@ -9,26 +9,23 @@
# Contributor: Gerardo Exequiel Pozzi <vmlinuz386@yahoo.com.ar>
pkgname=('llvm' 'llvm-ocaml' 'clang' 'clang-analyzer')
-pkgver=2.8
-pkgrel=7
+pkgver=2.9
+_gcc_ver=4.6.0
+pkgrel=3
arch=('i686' 'x86_64')
url="http://llvm.org/"
license=('custom:University of Illinois/NCSA Open Source License')
-makedepends=('gcc-libs' 'libffi' 'python2' 'ocaml')
+makedepends=('gcc-libs' 'libffi' 'python2' 'ocaml' "gcc=$_gcc_ver")
source=(http://llvm.org/releases/$pkgver/$pkgname-$pkgver.tgz
http://llvm.org/releases/$pkgver/clang-$pkgver.tgz
- cpp-headers.patch
clang-plugin-loader-registry.patch
- clang-2.8-cindexer-clang-path.patch
- llvm-2.8-alignOf.patch
- clang-2.8-alignOf.patch)
-md5sums=('220d361b4d17051ff4bb21c64abe05ba'
- '10e14c901fc3728eecbd5b829e011b59'
- '61f7b2ba70b9a0c7103b1a8be24ac1f0'
+ cindexer-clang-path.patch
+ clang-toolchains-gcc-versions.patch)
+md5sums=('793138412d2af2c7c7f54615f8943771'
+ '634de18d04b7a4ded19ec4c17d23cfca'
'02c23b4aaca3445b8bf39fddb2f9906e'
- '338d254d6745568ebdcbe4e20b0057d5'
- 'd923655d211191d77c4437b9c1bfa851'
- '742a1a13cfdc1cb0a76b8bc3b19b190e')
+ '87a7162dbe99e9ffce6c40bd09f5f4f0'
+ '8da236120a9a287a977b575b8b905c93')
build() {
cd "$srcdir/$pkgname-$pkgver"
@@ -50,19 +47,15 @@ build() {
# Fix insecure rpath (http://bugs.archlinux.org/task/14017)
sed -i 's:$(RPATH) -Wl,$(\(ToolDir\|LibDir\|ExmplDir\))::g' Makefile.rules
- # Update hardcoded path to C++ header files
- patch -d tools/clang -Np1 -i "$srcdir/cpp-headers.patch"
-
# Get the correct list of symbols to export
# See http://lists.cs.uiuc.edu/pipermail/cfe-dev/2010-April/008559.html
patch -Np1 -i "$srcdir/clang-plugin-loader-registry.patch"
- # Fix C++0x name clashes (https://bugs.archlinux.org/task/22296)
- patch -Np0 -i "$srcdir/llvm-2.8-alignOf.patch"
- patch -d tools/clang -Np0 -i "$srcdir/clang-2.8-alignOf.patch"
-
# Fix clang path in CIndexer.cpp (https://bugs.archlinux.org/task/22799)
- patch -d tools/clang -Np1 -i "$srcdir/clang-2.8-cindexer-clang-path.patch"
+ patch -d tools/clang -Np0 -i "$srcdir/cindexer-clang-path.patch"
+
+ # Add GCC 4.6.0 to GccVersions (FS#23631)
+ patch -d tools/clang -Np1 -i "$srcdir/clang-toolchains-gcc-versions.patch"
# Apply strip option to configure
_optimize_flag="--enable-optimize"
@@ -71,16 +64,15 @@ build() {
# Include location of libffi headers in CPPFLAGS
export CPPFLAGS="$CPPFLAGS $(pkg-config --cflags libffi)"
- # Well, this is supposed to be the final release
- sed -i 's/2.8rc/2.8/g' configure
-
./configure --prefix=/usr --libdir=/usr/lib/llvm --sysconfdir=/etc \
--enable-shared --enable-libffi \
--enable-bindings=ocaml --enable-targets=all \
--disable-expensive-checks --disable-debug-runtime \
--disable-assertions --with-binutils-include=/usr/include \
- $_optimize_flag
- make
+ $_optimize_flag \
+ --with-cxx-include-root=/usr/include/c++/$_gcc_ver \
+ --with-cxx-include-arch=$CHOST
+ make REQUIRES_RTTI=1
}
package_llvm() {
@@ -143,7 +135,7 @@ package_clang() {
url="http://clang.llvm.org/"
# It looks like clang still needs GCC to assemble and link object files
# See http://old.nabble.com/%22clang--v%22-shows-a-GCC-call-td28378453.html
- depends=("llvm=$pkgver-$pkgrel" 'gcc=4.6.0')
+ depends=("llvm=$pkgver-$pkgrel" "gcc=$_gcc_ver")
# Fix installation path for clang docs
sed -i 's:$(PROJ_prefix)/share/doc/llvm:$(PROJ_prefix)/share/doc/clang:' \
diff --git a/community-testing/llvm/cindexer-clang-path.patch b/community-testing/llvm/cindexer-clang-path.patch
new file mode 100644
index 000000000..ddaab690e
--- /dev/null
+++ b/community-testing/llvm/cindexer-clang-path.patch
@@ -0,0 +1,10 @@
+--- tools/libclang/CIndexer.cpp.orig 2011-04-07 13:08:24.000000000 +0300
++++ tools/libclang/CIndexer.cpp 2011-04-07 13:11:52.224884642 +0300
+@@ -80,6 +80,7 @@ std::string CIndexer::getClangResourcesP
+
+ // We now have the CIndex directory, locate clang relative to it.
+ LibClangPath.eraseComponent();
++ LibClangPath.eraseComponent();
+ #endif
+
+ LibClangPath.appendComponent("clang");
diff --git a/community-testing/llvm/clang-toolchains-gcc-versions.patch b/community-testing/llvm/clang-toolchains-gcc-versions.patch
new file mode 100644
index 000000000..2e527300d
--- /dev/null
+++ b/community-testing/llvm/clang-toolchains-gcc-versions.patch
@@ -0,0 +1,12 @@
+diff -upr clang-2.9.orig/lib/Driver/ToolChains.cpp clang-2.9/lib/Driver/ToolChains.cpp
+--- clang-2.9.orig/lib/Driver/ToolChains.cpp 2011-03-21 23:29:27.000000000 +0200
++++ clang-2.9/lib/Driver/ToolChains.cpp 2011-04-08 00:03:34.000000000 +0300
+@@ -1449,7 +1449,7 @@ Linux::Linux(const HostInfo &Host, const
+ GccTriple = "i586-suse-linux";
+ }
+
+- const char* GccVersions[] = {"4.5.2", "4.5.1", "4.5", "4.4.5", "4.4.4",
++ const char* GccVersions[] = {"4.6.0", "4.5.2", "4.5.1", "4.5", "4.4.5", "4.4.4",
+ "4.4.3", "4.4", "4.3.4", "4.3.3", "4.3.2",
+ "4.3", "4.2.4", "4.2.3", "4.2.2", "4.2.1",
+ "4.2"};