Gentoo Archives: gentoo-commits

From: Sam James <sam@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: sci-libs/opencascade/
Date: Mon, 10 Jan 2022 01:04:07
Message-Id: 1641776549.62acc9193ee2728e613bb511a483ee16c8947ec1.sam@gentoo
1 commit: 62acc9193ee2728e613bb511a483ee16c8947ec1
2 Author: Bernd Waibel <waebbl-gentoo <AT> posteo <DOT> net>
3 AuthorDate: Mon Dec 13 05:01:20 2021 +0000
4 Commit: Sam James <sam <AT> gentoo <DOT> org>
5 CommitDate: Mon Jan 10 01:02:29 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=62acc919
7
8 sci-libs/opencascade: use single slot/subslot for 7.5.2
9
10 Instead of using different slots for different versions, the package now
11 uses a single slot with subslots. This is to simplify dependency handling
12 in revdeps.
13
14 Allow to build against sci-libs/vtk-9.1.0
15
16 Package-Manager: Portage-3.0.29, Repoman-3.0.3
17 Signed-off-by: Bernd Waibel <waebbl-gentoo <AT> posteo.net>
18 Signed-off-by: Sam James <sam <AT> gentoo.org>
19
20 ...7.5.2-r2.ebuild => opencascade-7.5.2-r3.ebuild} | 34 ++++++++++------------
21 1 file changed, 15 insertions(+), 19 deletions(-)
22
23 diff --git a/sci-libs/opencascade/opencascade-7.5.2-r2.ebuild b/sci-libs/opencascade/opencascade-7.5.2-r3.ebuild
24 similarity index 87%
25 rename from sci-libs/opencascade/opencascade-7.5.2-r2.ebuild
26 rename to sci-libs/opencascade/opencascade-7.5.2-r3.ebuild
27 index cf90cc0c8aa1..080f7888f0bd 100644
28 --- a/sci-libs/opencascade/opencascade-7.5.2-r2.ebuild
29 +++ b/sci-libs/opencascade/opencascade-7.5.2-r3.ebuild
30 @@ -14,7 +14,7 @@ SRC_URI="https://git.dev.opencascade.org/gitweb/?p=occt.git;a=snapshot;h=refs/ta
31 S="${WORKDIR}/occt-V${MY_PV}"
32
33 LICENSE="|| ( Open-CASCADE-LGPL-2.1-Exception-1.0 LGPL-2.1 )"
34 -SLOT="${PV_MAJ}"
35 +SLOT="0/${PV_MAJ}"
36 KEYWORDS="~amd64 ~arm64 ~x86"
37 IUSE="debug doc examples ffmpeg freeimage gles2 json optimize tbb vtk"
38
39 @@ -25,7 +25,6 @@ REQUIRED_USE="?? ( optimize tbb )"
40 RESTRICT="test"
41
42 RDEPEND="
43 - app-eselect/eselect-opencascade
44 dev-lang/tcl:=
45 dev-lang/tk:=
46 dev-tcltk/itcl
47 @@ -49,13 +48,11 @@ RDEPEND="
48 tbb? ( <dev-cpp/tbb-2021.4.0 )
49 vtk? ( sci-libs/vtk:=[rendering] )
50 "
51 -DEPEND="
52 - ${RDEPEND}
53 +DEPEND="${RDEPEND}"
54 +
55 +BDEPEND="
56 dev-cpp/eigen
57 dev-libs/rapidjson
58 -"
59 -BDEPEND="
60 - app-eselect/eselect-opencascade
61 doc? ( app-doc/doxygen )
62 examples? ( dev-qt/linguist-tools:5 )
63 "
64 @@ -119,7 +116,13 @@ src_configure() {
65 fi
66
67 if use vtk; then
68 - if has_version ">=sci-libs/vtk-9.0.0"; then
69 + if has_version ">=sci-libs/vtk-9.1.0"; then
70 + mycmakeargs+=(
71 + -D3RDPARTY_VTK_DIR="${ESYSROOT}"/usr
72 + -D3RDPARTY_VTK_INCLUDE_DIR="${ESYSROOT}"/usr/include/vtk-9.1
73 + -D3RDPARTY_VTK_LIBRARY_DIR="${ESYSROOT}"/usr/$(get_libdir)
74 + )
75 + elif has_version ">=sci-libs/vtk-9.0.0"; then
76 mycmakeargs+=(
77 -D3RDPARTY_VTK_DIR="${ESYSROOT}"/usr
78 -D3RDPARTY_VTK_INCLUDE_DIR="${ESYSROOT}"/usr/include/vtk-9.0
79 @@ -134,11 +137,11 @@ src_configure() {
80 sed -e "s|lib/|$(get_libdir)/|" \
81 -e "s|VAR_PV|${PV}|" \
82 -e "s|VAR_CASROOT|${ESYSROOT}/usr|" \
83 - < "${FILESDIR}"/${PN}-${PV_MAJ}.env.in > "${T}"/${PV_MAJ} || die
84 + < "${FILESDIR}"/${PN}.env.in > "${T}"/99${PN} || die
85
86 # use TBB for memory allocation optimizations
87 if use tbb; then
88 - sed -e 's|^#MMGT_OPT=0$|MMGT_OPT=2|' -i "${T}"/${PV_MAJ} || die
89 + sed -e 's|^#MMGT_OPT=0$|MMGT_OPT=2|' -i "${T}"/99${PN} || die
90 fi
91
92 # use internal optimized memory manager and don't clear memory with this
93 @@ -146,16 +149,14 @@ src_configure() {
94 if use optimize ; then
95 sed -e 's|^#MMGT_OPT=0$|MMGT_OPT=1|' \
96 -e 's|^#MMGT_CLEAR=1$|MMGT_CLEAR=0|' \
97 - -i "${T}"/${PV_MAJ} || die
98 + -i "${T}"/99${PN} || die
99 fi
100 }
101
102 src_install() {
103 cmake_src_install
104
105 - # respect slotting
106 - insinto "/etc/env.d/${PN}"
107 - doins "${T}/${PV_MAJ}"
108 + doenvd "${T}/99${PN}"
109
110 # remove examples
111 if use !examples; then
112 @@ -164,8 +165,3 @@ src_install() {
113
114 docompress -x /usr/share/doc/${PF}/overview/html
115 }
116 -
117 -pkg_postinst() {
118 - eselect ${PN} set ${PV_MAJ} || die "failed to switch to updated implementation"
119 - einfo "You can switch between available ${PN} implementations using eselect ${PN}"
120 -}