[gentoo-commits] repo/gentoo:master commit in: dev-util/include-what-you-use/, dev-util/include-what-you-use/files/

2023-04-29 Thread Florian Schmaus
commit: 9c479450dfc4080bb682ac6803107efe2422b81c
Author: Florian Schmaus  gentoo  org>
AuthorDate: Sat Apr 29 19:09:44 2023 +
Commit: Florian Schmaus  gentoo  org>
CommitDate: Sat Apr 29 19:16:34 2023 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9c479450

dev-util/include-what-you-use: fix tests

1. invoke run_iwyu_tests with "-- ${BUILD_DIR}/bin/${PN}", so that the
just build iwyu is used and not the one potentially available in PATH

2. Fix include path, see
https://github.com/include-what-you-use/include-what-you-use/pull/1252

3. Drop stddef from badinc.cc. This makes the test pass. I am not sure
if this is correct or not, but at the moment it was either this or
dropping the test entirely.

Closes: https://bugs.gentoo.org/905214
Signed-off-by: Florian Schmaus  gentoo.org>

 dev-util/include-what-you-use/Manifest |  1 +
 ...cxx-badinc.cc-remove-stddef-from-expected.patch | 34 ++
 .../include-what-you-use-0.19.ebuild   | 21 +++--
 3 files changed, 54 insertions(+), 2 deletions(-)

diff --git a/dev-util/include-what-you-use/Manifest 
b/dev-util/include-what-you-use/Manifest
index f5981ea17c80..70e10aaf4ba5 100644
--- a/dev-util/include-what-you-use/Manifest
+++ b/dev-util/include-what-you-use/Manifest
@@ -1 +1,2 @@
+DIST include-what-you-use-0.19-test-util-support-EXTRA_IWYU_ARGS.patch 2314 
BLAKE2B 
d6c99aa59b52207ece610f8a8fe52ae967f3e027118c97f665b0a5d21782d85d94658ece1e0ae0e2d86cdcb94a345f072fdbda495caf589b045a8be38bf56f99
 SHA512 
2ecd6afc2de5ff85c8a6609b151d7d1e50a985e5c52db9b298ce21bad94a3bafb7b939fcd3b3cec0b753e83ba9ea256f628fbda16837ee6b3c3f1d2ec664d4d9
 DIST include-what-you-use-0.19.tar.gz 757761 BLAKE2B 
09dfe686db78973059039f878029cda8dea9912127cf7ed9ddc123abe14459e670304fd531760afbebedee8c4992d15add18b75f9b62dc2d9c4b0f4edb8e0a1d
 SHA512 
0847ae898696b51540ab9f5715e69bae67db42409d60205227d543ba6597b12cc2ea5bf68a3315c31f22e7186e05c06a86f5ae5b893c23bfe4cd9ef6f06ccddc

diff --git 
a/dev-util/include-what-you-use/files/include-what-you-use-0.19-tests-cxx-badinc.cc-remove-stddef-from-expected.patch
 
b/dev-util/include-what-you-use/files/include-what-you-use-0.19-tests-cxx-badinc.cc-remove-stddef-from-expected.patch
new file mode 100644
index ..4d63e0c1530a
--- /dev/null
+++ 
b/dev-util/include-what-you-use/files/include-what-you-use-0.19-tests-cxx-badinc.cc-remove-stddef-from-expected.patch
@@ -0,0 +1,34 @@
+From 0c4577fc5796b2824da5629f77bf6bf6bdcd4823 Mon Sep 17 00:00:00 2001
+From: Florian Schmaus 
+Date: Sat, 29 Apr 2023 20:12:00 +0200
+Subject: [PATCH] tests/cxx/badinc.cc: remove stddef from expected output
+
+--- a/tests/cxx/badinc.cc
 b/tests/cxx/badinc.cc
