mirror of
https://abf.rosa.ru/djam/llvm.git
synced 2025-02-23 16:22:50 +00:00
commit
8acdd7baeb
5 changed files with 65 additions and 133 deletions
10
.abf.yml
10
.abf.yml
|
@ -1,6 +1,6 @@
|
|||
sources:
|
||||
cfe-3.9.0.src.tar.xz: 00d49ee82451130a8e1e7b1d56cffa37b783bcb2
|
||||
clang-tools-extra-3.9.0.src.tar.xz: 396ad1af7a8d3cff015a644e595f35553a7548c4
|
||||
compiler-rt-3.9.0.src.tar.xz: a306d576e84b7ee048ebb0ae5ca72e6ec9e1c549
|
||||
llvm-3.9.0.src.tar.xz: da792f11a208d5b994c4fe1c8faa20f90ff0e4a3
|
||||
polly-3.9.0.src.tar.xz: 9d5809bd413b05de18480b69fcf6dbe8d3b1f9ac
|
||||
cfe-6.0.1.src.tar.xz: d93d8f3e3d7eb549ac58507383f7fcbdd78804d7
|
||||
clang-tools-extra-6.0.1.src.tar.xz: 0e4077e46dba66f9db17eb55b1e913b44cb19fd3
|
||||
compiler-rt-6.0.1.src.tar.xz: 4a61bd09f31d3079e921205bb93fb7d05a95946b
|
||||
llvm-6.0.1.src.tar.xz: 09a6316c5225cab255ba12391e7abe5ff4d28935
|
||||
polly-6.0.1.src.tar.xz: ace57e113a26c1244cf28c79012ff5e3f73ff076
|
||||
|
|
12
cfe-6.0.0-i586-unknown-linux-gnu.patch
Normal file
12
cfe-6.0.0-i586-unknown-linux-gnu.patch
Normal file
|
@ -0,0 +1,12 @@
|
|||
diff -Naur cfe-6.0.0.src-orig/lib/Driver/ToolChains/Gnu.cpp cfe-6.0.0.src/lib/Driver/ToolChains/Gnu.cpp
|
||||
--- cfe-6.0.0.src-orig/lib/Driver/ToolChains/Gnu.cpp 2017-12-09 03:34:01.000000000 +0300
|
||||
+++ cfe-6.0.0.src/lib/Driver/ToolChains/Gnu.cpp 2018-04-13 13:47:48.199744983 +0300
|
||||
@@ -1743,7 +1743,7 @@
|
||||
"i386-linux-gnu", "i386-redhat-linux6E", "i686-redhat-linux",
|
||||
"i586-redhat-linux", "i386-redhat-linux", "i586-suse-linux",
|
||||
"i486-slackware-linux", "i686-montavista-linux", "i686-linux-android",
|
||||
- "i586-linux-gnu"};
|
||||
+ "i586-linux-gnu", "i586-unknown-linux-gnu"};
|
||||
|
||||
static const char *const MIPSLibDirs[] = {"/lib"};
|
||||
static const char *const MIPSTriples[] = {"mips-linux-gnu", "mips-mti-linux",
|
|
@ -1,73 +0,0 @@
|
|||
--- llvm-3.5/tools/clang/lib/Driver/Driver.cpp.gcc49~ 2014-08-22 22:54:39.000000000 +0200
|
||||
+++ llvm-3.5/tools/clang/lib/Driver/Driver.cpp 2014-08-25 22:24:57.688608644 +0200
|
||||
@@ -910,7 +910,7 @@
|
||||
// If we want to return a more correct answer some day, then we should
|
||||
// introduce a non-pedantically GCC compatible mode to Clang in which we
|
||||
// provide sensible definitions for -dumpversion, __VERSION__, etc.
|
||||
- llvm::outs() << "4.2.1\n";
|
||||
+ llvm::outs() << "4.9.1\n";
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
--- llvm-3.5/tools/clang/lib/Frontend/InitPreprocessor.cpp.gcc49~ 2014-08-22 22:54:39.000000000 +0200
|
||||
+++ llvm-3.5/tools/clang/lib/Frontend/InitPreprocessor.cpp 2014-08-25 22:24:57.689608632 +0200
|
||||
@@ -522,9 +522,9 @@
|
||||
#undef TOSTR
|
||||
#undef TOSTR2
|
||||
if (!LangOpts.MSVCCompat) {
|
||||
- // Currently claim to be compatible with GCC 4.2.1-5621, but only if we're
|
||||
+ // Currently claim to be compatible with GCC 4.9.1, but only if we're
|
||||
// not compiling for MSVC compatibility
|
||||
- Builder.defineMacro("__GNUC_MINOR__", "2");
|
||||
+ Builder.defineMacro("__GNUC_MINOR__", "9");
|
||||
Builder.defineMacro("__GNUC_PATCHLEVEL__", "1");
|
||||
Builder.defineMacro("__GNUC__", "4");
|
||||
Builder.defineMacro("__GXX_ABI_VERSION", "1002");
|
||||
@@ -542,9 +542,9 @@
|
||||
Builder.defineMacro("__PRAGMA_REDEFINE_EXTNAME", "1");
|
||||
|
||||
// As sad as it is, enough software depends on the __VERSION__ for version
|
||||
- // checks that it is necessary to report 4.2.1 (the base GCC version we claim
|
||||
+ // checks that it is necessary to report 4.9.1 (the base GCC version we claim
|
||||
// compatibility with) first.
|
||||
- Builder.defineMacro("__VERSION__", "\"4.2.1 Compatible " +
|
||||
+ Builder.defineMacro("__VERSION__", "\"4.9.1 Compatible " +
|
||||
Twine(getClangFullCPPVersion()) + "\"");
|
||||
|
||||
// Initialize language-specific preprocessor defines.
|
||||
|
||||
--- llvm-3.5/tools/clang/test/Driver/immediate-options.c.gcc49~ 2014-08-22 22:54:39.000000000 +0200
|
||||
+++ llvm-3.5/tools/clang/test/Driver/immediate-options.c 2014-08-25 22:24:57.690608619 +0200
|
||||
@@ -7,7 +7,7 @@
|
||||
// HELP-HIDDEN: driver-mode
|
||||
|
||||
// RUN: %clang -dumpversion | FileCheck %s -check-prefix=DUMPVERSION
|
||||
-// DUMPVERSION: 4.2.1
|
||||
+// DUMPVERSION: 4.9.1
|
||||
|
||||
// RUN: %clang -print-search-dirs | FileCheck %s -check-prefix=PRINT-SEARCH-DIRS
|
||||
// PRINT-SEARCH-DIRS: programs: ={{.*}}
|
||||
|
||||
--- llvm-3.5/tools/clang/test/Preprocessor/init.c.gcc49~ 2014-08-25 22:24:57.691608607 +0200
|
||||
+++ llvm-3.5/tools/clang/test/Preprocessor/init.c 2014-08-25 22:25:27.754232772 +0200
|
||||
@@ -7025,7 +7025,7 @@
|
||||
// SPARC:#define __UINT_LEAST8_MAX__ 255
|
||||
// SPARC:#define __UINT_LEAST8_TYPE__ unsigned char
|
||||
// SPARC:#define __USER_LABEL_PREFIX__
|
||||
-// SPARC:#define __VERSION__ "4.2.1 Compatible{{.*}}
|
||||
+// SPARC:#define __VERSION__ "4.9.1 Compatible{{.*}}
|
||||
// SPARC:#define __WCHAR_MAX__ 2147483647
|
||||
// SPARC:#define __WCHAR_TYPE__ int
|
||||
// SPARC:#define __WCHAR_WIDTH__ 32
|
||||
--- llvm-3.6.0.src/include/llvm/Support/Compiler.h.omv~ 2014-10-28 18:09:47.260731249 +0100
|
||||
+++ llvm-3.6.0.src/include/llvm/Support/Compiler.h 2014-10-28 18:09:59.930572854 +0100
|
||||
@@ -288,7 +288,7 @@
|
||||
|
||||
/// \macro LLVM_ASSUME_ALIGNED
|
||||
/// \brief Returns a pointer with an assumed alignment.
|
||||
-#if __has_builtin(__builtin_assume_aligned) || LLVM_GNUC_PREREQ(4, 7, 0)
|
||||
+#if __has_builtin(__builtin_assume_aligned) || (!defined(__clang__) && LLVM_GNUC_PREREQ(4, 7, 0))
|
||||
# define LLVM_ASSUME_ALIGNED(p, a) __builtin_assume_aligned(p, a)
|
||||
#elif defined(LLVM_BUILTIN_UNREACHABLE)
|
||||
// As of today, clang does not support __builtin_assume_aligned.
|
|
@ -1,2 +1,5 @@
|
|||
addFilter("E: hardcoded-library-path")
|
||||
addFilter("E: incoherent-version-in-name")
|
||||
# 202 warnings
|
||||
addFilter("W: devel-file-in-non-devel-package")
|
||||
addFilter("W: invalid-license")
|
||||
|
|
100
llvm.spec
100
llvm.spec
|
@ -11,13 +11,24 @@
|
|||
|
||||
%bcond_without clang
|
||||
|
||||
%define major_ver 3.9
|
||||
%define minor_ver 0
|
||||
%define maj_ver 6
|
||||
%define major_ver %{maj_ver}.0
|
||||
%define minor_ver 1
|
||||
|
||||
%define major %{major_ver}
|
||||
%define lto_major %{maj_ver}
|
||||
%define libname %mklibname %{name} %{major}
|
||||
%define liblto %mklibname lto %{lto_major}
|
||||
%define devname %mklibname %{name} -d
|
||||
|
||||
%define clang_major %{major_ver}
|
||||
%define libclang %mklibname clang %{clang_major}
|
||||
%define devclang %mklibname clang -d
|
||||
|
||||
Summary: Low Level Virtual Machine (LLVM)
|
||||
Name: llvm
|
||||
Version: %{major_ver}.%{minor_ver}
|
||||
Release: 4
|
||||
Release: 1
|
||||
License: NCSA
|
||||
Group: Development/Other
|
||||
Url: http://llvm.org/
|
||||
|
@ -31,11 +42,9 @@ Source1000: llvm.rpmlintrc
|
|||
|
||||
# Adjust the search paths to match the OS, adjust the default compiler flags
|
||||
# as well.
|
||||
Patch1: clang-rosa.patch
|
||||
# Claim compatibility with gcc 4.9.1 rather than 4.2.1, it's
|
||||
# much much closer in terms of standards supported etc.
|
||||
Patch7: clang-gcc-compat.patch
|
||||
|
||||
#Patch1: clang-rosa.patch
|
||||
#
|
||||
Patch2: cfe-6.0.0-i586-unknown-linux-gnu.patch
|
||||
|
||||
BuildRequires: cmake
|
||||
BuildRequires: bison
|
||||
|
@ -49,8 +58,6 @@ BuildRequires: sed
|
|||
BuildRequires: tcl
|
||||
BuildRequires: zip
|
||||
BuildRequires: libstdc++-devel
|
||||
#BuildRequires: pkgconfig(cloog-isl)
|
||||
#BuildRequires: pkgconfig(isl) >= 0.13
|
||||
BuildRequires: pkgconfig(libffi)
|
||||
BuildRequires: pkgconfig(libtirpc)
|
||||
%if %{compile_apidox}
|
||||
|
@ -71,36 +78,9 @@ for effective implementation, proper tail calls or garbage collection.
|
|||
%{_bindir}/bugpoint
|
||||
%{_bindir}/llc
|
||||
%{_bindir}/lli
|
||||
%{_bindir}/llvm*
|
||||
%exclude %{_bindir}/llvm-config
|
||||
%{_bindir}/opt
|
||||
%{_bindir}/llvm-ar
|
||||
%{_bindir}/llvm-as
|
||||
%{_bindir}/llvm-bcanalyzer
|
||||
%{_bindir}/llvm-diff
|
||||
%{_bindir}/llvm-dis
|
||||
%{_bindir}/llvm-extract
|
||||
%{_bindir}/llvm-link
|
||||
%{_bindir}/llvm-mc
|
||||
%{_bindir}/llvm-nm
|
||||
%{_bindir}/llvm-objdump
|
||||
%{_bindir}/llvm-ranlib
|
||||
%{_bindir}/llvm-readobj
|
||||
%{_bindir}/llvm-cov
|
||||
%{_bindir}/llvm-dwarfdump
|
||||
%{_bindir}/llvm-mcmarkup
|
||||
%{_bindir}/llvm-profdata
|
||||
%{_bindir}/llvm-rtdyld
|
||||
%{_bindir}/llvm-size
|
||||
%{_bindir}/llvm-stress
|
||||
%{_bindir}/llvm-symbolizer
|
||||
%{_bindir}/llvm-tblgen
|
||||
%{_bindir}/llvm-cxxdump
|
||||
%{_bindir}/llvm-dsymutil
|
||||
%{_bindir}/llvm-pdbdump
|
||||
%{_bindir}/llvm-c-test
|
||||
%{_bindir}/llvm-dwp
|
||||
%{_bindir}/llvm-lib
|
||||
%{_bindir}/llvm-lto
|
||||
%{_bindir}/llvm-split
|
||||
%{_bindir}/modularize
|
||||
%{_bindir}/sancov
|
||||
%{_bindir}/verify-uselistorder
|
||||
|
@ -108,6 +88,7 @@ for effective implementation, proper tail calls or garbage collection.
|
|||
%{_bindir}/yaml2obj
|
||||
%{_bindir}/find-all-symbols
|
||||
%{_bindir}/sanstats
|
||||
%{_datadir}/opt-viewer
|
||||
|
||||
#----------------------------------------------------------------------------
|
||||
|
||||
|
@ -125,15 +106,11 @@ LLVM plugins.
|
|||
|
||||
%files -n %{plugins}
|
||||
%{_libdir}/BugpointPasses.so
|
||||
%{_libdir}/libLTO.so
|
||||
%{_libdir}/LLVMgold.so
|
||||
%{_libdir}/LLVMHello.so
|
||||
|
||||
#----------------------------------------------------------------------------
|
||||
|
||||
%define major %{major_ver}
|
||||
%define libname %mklibname %{name} %{major}
|
||||
|
||||
%package -n %{libname}
|
||||
Summary: LLVM shared libraries
|
||||
Group: System/Libraries
|
||||
|
@ -150,13 +127,25 @@ programs that are dynamically linked against libLLVM.
|
|||
|
||||
#----------------------------------------------------------------------------
|
||||
|
||||
%define devname %mklibname -d %{name}
|
||||
%package -n %{liblto}
|
||||
Summary: LLVM shared library
|
||||
Group: System/Libraries
|
||||
Conflicts: %{_lib}llvm-plugins < 6.0.0-3
|
||||
|
||||
%description -n %{liblto}
|
||||
Shared library for the LLVM compiler infrastructure.
|
||||
|
||||
%files -n %{liblto}
|
||||
%{_libdir}/libLTO.so.%{lto_major}*
|
||||
|
||||
#----------------------------------------------------------------------------
|
||||
|
||||
%package -n %{devname}
|
||||
Summary: Development files for LLVM
|
||||
Group: Development/Other
|
||||
Provides: llvm-devel = %{EVRD}
|
||||
Requires: %{libname} = %{EVRD}
|
||||
Requires: %{liblto} = %{EVRD}
|
||||
Requires: %{name} = %{EVRD}
|
||||
Requires: llvm-polly = %{EVRD}
|
||||
|
||||
|
@ -165,6 +154,7 @@ Provides: llvm-polly-devel = %{EVRD}
|
|||
|
||||
Conflicts: llvm < 3.0-7
|
||||
Conflicts: %{_lib}llvm3.0 < 3.0-9
|
||||
Conflicts: %{_lib}llvm-plugins < 6.0.0-3
|
||||
|
||||
%description -n %{devname}
|
||||
This package contains the development files for LLVM.
|
||||
|
@ -173,8 +163,10 @@ This package contains the development files for LLVM.
|
|||
%{_bindir}/%{name}-config
|
||||
%{_libdir}/libLLVM.so
|
||||
%{_libdir}/libLLVM*.a
|
||||
%{_libdir}/libLTO.so
|
||||
%{_libdir}/libfindAllSymbols.a
|
||||
%{_libdir}/cmake/%{name}/*
|
||||
%{_libdir}/cmake/polly/*.cmake
|
||||
%{_includedir}/%{name}
|
||||
%{_includedir}/%{name}-c
|
||||
%{_includedir}/polly
|
||||
|
@ -193,7 +185,6 @@ Documentation for the LLVM compiler infrastructure.
|
|||
|
||||
%files doc
|
||||
%doc README.txt
|
||||
%doc docs/*.html
|
||||
%doc docs/tutorial
|
||||
%doc examples
|
||||
%if %{compile_apidox}
|
||||
|
@ -227,7 +218,7 @@ short vector instructions as well as dedicated accelerators.
|
|||
#----------------------------------------------------------------------------
|
||||
|
||||
%if %{with clang}
|
||||
# TODO: %{_bindir}/clang is linked against static libclang.a, could it be
|
||||
# TODO: %%{_bindir}/clang is linked against static libclang.a, could it be
|
||||
# linked against libclang.so instead, like llvm-* are against livLLVM.so?
|
||||
|
||||
%package -n clang
|
||||
|
@ -262,14 +253,15 @@ as libraries and designed to be loosely-coupled and extensible.
|
|||
%{_datadir}/clang/run-clang-tidy.py
|
||||
%{_datadir}/clang/clang-include-fixer.py
|
||||
%{_datadir}/clang/run-find-all-symbols.py
|
||||
%{_datadir}/clang/bash-autocomplete.sh
|
||||
%{_datadir}/clang/clang-include-fixer.el
|
||||
%{_datadir}/clang/clang-rename.el
|
||||
%{_datadir}/clang/clang-rename.py
|
||||
%endif
|
||||
|
||||
#----------------------------------------------------------------------------
|
||||
|
||||
%if %{with clang}
|
||||
%define clang_major %{major_ver}
|
||||
%define libclang %mklibname clang %{clang_major}
|
||||
|
||||
%package -n %{libclang}
|
||||
Summary: Shared library for clang
|
||||
Group: System/Libraries
|
||||
|
@ -280,6 +272,7 @@ programs that are dynamically linked against libclang.
|
|||
|
||||
%files -n %{libclang}
|
||||
%{_libdir}/libclang.so.%{clang_major}
|
||||
%{_libdir}/libclang.so.%{maj_ver}
|
||||
%{_libdir}/libclang-%{clang_major}.so
|
||||
%{_libdir}/libclang-%{clang_major}.%{minor_ver}.so
|
||||
%endif
|
||||
|
@ -287,8 +280,6 @@ programs that are dynamically linked against libclang.
|
|||
#----------------------------------------------------------------------------
|
||||
|
||||
%if %{with clang}
|
||||
%define devclang %mklibname -d clang
|
||||
|
||||
%package -n %{devclang}
|
||||
Summary: Development files for clang
|
||||
Group: Development/Other
|
||||
|
@ -351,10 +342,10 @@ mv polly-%{version}.src tools/polly
|
|||
mv clang-tools-extra-%{version}.src tools/clang/tools/extra
|
||||
mv compiler-rt-%{version}.src projects/compiler-rt
|
||||
cd tools/clang
|
||||
%patch1 -p1 -b .rosa~
|
||||
#%patch1 -p1 -b .rosa~
|
||||
%patch2 -p1 -b .gnu~
|
||||
cd -
|
||||
%endif
|
||||
%patch7 -p1 -b .gcc49~
|
||||
|
||||
|
||||
%build
|
||||
|
@ -408,8 +399,7 @@ done
|
|||
-DWITH_POLLY:BOOL=ON \
|
||||
-DLINK_POLLY_INTO_TOOLS:BOOL=ON
|
||||
|
||||
|
||||
%make
|
||||
%make -s
|
||||
|
||||
%install
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue