1 |
commit: bd4ac0dc54146264f00d132707fac794340a5e2d |
2 |
Author: Michael Palimaka <kensington <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sun Mar 31 09:49:14 2019 +0000 |
4 |
Commit: Michael Palimaka <kensington <AT> gentoo <DOT> org> |
5 |
CommitDate: Sun Mar 31 09:49:30 2019 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=bd4ac0dc |
7 |
|
8 |
dev-util/clazy: fix build with mismatched clang/llvm versions |
9 |
|
10 |
Closes: https://bugs.gentoo.org/681568 |
11 |
Package-Manager: Portage-2.3.62, Repoman-2.3.12 |
12 |
Signed-off-by: Michael Palimaka <kensington <AT> gentoo.org> |
13 |
|
14 |
dev-util/clazy/clazy-1.5-r1.ebuild | 49 ++++++++++++++++++++++++++++++++++++++ |
15 |
1 file changed, 49 insertions(+) |
16 |
|
17 |
diff --git a/dev-util/clazy/clazy-1.5-r1.ebuild b/dev-util/clazy/clazy-1.5-r1.ebuild |
18 |
new file mode 100644 |
19 |
index 00000000000..47e98ab9709 |
20 |
--- /dev/null |
21 |
+++ b/dev-util/clazy/clazy-1.5-r1.ebuild |
22 |
@@ -0,0 +1,49 @@ |
23 |
+# Copyright 1999-2019 Gentoo Authors |
24 |
+# Distributed under the terms of the GNU General Public License v2 |
25 |
+ |
26 |
+EAPI=7 |
27 |
+ |
28 |
+inherit cmake-utils |
29 |
+ |
30 |
+DESCRIPTION="Compiler plugin which allows clang to understand Qt semantics" |
31 |
+HOMEPAGE="https://cgit.kde.org/clazy.git/tree/README.md" |
32 |
+SRC_URI="mirror://kde/stable/${PN}/${PV}/src/${P}.tar.xz" |
33 |
+ |
34 |
+LICENSE="LGPL-2+" |
35 |
+SLOT="0" |
36 |
+KEYWORDS="~amd64" |
37 |
+IUSE="" |
38 |
+ |
39 |
+RDEPEND=" |
40 |
+ sys-devel/clang:= |
41 |
+ >=sys-devel/llvm-3.8:= |
42 |
+" |
43 |
+DEPEND="${RDEPEND}" |
44 |
+ |
45 |
+DOCS=( README.md ) |
46 |
+ |
47 |
+src_prepare() { |
48 |
+ cmake-utils_src_prepare |
49 |
+ |
50 |
+ sed -e '/install(FILES README.md COPYING-LGPL2.txt checks.json DESTINATION/d' \ |
51 |
+ -i CMakeLists.txt || die |
52 |
+ |
53 |
+ sed -e 's|${MAN_INSTALL_DIR}|share/man/man1|' \ |
54 |
+ -i docs/man/CMakeLists.txt || die |
55 |
+} |
56 |
+ |
57 |
+src_configure() { |
58 |
+ # this package requires both llvm and clang of the same version. |
59 |
+ # clang pulls in the equivalent llvm version, but not vice versa. |
60 |
+ # so, we must find llvm based on the installed clang version. |
61 |
+ # bug #681568 |
62 |
+ local clang_version=$(best_version sys-devel/clang) |
63 |
+ export LLVM_ROOT="/usr/lib/llvm/$(ver_cut 1 ${clang_version##sys-devel/clang-})s" |
64 |
+ cmake-utils_src_configure |
65 |
+} |
66 |
+ |
67 |
+src_install() { |
68 |
+ cmake-utils_src_install |
69 |
+ mv "${D}"/usr/share/doc/clazy/* "${D}"/usr/share/doc/${PF} || die |
70 |
+ rmdir "${D}"/usr/share/doc/clazy || die |
71 |
+} |