Gentoo Archives: gentoo-commits

From: Michael Orlitzky <mjo@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: sci-mathematics/giac/
Date: Thu, 03 Feb 2022 00:21:34
Message-Id: 1643847664.d2a696dfe2f80b592c711880c1c9cfeec540fbff.mjo@gentoo
1 commit: d2a696dfe2f80b592c711880c1c9cfeec540fbff
2 Author: François Bissey <frp.bissey <AT> gmail <DOT> com>
3 AuthorDate: Wed Feb 2 21:49:10 2022 +0000
4 Commit: Michael Orlitzky <mjo <AT> gentoo <DOT> org>
5 CommitDate: Thu Feb 3 00:21:04 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d2a696df
7
8 sci-mathematics/giac: version bump. Disable quickjs.
9
10 Package-Manager: Portage-3.0.30, Repoman-3.0.3
11 Closes: https://bugs.gentoo.org/832594
12 Closes: https://github.com/gentoo/gentoo/pull/24056
13 Signed-off-by: François René Pierre Bissey <frp.bissey <AT> gmail.com>
14 Signed-off-by: Michael Orlitzky <mjo <AT> gentoo.org>
15
16 sci-mathematics/giac/Manifest | 1 +
17 sci-mathematics/giac/giac-1.7.0.47.ebuild | 166 ++++++++++++++++++++++++++++++
18 2 files changed, 167 insertions(+)
19
20 diff --git a/sci-mathematics/giac/Manifest b/sci-mathematics/giac/Manifest
21 index 61c49c8e9650..259cb91e5543 100644
22 --- a/sci-mathematics/giac/Manifest
23 +++ b/sci-mathematics/giac/Manifest
24 @@ -1,2 +1,3 @@
25 DIST giac_1.7.0-13.tar.gz 86447065 BLAKE2B 4d91e83608f7ec376d133c2784ffce99447a9dd78b5c8582b81a0aae0b8ac59eec4db3ee4a8bcb39202c777c300178a181f2dc2ac74ab445ddba2f3efa0ecb1b SHA512 99fff7ce5117fd8c106601ead03679805d529fe12d5372cdd4ae54824aa6fdcbdaaa1a62ea1153391a1a65af8970e38fca7d95ca9983755ff06053f1d8b6d65a
26 DIST giac_1.7.0-45.tar.gz 96780194 BLAKE2B c43b0f89ad664b419db5d98541f23d3259a32b462d71f3a4fe06ea2ac3de0dd71d903308cd8e241758d809d0755a2f070bae03434a75abc94f17b1d8cbda03a2 SHA512 47fa019fee526d584f5dbc67adb4326e2680649ad942a2140d033ecd66957ba7a21441f02a3ba55d009bbd6756da239fcee99cab2a361993aae4df6e9f79a1a7
27 +DIST giac_1.7.0-47.tar.gz 96787570 BLAKE2B b05b3f44f10695a5d085df0a0db9aba761ac011964caeb247bd6034ca2a41505e5eb30df0de494826270703d9b62fbb3b9d4869f4cdd32d1d88636f374fbae16 SHA512 60a8550f7da2a163365759266660421c936797a9d52c3ba3802b5e00610fc460b49ccef44df809331abb1cbb65432e283fb4484b1efffb577c4802ab44fecff7
28
29 diff --git a/sci-mathematics/giac/giac-1.7.0.47.ebuild b/sci-mathematics/giac/giac-1.7.0.47.ebuild
30 new file mode 100644
31 index 000000000000..bf7ed2bdb24c
32 --- /dev/null
33 +++ b/sci-mathematics/giac/giac-1.7.0.47.ebuild
34 @@ -0,0 +1,166 @@
35 +# Copyright 1999-2022 Gentoo Authors
36 +# Distributed under the terms of the GNU General Public License v2
37 +
38 +EAPI=8
39 +
40 +inherit autotools flag-o-matic xdg-utils
41 +
42 +FETCH_P="${PN}_"$(ver_rs 3 '-')
43 +MY_PV=$(ver_cut 1-3)
44 +DESCRIPTION="A free C++ Computer Algebra System library and its interfaces"
45 +HOMEPAGE="https://www-fourier.ujf-grenoble.fr/~parisse/giac.html"
46 +SRC_URI="https://www-fourier.ujf-grenoble.fr/~parisse/debian/dists/stable/main/source/${FETCH_P}.tar.gz"
47 +LICENSE="GPL-2"
48 +
49 +SLOT="0"
50 +KEYWORDS="~amd64 ~x86"
51 +LANGS="el en es pt"
52 +IUSE="ao doc +ecm examples gc +glpk gui static-libs test"
53 +for X in ${LANGS} ; do
54 + IUSE="${IUSE} l10n_${X}"
55 +done
56 +
57 +# nauty and cliquer are automagical dependencies
58 +RDEPEND="dev-libs/gmp:=[cxx(+)]
59 + sys-libs/readline:=
60 + gui? ( x11-libs/fltk
61 + media-libs/libpng:= )
62 + ao? ( media-libs/libao )
63 + dev-libs/mpfr:=
64 + sci-libs/mpfi
65 + sci-libs/gsl:=
66 + sci-mathematics/pari:=[threads]
67 + dev-libs/ntl:=
68 + virtual/lapack
69 + virtual/blas
70 + net-misc/curl
71 + sci-mathematics/cliquer
72 + sci-mathematics/nauty
73 + ecm? ( sci-mathematics/gmp-ecm )
74 + glpk? ( sci-mathematics/glpk )
75 + gc? ( dev-libs/boehm-gc )"
76 +
77 +DEPEND="${RDEPEND}"
78 +
79 +BDEPEND="dev-tex/hevea
80 + virtual/pkgconfig
81 + virtual/yacc"
82 +
83 +PATCHES=(
84 + "${FILESDIR}/${PN}-1.7.0.1-gsl_lapack.patch"
85 + "${FILESDIR}/${PN}-1.6.0-pari-2.11.patch"
86 +)
87 +
88 +REQUIRED_USE="test? ( gui )"
89 +
90 +# The mirror restriction is due to the French documentation for which
91 +# "Other kind of redistributions require the consent of the copyright
92 +# holder."
93 +RESTRICT="!test? ( test ) mirror"
94 +
95 +S="${WORKDIR}/${PN}-${MY_PV}"
96 +
97 +src_prepare() {
98 + default
99 + eautoreconf
100 +}
101 +
102 +src_configure() {
103 + append-cxxflags -std=c++14 # bug 788283
104 +
105 + if use gui; then
106 + append-cppflags -I$(fltk-config --includedir)
107 + append-lfs-flags
108 +
109 + # Get the big-L flags from fltk's LDFLAGS.
110 + append-ldflags $(fltk-config --ldflags | sed -e 's/\(-L\S*\)\s.*/\1/')
111 + fi
112 +
113 + # Using libsamplerate is currently broken
114 + #
115 + # The giac build system supports --docdir, but the path /usr/share/giac/doc
116 + # is hard-coded throughout the source code, so passing anything else to
117 + # ./configure --docdir just causes problems. Later, we'll put things right.
118 + #
119 + # micropython is for specific use in an upstream project, so is quickjs.
120 + econf \
121 + --enable-gmpxx \
122 + --disable-samplerate \
123 + --disable-micropy \
124 + --disable-quickjs \
125 + --docdir="${EPREFIX}"/usr/share/giac/doc \
126 + $(use_enable static-libs static) \
127 + $(use_enable gui) \
128 + $(use_enable gui png) \
129 + $(use_enable ao) \
130 + $(use_enable ecm) \
131 + $(use_enable glpk) \
132 + $(use_enable gc)
133 +
134 +}
135 +
136 +src_install() {
137 + docompress -x "/usr/share/doc/${PF}/"{aide_cas,doc,examples}
138 + emake install DESTDIR="${D}"
139 +
140 + # Move all of /usr/share/giac (which contains only documentation) to
141 + # its /usr/share/doc/${PF} counterpart.
142 + dodir /usr/share/doc
143 + mv "${ED}"/usr/share/giac "${ED}/usr/share/doc/${PF}" || die
144 +
145 + # and create a symlink from the original location to the new one
146 + dosym "./doc/${PF}" /usr/share/giac
147 +
148 + # This is duplicated in ${ED}/usr/share/doc/${PF}/examples
149 + rm -r "${ED}/usr/share/doc/${PF}/doc/Exemples" || die
150 +
151 + # These aren't supposed to be installed at all.
152 + find "${ED}/usr/share/doc/${PF}" -type f -name 'Makefile*' -delete || die
153 +
154 + # The French docs are not freely licensed according to the README.
155 + rm -r "${ED}/usr/share/doc/${PF}/doc/fr" || die
156 +
157 + dodoc AUTHORS ChangeLog INSTALL NEWS README TROUBLES
158 + if ! use gui; then
159 + rm -rf \
160 + "${ED}"/usr/bin/x* \
161 + "${ED}"/usr/share/application-registry \
162 + "${ED}"/usr/share/applications \
163 + "${ED}"/usr/share/icons \
164 + || die "failed to clean up fltk files"
165 + fi
166 +
167 + if ! use doc; then
168 + rm -r "${ED}/usr/share/doc/${PF}/doc" || die "failed to remove doc directory"
169 + else
170 + for lang in ${LANGS}; do
171 + if use l10n_$lang; then
172 + dosym ../aide_cas "/usr/share/doc/${PF}/doc/${lang}/aide_cas"
173 + else
174 + rm -r "${ED}/usr/share/giac/doc/${lang}" \
175 + || die "failed to remove ${lang} documentation"
176 + fi
177 + done
178 + fi
179 +
180 + if ! use examples; then
181 + rm -r "${ED}/usr/share/doc/${PF}/examples" \
182 + || die "failed to remove examples"
183 + fi
184 +
185 + find "${ED}" -type f -name '*.la' -delete || die
186 +}
187 +
188 +pkg_postinst() {
189 + if use gui; then
190 + xdg_desktop_database_update
191 + xdg_icon_cache_update
192 + fi
193 +}
194 +
195 +pkg_postrm() {
196 + if use gui; then
197 + xdg_desktop_database_update
198 + xdg_icon_cache_update
199 + fi
200 +}