From c823f68df9e9ee4a5aa408d3aa57662a9c37b0b7 Mon Sep 17 00:00:00 2001 From: Tom Stellard Date: Thu, 6 Sep 2018 20:34:50 +0000 Subject: [PATCH] Drop all uses of python2 from lit tests --- 0001-Don-t-prefer-python2.7.patch | 24 ++++++++++++++++++++++++ clang.spec | 13 +++++++------ 2 files changed, 31 insertions(+), 6 deletions(-) create mode 100644 0001-Don-t-prefer-python2.7.patch diff --git a/0001-Don-t-prefer-python2.7.patch b/0001-Don-t-prefer-python2.7.patch new file mode 100644 index 0000000..28ca4e0 --- /dev/null +++ b/0001-Don-t-prefer-python2.7.patch @@ -0,0 +1,24 @@ +From d13bd5108e3471cc6f6203ba1c0c0e67323bbb12 Mon Sep 17 00:00:00 2001 +From: Tom Stellard +Date: Wed, 5 Sep 2018 21:43:42 -0700 +Subject: [PATCH] Don't prefer python2.7 + +--- + CMakeLists.txt | 1 - + 1 file changed, 1 deletion(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 52b8819..6f233fd 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -109,7 +109,6 @@ if( CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR ) + set( CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib${LLVM_LIBDIR_SUFFIX} ) + + if(LLVM_INCLUDE_TESTS) +- set(Python_ADDITIONAL_VERSIONS 2.7) + include(FindPythonInterp) + if(NOT PYTHONINTERP_FOUND) + message(FATAL_ERROR +-- +1.8.3.1 + diff --git a/clang.spec b/clang.spec index 461c16e..43d8664 100644 --- a/clang.spec +++ b/clang.spec @@ -59,7 +59,7 @@ Name: %pkg_name Version: %{maj_ver}.%{min_ver}.%{patch_ver} -Release: 0.7.rc%{rc_ver}%{?dist} +Release: 0.8.rc%{rc_ver}%{?dist} Summary: A C language family front-end for LLVM License: NCSA @@ -83,6 +83,7 @@ Patch0: 0001-lit.cfg-Add-hack-so-lit-can-find-not-and-FileCheck.patch Patch1: 0001-GCC-compatibility-Ignore-fstack-clash-protection.patch Patch2: 0001-Driver-Prefer-vendor-supplied-gcc-toolchain.patch Patch4: 0001-gtest-reorg.patch +Patch5: 0001-Don-t-prefer-python2.7.patch BuildRequires: gcc BuildRequires: gcc-c++ @@ -111,10 +112,6 @@ BuildRequires: emacs BuildRequires: python3-lit %endif -# make check-clang passes LLVM_EXTERNAL_LIT as an argument to -# /usr/bin/python2, so we must have the python2 version of lit. -# FIXME: We should find a way to not depend on python2-lit. -BuildRequires: python2-lit BuildRequires: python2-rpm-macros BuildRequires: python3-sphinx BuildRequires: libatomic @@ -233,6 +230,7 @@ suite can be run with any compiler, not just clang. %patch1 -p1 -b .fstack-clash-protection %patch2 -p1 -b .vendor-gcc %patch4 -p1 -b .gtest +%patch5 -p1 -b .no-python2 mv ../%{clang_tools_srcdir} tools/extra %endif @@ -263,7 +261,7 @@ cd _build %else -DLLVM_CONFIG:FILEPATH=/usr/bin/llvm-config-%{__isa_bits} \ -DCLANG_INCLUDE_TESTS:BOOL=ON \ - -DLLVM_EXTERNAL_LIT=%{python2_sitelib}/lit/main.py \ + -DLLVM_EXTERNAL_LIT=%{_bindir}/lit \ -DLLVM_MAIN_SRC_DIR=%{_datadir}/llvm/src \ %if 0%{?__isa_bits} == 64 -DLLVM_LIBDIR_SUFFIX=64 \ @@ -429,6 +427,9 @@ false %endif %changelog +* Thu Sep 06 2018 Tom Stellard - 7.0.0-0.8.rc2 +- Drop all uses of python2 from lit tests + * Sat Sep 01 2018 Tom Stellard - 7.0.0-0.7.rc2 - Add Fedora specific version string