From a4e2a46beb5e4858ef27bdedbb0ff6d2ced430ad Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Sat, 28 Apr 2018 20:02:04 +0100 Subject: gentoo resync : 28.04.2018 --- dev-cpp/catch/Manifest | 7 ++-- dev-cpp/catch/catch-2.2.0.ebuild | 37 ---------------- dev-cpp/catch/catch-2.2.2.ebuild | 49 ++++++++++++++++++++++ .../catch/files/catch-2.2.0-fix-pkg-config.patch | 22 ---------- .../catch/files/catch-2.2.2-python-automagic.patch | 25 +++++++++++ dev-cpp/catch/files/catch-2.2.2-test-python3.patch | 44 +++++++++++++++++++ 6 files changed, 122 insertions(+), 62 deletions(-) delete mode 100644 dev-cpp/catch/catch-2.2.0.ebuild create mode 100644 dev-cpp/catch/catch-2.2.2.ebuild delete mode 100644 dev-cpp/catch/files/catch-2.2.0-fix-pkg-config.patch create mode 100644 dev-cpp/catch/files/catch-2.2.2-python-automagic.patch create mode 100644 dev-cpp/catch/files/catch-2.2.2-test-python3.patch (limited to 'dev-cpp/catch') diff --git a/dev-cpp/catch/Manifest b/dev-cpp/catch/Manifest index 78fa8a43b9d8..10f18b533007 100644 --- a/dev-cpp/catch/Manifest +++ b/dev-cpp/catch/Manifest @@ -1,10 +1,11 @@ -AUX catch-2.2.0-fix-pkg-config.patch 703 BLAKE2B 538ae153edbb8d6ef13c15ba89e9ab35cf71f654fc01c3999235a74ee59fb6d6a2372c18340c2c5e42dfc8f3801b989409f162527559c5ebfc7a9b4e398a894f SHA512 631bedca0eecc96002fc07064b0c1fa6d47ffa4d9235b123e9effb7f7e1355e5bd38e58982b2788b3515487d0cea10bc191be5aef0fb3b54ba1757fdc5725888 +AUX catch-2.2.2-python-automagic.patch 1096 BLAKE2B c1c5ae6cc0fa4f8066255581ab29bed966f4051eea79941c0a0f3e51f3639894b216dcc229de2ca932f0e41b8c3277f687d5d4dd2d226a2872f58ea486b9315f SHA512 d6b7198f60e45a52a40496eeecc1b34f5394af5dcccbaa7b2afa3af674d83f05a258311f151147ee8fcacae7764c4d742a92591c910a7beedfba5c71f547dfdc +AUX catch-2.2.2-test-python3.patch 1521 BLAKE2B 6329f5d4995216e685c3404ef99fea1deed0be3e5f4849e7b24448b7a6c3d2aab47442a29dadbf0684888360c4a5a2e09667d765182a8a5f9245e64c7723cb34 SHA512 ca4ba7bfd87edcd06775d4d3fc7f19eb7188f95c73f4f26a08ddddd63a86249e2f4e3380b6a7cf449f1d6a32a6181557d5f82af6f79ca0c315b72fa9f7198166 DIST Catch-1.11.0.tar.gz 376132 BLAKE2B 23a1a6292dd91ec1c71923b4902b42b59ff6be5227b666f68ef0dc33756a58a63edd70a9b139dda0b1860c2b7a0cfec7ab9262e6447eff3184cfe28ea9b0aa77 SHA512 33085c2671f78c7562eace909564b2730eabcaf4490cd463402e66ab4ac2be1fe4fe360916c11aa589ba4a010622444126ee2ae747783b5869b5d7276361f132 DIST Catch2-2.1.1.tar.gz 481236 BLAKE2B 8a8110611aaf4ea913462884d8293bcae7d0abf3075253a26385a56b2cb5bf50b769e2117430c9712e4644f430cc16461fabfef921c5fbfceb82effb0da74e93 SHA512 64947672e614301a45efd812eb3eef98d871c9719005a441b6f6bb1dc26820bd9643ba285bcc0eaef9b212c5ab6ada4a875433c47a020ce436bcc411cdc8ad72 -DIST Catch2-2.2.0.tar.gz 487585 BLAKE2B 2d8f58e8d3630cb30e438da7a169df3afff387d38dd3054cfcdb8860aa507ecc3c614471fa1110f64b0dba3d6855edfc68ee4e0b7eb97164be833827078e82fd SHA512 9dcc409939df61f84b965ee3147a7a7578b3a816ff285e103b7666115bf38a608d9a0075e06e98f93b9f06882d2e41d6c51cdaae352abbfaa2a3c1b408f22df7 +DIST Catch2-2.2.2.tar.gz 497244 BLAKE2B d5073d56b9399bd7f50bafc7758e60e31ba4434e229f92ca92cd04257f4a54cec925ad3180cc964c4f69edbaa7fc14f8af8e828421e2bb2b4f6c59eaea5cc06d SHA512 ab91036c6c3ace087d0382ce99f26b2c30a4b75d52f285619ca282a618470fe388afe47495f3b2764268d600c6834c60ba464483d06f3a1c4316c099477c8e38 EBUILD catch-1.11.0.ebuild 725 BLAKE2B 49c5034310812a931d9155d0aa3d791c30ab1f381c14bf102a26e23cd7c24ca97c4d4b7b11c8c859e665fdbd7beea44416e193ec06ad1d8e883f7459023ce3d6 SHA512 e7fa7e70cb02ab499606e656650d4ddb0c11c4990c720457dc0e21ebcee4a44e67356dfc89d3bdd0caf5e943fb5b59b5fa4ff9f2bd1963b6db20f362c1725560 EBUILD catch-1.9999.ebuild 558 BLAKE2B bafe5cb18017202bd684d631b8839caab6bb128d8fc42d7772dd74aa91dcd99b139393fa22463536924da114fc508a92d5b49639590933397a57cab9f2159ac0 SHA512 1952c96b2fa49e674a32466f2ec709b2f92c8e2502eecb1f25c24d81d11c73e8c28cfbb1da5b7e322bbebd28d6ade06f6b157e07f47f1a06ad258c30efc118f0 EBUILD catch-2.1.1.ebuild 789 BLAKE2B 1eefb971644a62d137bd3af77bd3155fe82382f1520e5da503ad80bb4ace697ce461f5d3c6311ac0b241224f6df603b87ec00f5c9225d8d6bb6c7a6ecf9bb303 SHA512 930839ea809a06dcb8f66ade29cf3e5b109327ceaef66da33c55fc958974b2489bfb003238b560189868bc08246ca4ddb7b5f239ff0b804973c6fab50ab4b4b0 -EBUILD catch-2.2.0.ebuild 849 BLAKE2B 9a60b16e90754ccc4b815ab2b1b077c694dc8ab17effe63197f7721dfc0e9de2f6080a80960201d3ec66500bb331f3d9b293ae3497e7113ada6937a78672ba31 SHA512 046bf2c8d913595a3d6fe66d5a0f32d0772a6a221f112eda1a4b981a9a0972f6b24100102d5207704643bd6c5c20456ce0e09f2c540d6f6b177fd8291a832bd7 +EBUILD catch-2.2.2.ebuild 1078 BLAKE2B 5c33d53d303e552418f2957e8c1c9f640fb03b356bb3e4f6d2988c2fc98225d1bc6a50621a1285d5ab0d255cd1a00b5916788de16527c3f7f436bdf9d4ba3f28 SHA512 3912a227443c1eff86b65831ea3f5c2703811c0978c8750e5b69c75cca0079d1ecc31d2c643aad6a02a2b210da061f111097db390e9be00fab807d4e54eb5534 EBUILD catch-9999.ebuild 789 BLAKE2B 1eefb971644a62d137bd3af77bd3155fe82382f1520e5da503ad80bb4ace697ce461f5d3c6311ac0b241224f6df603b87ec00f5c9225d8d6bb6c7a6ecf9bb303 SHA512 930839ea809a06dcb8f66ade29cf3e5b109327ceaef66da33c55fc958974b2489bfb003238b560189868bc08246ca4ddb7b5f239ff0b804973c6fab50ab4b4b0 MISC metadata.xml 324 BLAKE2B e32ed47ddce7e517244ff26e70d1bd31cdaa33bef0bf4a6cf4284f3688745760a9538f9bf6d9d25a9fabd3f5f6901a1b91c76d2fe290427a55bcc74d4f17be7b SHA512 094af03b1e2befa015f1faaca9ecf4158fffedfe7ef8a2873e9e6cd6e4e7d26f276e357ac1989c2809702abc3ada590668adc37c9d804cee31ae564f88c3315f diff --git a/dev-cpp/catch/catch-2.2.0.ebuild b/dev-cpp/catch/catch-2.2.0.ebuild deleted file mode 100644 index c9f6247c2842..000000000000 --- a/dev-cpp/catch/catch-2.2.0.ebuild +++ /dev/null @@ -1,37 +0,0 @@ -# Copyright 1999-2018 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 - -EAPI=6 - -: ${CMAKE_MAKEFILE_GENERATOR:=ninja} -inherit cmake-utils - -if [[ ${PV} == *9999 ]]; then - inherit git-r3 - EGIT_REPO_URI="https://github.com/catchorg/Catch2.git" -else - MY_P=${PN^}2-${PV} - SRC_URI="https://github.com/catchorg/Catch2/archive/v${PV}.tar.gz -> ${MY_P}.tar.gz" - KEYWORDS="~amd64 ~x86" - - S=${WORKDIR}/${MY_P} -fi - -DESCRIPTION="Modern C++ header-only framework for unit-tests" -HOMEPAGE="https://github.com/catchorg/Catch2" - -LICENSE="Boost-1.0" -SLOT="0" -IUSE="test" -RESTRICT="!test? ( test )" - -PATCHES=( "${FILESDIR}"/${PN}-2.2.0-fix-pkg-config.patch ) - -src_configure() { - local mycmakeargs=( - -DCATCH_ENABLE_WERROR=OFF - -DBUILD_TESTING=$(usex test) - -DCMAKE_INSTALL_DOCDIR="share/doc/${PF}" - ) - cmake-utils_src_configure -} diff --git a/dev-cpp/catch/catch-2.2.2.ebuild b/dev-cpp/catch/catch-2.2.2.ebuild new file mode 100644 index 000000000000..2cce0298b3a4 --- /dev/null +++ b/dev-cpp/catch/catch-2.2.2.ebuild @@ -0,0 +1,49 @@ +# Copyright 1999-2018 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +PYTHON_COMPAT=( python2_7 python3_{5,6} ) + +: ${CMAKE_MAKEFILE_GENERATOR:=ninja} +inherit cmake-utils python-any-r1 + +if [[ ${PV} == *9999 ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/catchorg/Catch2.git" +else + MY_P=${PN^}2-${PV} + SRC_URI="https://github.com/catchorg/Catch2/archive/v${PV}.tar.gz -> ${MY_P}.tar.gz" + KEYWORDS="~amd64 ~x86" + + S=${WORKDIR}/${MY_P} +fi + +DESCRIPTION="Modern C++ header-only framework for unit-tests" +HOMEPAGE="https://github.com/catchorg/Catch2" + +LICENSE="Boost-1.0" +SLOT="0" +IUSE="test" +RESTRICT="!test? ( test )" + +DEPEND="test? ( ${PYTHON_DEPS} )" + +PATCHES=( + "${FILESDIR}"/${PN}-2.2.2-test-python3.patch + "${FILESDIR}"/${PN}-2.2.2-python-automagic.patch +) + +pkg_setup() { + use test && python-any-r1_pkg_setup +} + +src_configure() { + local mycmakeargs=( + -DCATCH_ENABLE_WERROR=OFF + -DBUILD_TESTING=$(usex test) + -DCMAKE_INSTALL_DOCDIR="share/doc/${PF}" + -DPYTHON_EXECUTABLE="${PYTHON}" + ) + cmake-utils_src_configure +} diff --git a/dev-cpp/catch/files/catch-2.2.0-fix-pkg-config.patch b/dev-cpp/catch/files/catch-2.2.0-fix-pkg-config.patch deleted file mode 100644 index 1c1463921b2b..000000000000 --- a/dev-cpp/catch/files/catch-2.2.0-fix-pkg-config.patch +++ /dev/null @@ -1,22 +0,0 @@ -From c778848b09df073b9f84f22622ea7a632642c4a5 Mon Sep 17 00:00:00 2001 -From: David Seifert -Date: Tue, 30 Jan 2018 11:13:53 +0100 -Subject: [PATCH] Fix pkg-config - -* All uses of Catch involve #include'ing it without - a prefixed folder, such as `#include "catch.hpp"`. - This requires fixing the pkg-config file. ---- - catch.pc.in | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/catch.pc.in b/catch.pc.in -index abd0b66b1..4f48bc7fb 100644 ---- a/catch.pc.in -+++ b/catch.pc.in -@@ -3,4 +3,4 @@ includedir=@CMAKE_INSTALL_FULL_INCLUDEDIR@ - Name: Catch - Description: Testing library for C++ - Version: @Catch2_VERSION@ --Cflags: -I${includedir} -+Cflags: -I${includedir}/catch diff --git a/dev-cpp/catch/files/catch-2.2.2-python-automagic.patch b/dev-cpp/catch/files/catch-2.2.2-python-automagic.patch new file mode 100644 index 000000000000..ecc99905d7f0 --- /dev/null +++ b/dev-cpp/catch/files/catch-2.2.2-python-automagic.patch @@ -0,0 +1,25 @@ +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -308,6 +308,9 @@ + + include(CTest) + ++# Approval tests require python 2.7 or 3 ++find_package(PythonInterp) ++ + if (BUILD_TESTING AND NOT_SUBPROJECT) + add_executable(SelfTest ${TEST_SOURCES} ${IMPL_SOURCES} ${REPORTER_SOURCES} ${SURROGATE_SOURCES} ${HEADERS}) + target_include_directories(SelfTest PRIVATE ${HEADER_DIR}) +@@ -384,7 +387,11 @@ + set_tests_properties(NoTest PROPERTIES PASS_REGULAR_EXPRESSION "No test cases matched") + + # AppVeyor has a Python 2.7 in path, but doesn't have .py files as autorunnable +- add_test(NAME ApprovalTests COMMAND python ${CMAKE_CURRENT_SOURCE_DIR}/scripts/approvalTests.py $) ++ if(NOT ${PYTHONINTERP_FOUND}) ++ message(FATAL_ERROR "Python not found, but required for running tests!") ++ endif() ++ ++ add_test(NAME ApprovalTests COMMAND ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/scripts/approvalTests.py $) + set_tests_properties(ApprovalTests PROPERTIES FAIL_REGULAR_EXPRESSION "Results differed") + + if (CATCH_USE_VALGRIND) diff --git a/dev-cpp/catch/files/catch-2.2.2-test-python3.patch b/dev-cpp/catch/files/catch-2.2.2-test-python3.patch new file mode 100644 index 000000000000..0712f1577077 --- /dev/null +++ b/dev-cpp/catch/files/catch-2.2.2-test-python3.patch @@ -0,0 +1,44 @@ +From dc6b83bec9bdcc149db08711cc9dfd555a8620fa Mon Sep 17 00:00:00 2001 +From: Tom Hughes +Date: Fri, 6 Apr 2018 13:59:08 +0100 +Subject: [PATCH] Support Python3 in approval tests + +--- + scripts/approvalTests.py | 15 +++++++++++---- + 1 file changed, 11 insertions(+), 4 deletions(-) + +diff --git a/scripts/approvalTests.py b/scripts/approvalTests.py +index a2ab5d5a2..16cc7b7d2 100755 +--- a/scripts/approvalTests.py ++++ b/scripts/approvalTests.py +@@ -72,10 +72,17 @@ + + overallResult = 0 + ++def openFile(file, mode): ++ try: ++ return open(file, mode, encoding='utf-8', errors='surrogateescape') ++ except TypeError: ++ import io ++ return io.open(file, mode, encoding='utf-8', errors='surrogateescape') ++ + def diffFiles(fileA, fileB): +- with open(fileA, 'r') as file: ++ with openFile(fileA, 'r') as file: + aLines = [line.rstrip() for line in file.readlines()] +- with open(fileB, 'r') as file: ++ with openFile(fileB, 'r') as file: + bLines = [line.rstrip() for line in file.readlines()] + + shortenedFilenameA = fileA.rsplit(os.sep, 1)[-1] +@@ -139,8 +146,8 @@ def approve(baseName, args): + subprocess.call(args, stdout=f, stderr=f) + f.close() + +- rawFile = open(rawResultsPath, 'r') +- filteredFile = open(filteredResultsPath, 'w') ++ rawFile = openFile(rawResultsPath, 'r') ++ filteredFile = openFile(filteredResultsPath, 'w') + for line in rawFile: + filteredFile.write(filterLine(line).rstrip() + "\n") + filteredFile.close() -- cgit v1.2.3