--- /dev/null
+--- llvm-3.5.0.src/tools/lldb/lib/Makefile.orig 2014-07-21 19:24:05.000000000 +0200
++++ llvm-3.5.0.src/tools/lldb/lib/Makefile 2014-10-19 22:11:21.104592254 +0200
+@@ -173,7 +173,7 @@
+ # Don't allow unresolved symbols.
+ LLVMLibsOptions += -Wl,--no-undefined
+ # Link in python
+- LLVMLibsOptions += $(PYTHON_BUILD_FLAGS) -lrt -ledit -lncurses -lpanel
++ LLVMLibsOptions += $(PYTHON_BUILD_FLAGS) -lrt -ledit -lncurses -lpanel -latomic
+ LLVMLibsOptions += -Wl,--soname,lib$(LIBRARYNAME)$(SHLIBEXT)
+ endif
+
Patch2: %{name}-pld.patch
Patch3: %{name}-polly-update.patch
Patch4: %{name}-lldb.patch
-Patch5: %{name}-lld-link.patch
+Patch5: %{name}-lldb-atomic.patch
+Patch6: %{name}-lld-link.patch
URL: http://llvm.org/
BuildRequires: autoconf >= 2.60
BuildRequires: automake >= 1:1.9.6
BuildRequires: tcl-devel
%endif
%if %{with lldb}
+%ifarch i386 i486
+BuildRequires: libatomic-devel
+%endif
BuildRequires: libedit-devel
BuildRequires: libxml2-devel >= 2
BuildRequires: ncurses-ext-devel
%patch1 -p1
%patch2 -p1
%{?with_polly:%patch3 -p1}
-%{?with_lldb:%patch4 -p1}
+%if %{with lldb}
+%patch4 -p1
+%ifarch i386 i486
%patch5 -p1
+%endif
+%endif
+%patch6 -p1
# configure does not properly specify libdir
%{__sed} -i 's|(PROJ_prefix)/lib|(PROJ_prefix)/%{_lib}|g' Makefile.config.in