+@@ -1415,7 +1415,6 @@ int main() {
+   typeof(kI1ConstInt) another_const_int = 1;
+   (void)(another_const_int);
+   // This is a C standard macro, but is implemented via a gcc extension too.
+-  // IWYU: offsetof is...*
+   // IWYU: I1_Struct is...*badinc-i1.h
+   (void)(offsetof(I1_Struct, c));
+   // IWYU: kI1ConstInt is...*badinc-i1.h
+@@ -1807,7 +1806,6 @@ int main() {
+ 
+ tests/cxx/badinc.cc should add these lines:
+ #include 
+-#include 
+ #include 
+ #include "tests/cxx/badinc-i1.h"
+ class D2_Class;
+@@ -1836,7 +1834,6 @@ The full include-list for tests/cxx/badinc.cc:
+ #include "tests/cxx/badinc-inl.h"
+ #include   // for isascii
+ #include 
+-#include   // for offsetof
+ #include   // for find
+ #include   // for fstream
+ #include   // for list
+-- 
+2.39.2
+

diff --git a/dev-util/include-what-you-use/include-what-you-use-0.19.ebuild 
b/dev-util/include-what-you-use/include-what-you-use-0.19.ebuild
index 367e7c6d5101..eb3c6a7e4c82 100644
--- a/dev-util/include-what-you-use/include-what-you-use-0.19.ebuild
+++ b/dev-util/include-what-you-use/include-what-you-use-0.19.ebuild
@@ -9,7 +9,11 @@ inherit cmake llvm python-single-r1
 
 DESCRIPTION="Find unused include directives in C/C++ programs"
 HOMEPAGE="https://include-what-you-use.org/;
-SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
+SRC_URI="
+   https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz
+   
https://github.com/include-what-you-use/include-what-you-use/commit/62e5e2e35380e46ccbff2c2ed118f8bb5c01755b.patch
+   -> ${PN}-0.19-test-util-support-EXTRA_IWYU_ARGS.patch
+"
 
 LICENSE="GPL-2"
 SLOT="0"
@@ -26,6 +30,12 @@ DEPEND="${RDEPEND}"
 
 REQUIRED_USE="${PYTHON_REQUIRED_USE}"
 
+PATCHES=(
+   # https://github.com/include-what-you-use/include-what-you-use/pull/1252
+   "${DISTDIR}"/${PN}-0.19-test-util-support-EXTRA_IWYU_ARGS.patch
+   
"${FILESDIR}"/${PN}-0.19-tests-cxx-badinc.cc-remove-stddef-from-expected.patch
+)
+
 llvm_check_deps() {
has_version "sys-devel/clang:${LLVM_SLOT}"
 }
@@ -54,5 +64,12 @@ src_configure() {
 }
 
 src_test() {
-   "${EPYTHON}" run_iwyu_tests.py || die
+   local clang_version=$(best_version sys-devel/clang:${LLVM_MAX_SLOT})
+   

[gentoo-commits] repo/gentoo:master commit in: dev-util/include-what-you-use/, dev-util/include-what-you-use/files/

2016-05-13 Thread Sergei Trofimovich
commit: 0dd81960c5f1ab8cd4115282f534300c6314962b
Author: Sergei Trofimovich  gentoo  org>
AuthorDate: Fri May 13 07:52:00 2016 +
Commit: Sergei Trofimovich  gentoo  org>
CommitDate: Fri May 13 07:52:00 2016 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0dd81960

dev-util/include-what-you-use: drop old

Package-Manager: portage-2.2.28

 dev-util/include-what-you-use/Manifest |   2 -
 ...de-what-you-use-3.3-issue-110-elaboration.patch | 299 -
 .../include-what-you-use-3.3-r1.ebuild |  35 ---
 .../include-what-you-use-3.4.ebuild|  34 ---
 4 files changed, 370 deletions(-)

diff --git a/dev-util/include-what-you-use/Manifest 
b/dev-util/include-what-you-use/Manifest
index 0c260f7..21c7c79 100644
--- a/dev-util/include-what-you-use/Manifest
+++ b/dev-util/include-what-you-use/Manifest
@@ -1,5 +1,3 @@
-DIST include-what-you-use-3.3.tar.gz 287279 SHA256 
4aa3a4b1f9450c731c9cb125db6906d2b6bce093297dd1811bdc191c35a443be SHA512 
70d7052a0cd5d82fc9d8fcec2fa222f38a02517ad1f6aa6bcff1b9a5170372dd090aebe3989746727ec883a21bf44c5d5602ebe0f8a021cfc2124fb81a14a238
 WHIRLPOOL 
04fbc8bef3b176327f88eb5edae8a14a046803b06a7782c548690e222b00c9f3e8aace71395bbc41ed5b928e60fe2531bbcb9650655386dc5499da14e746f255
-DIST include-what-you-use-3.4.src.tar.gz 291851 SHA256 
73cf2c715c8604c4e832d0a63773210a2cd396988c970ddcbe8fe35bc026d0a4 SHA512 
bf02abeb3df27d319db8c6ff7d8319f9cfb301206c77378f8a18d2be7b82ecc6179a034eeb52c18cade6d98288abaf9efc534c221fb2ab93730567c41e77ad11
 WHIRLPOOL 
5e39837909ac36bfc45868723f93593c0366020d3f4f6de3f0258497ad01184e6ae17e9aa8bace1d2b27b77c4351856adf9f07eb9a6ec2d39d23bf9672f30e39
 DIST include-what-you-use-3.5.src.tar.gz 302759 SHA256 
bc8475fc853a4b60941eb30ea31c62d096e131e359ac69a5d6a2a237393ad4f1 SHA512 
5e5c310dbb673eab7c5e2234fa6a35eebdb208b6b779fcd38503e15617a7a6bea6d6dce081c4620f7ec5895628ed037a091e8917d28538c2fe936d848459ea53
 WHIRLPOOL 
452ae42b39a4fffbb462bc9e33244bf2dca1e0b8676b015fb08f350ec9249f15aadc706e3dcd62e12b511c2daf96fdbcd2aa97145f64a7d183be2428111af5a1
 DIST include-what-you-use-3.6.src.tar.gz 308678 SHA256 
0571fe55c0af5d38bfd5e71d8d4743f09f2d404e3725a027b20665b7f983fca6 SHA512 
3d8c80e6f60f24774cb7b6fae53f4fac2ef368737a1cd8646c3b80029b2b1d0e439aa4185935759dc37e2b9a3ee06e79af8b262af8bbfd38597d8c509942356b
 WHIRLPOOL 
c886169f7bb1bc1ff8f89e25452558607f1ad9cff5b45bbf5e9a0ee129695a2741baa2c144d1198a488fa0455b055722db4404f8b0e843100891aa19fd2abe58
 DIST include-what-you-use-3.7.src.tar.gz 404081 SHA256 
ef2b6a62bf82455148bbe2a711245a7fd3ee36a9b8ab431d50d683fd6346e538 SHA512 
805395873b59e4f4236853ba9ac6818d60968190ad485d580ea80d69c518eb8c44822a4281a4219b4ccc02e2dc8f3db5c470170e27e67ea0d8e04ef78da9078c
 WHIRLPOOL 
d83d26afb1ffed8652b2c15b38fc5546f1302999009778d7e116abfe2ee574206fcded09712f26fd6d0f1d509a0a1cfa40ae37bd3d18e1c5b63a2ce457f23336

diff --git 
a/dev-util/include-what-you-use/files/include-what-you-use-3.3-issue-110-elaboration.patch
 
b/dev-util/include-what-you-use/files/include-what-you-use-3.3-issue-110-elaboration.patch
deleted file mode 100644
index 70a2a5d..000
--- 
a/dev-util/include-what-you-use/files/include-what-you-use-3.3-issue-110-elaboration.patch
+++ /dev/null
@@ -1,299 +0,0 @@
-Upstream-bug: 
http://code.google.com/p/include-what-you-use/issues/detail?id=110
-Index: tests/elaboration-struct.h
-===
 tests/elaboration-struct.h (revision 0)
-+++ tests/elaboration-struct.h (revision 0)
-@@ -0,0 +1,10 @@
-+//===--- elaboration-struct.h - test input file for iwyu 
--===//
-+//
-+// The LLVM Compiler Infrastructure
-+//
-+// This file is distributed under the University of Illinois Open Source
-+// License. See LICENSE.TXT for details.
-+//
-+//===--===//
-+
-+struct ElaborationStruct {};
-
-Property changes on: tests\elaboration-struct.h
-___
-Added: svn:eol-style
-   + native
-
-Index: tests/elaboration.cc
-===
 tests/elaboration.cc   (revision 0)
-+++ tests/elaboration.cc   (revision 0)
-@@ -0,0 +1,79 @@
-+//===--- elaboration.cc - test input file for iwyu 
===//
-+//
-+// The LLVM Compiler Infrastructure
-+//
-+// This file is distributed under the University of Illinois Open Source
-+// License. See LICENSE.TXT for details.
-+//
-+//===--===//
-+
-+// Test that elaborated types are handled correctly.
-+//
-+// An elaborated type is a type prefixed by type kind, e.g. 'class Foo',
-+// 'struct Bar' or 'enum Baz'.
-+//
-+// Clang considers namespace-qualified types elaborated as well, even if they
-+// lack actual elaboration, e.g. 'ns::Foo'.
-+
-+