Gentoo Archives: gentoo-commits

From: Zac Medico <zmedico@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: app-text/calibre/
Date: Sun, 16 Feb 2020 20:25:58
Message-Id: 1581884746.7038fdf5f67295d572fe69b521dc4e2edbb3ce2f.zmedico@gentoo
1 commit: 7038fdf5f67295d572fe69b521dc4e2edbb3ce2f
2 Author: Zac Medico <zmedico <AT> gentoo <DOT> org>
3 AuthorDate: Sun Feb 16 20:24:37 2020 +0000
4 Commit: Zac Medico <zmedico <AT> gentoo <DOT> org>
5 CommitDate: Sun Feb 16 20:25:46 2020 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7038fdf5
7
8 app-text/calibre: drop 3.x version (bug 709848)
9
10 Closes: https://bugs.gentoo.org/709848
11 Package-Manager: Portage-2.3.89, Repoman-2.3.20
12 Signed-off-by: Zac Medico <zmedico <AT> gentoo.org>
13
14 app-text/calibre/Manifest | 1 -
15 app-text/calibre/calibre-3.48.0-r2.ebuild | 265 ------------------------------
16 2 files changed, 266 deletions(-)
17
18 diff --git a/app-text/calibre/Manifest b/app-text/calibre/Manifest
19 index ecc34eac2e3..853b3b9602a 100644
20 --- a/app-text/calibre/Manifest
21 +++ b/app-text/calibre/Manifest
22 @@ -1,3 +1,2 @@
23 -DIST calibre-3.48.0.tar.xz 38777408 BLAKE2B 9a7fae20487ae93120cfdc06a312a42d54d68935fdd2bc18dc41be5f8d359c79eae24e0409ba8e7f4df85e2f073f80ce6bab56cba0638cead6693600fa93cb41 SHA512 6cee28fb560e2e00b8ac2f32756f094146c6fe744cfc343d68f1fb54b3f8b0ca16129a5b35018af54a103790faa2eb03ac186c01003f21c874d2ed5218441220
24 DIST calibre-4.10.1.tar.xz 37012272 BLAKE2B e5d9421ed986da8ec7d814f364702fe04bcbb76b5e08dedfadd7164c81943cdfe6f012042e82a4715e3ccda284efdf44340af0bde9d03cbc7c22cbcf10136a55 SHA512 eb6f4fd458da3e3e1121ff72da0dfb2bdc38cec98bdaf538e6761563aa176aae2439e4949424795c239a8fa8ebde507564452495ef71f3f7f19b25435e10a41a
25 DIST calibre-4.9.1.tar.xz 37529656 BLAKE2B 5d703ca0c398b43cc26a54e0628d0fe938c6a5027a4fd0c9cac83944e5143eb08439bf79b2098182be7727eaa042748f17866788b02c7744178dce131f6b1d1e SHA512 bf06aa3cbc8d255934f3f7f3ce20b4798edf107ed9f822943d2b4ae7d95473842928ed79f8ba7571f7e0ebdc267c441916d543d5b7630aae5cb151bcc3184b71
26
27 diff --git a/app-text/calibre/calibre-3.48.0-r2.ebuild b/app-text/calibre/calibre-3.48.0-r2.ebuild
28 deleted file mode 100644
29 index 4aac7817f18..00000000000
30 --- a/app-text/calibre/calibre-3.48.0-r2.ebuild
31 +++ /dev/null
32 @@ -1,265 +0,0 @@
33 -# Copyright 1999-2020 Gentoo Authors
34 -# Distributed under the terms of the GNU General Public License v2
35 -
36 -EAPI=7
37 -
38 -PYTHON_COMPAT=( python2_7 )
39 -PYTHON_REQ_USE="sqlite,ssl"
40 -
41 -inherit bash-completion-r1 desktop toolchain-funcs python-single-r1 xdg-utils
42 -
43 -DESCRIPTION="Ebook management application"
44 -HOMEPAGE="https://calibre-ebook.com/"
45 -SRC_URI="https://download.calibre-ebook.com/${PV}/${P}.tar.xz"
46 -
47 -LICENSE="
48 - GPL-3+
49 - GPL-3
50 - GPL-2+
51 - GPL-2
52 - GPL-1+
53 - LGPL-3+
54 - LGPL-2.1+
55 - LGPL-2.1
56 - BSD
57 - MIT
58 - Old-MIT
59 - Apache-2.0
60 - public-domain
61 - || ( Artistic GPL-1+ )
62 - CC-BY-3.0
63 - OFL-1.1
64 - PSF-2
65 -"
66 -KEYWORDS="amd64 ~arm x86"
67 -SLOT="0"
68 -IUSE="ios +udisks"
69 -
70 -REQUIRED_USE="${PYTHON_REQUIRED_USE}"
71 -
72 -COMMON_DEPEND="${PYTHON_DEPS}
73 - >=app-text/podofo-0.9.6_pre20171027:=
74 - >=app-text/poppler-0.26.5[qt5]
75 - >=dev-libs/chmlib-0.40:=
76 - dev-libs/glib:2=
77 - >=dev-libs/icu-57.1:=
78 - dev-libs/libinput:=
79 - >=dev-libs/dbus-glib-0.106
80 - >=sys-apps/dbus-1.10.8
81 - $(python_gen_cond_dep '
82 - >=dev-python/apsw-3.25.2_p1[${PYTHON_MULTI_USEDEP}]
83 - dev-python/beautifulsoup:4[${PYTHON_MULTI_USEDEP}]
84 - >=dev-python/chardet-3.0.3[${PYTHON_MULTI_USEDEP}]
85 - >=dev-python/cssselect-0.7.1[${PYTHON_MULTI_USEDEP}]
86 - >=dev-python/css-parser-1.0.4[${PYTHON_MULTI_USEDEP}]
87 - >=dev-python/dbus-python-1.2.4[${PYTHON_MULTI_USEDEP}]
88 - dev-python/dnspython[${PYTHON_MULTI_USEDEP}]
89 - >=dev-python/feedparser-5.2.1[${PYTHON_MULTI_USEDEP}]
90 - >=dev-python/html5-parser-0.4.9[${PYTHON_MULTI_USEDEP}]
91 - >=dev-python/lxml-3.8.0[${PYTHON_MULTI_USEDEP}]
92 - >=dev-python/markdown-3.0.1[${PYTHON_MULTI_USEDEP}]
93 - >=dev-python/mechanize-0.3.5[${PYTHON_MULTI_USEDEP}]
94 - >=dev-python/msgpack-0.5.6[${PYTHON_MULTI_USEDEP}]
95 - >=dev-python/netifaces-0.10.5[${PYTHON_MULTI_USEDEP}]
96 - >=dev-python/pillow-3.2.0[${PYTHON_MULTI_USEDEP}]
97 - >=dev-python/psutil-4.3.0[${PYTHON_MULTI_USEDEP}]
98 - >=dev-python/pygments-2.3.1[${PYTHON_MULTI_USEDEP}]
99 - >=dev-python/python-dateutil-2.5.3[${PYTHON_MULTI_USEDEP}]
100 - >=dev-python/PyQt5-5.8[gui,svg,webkit,widgets,network,printsupport,${PYTHON_MULTI_USEDEP}]
101 - dev-python/regex[${PYTHON_MULTI_USEDEP}]
102 - ')
103 - dev-qt/qtcore:5=
104 - dev-qt/qtdbus:5=
105 - dev-qt/qtgui:5=
106 - dev-qt/qtwidgets:5=
107 - dev-util/desktop-file-utils
108 - dev-util/gtk-update-icon-cache
109 - media-fonts/liberation-fonts
110 - media-libs/fontconfig:=
111 - >=media-libs/freetype-2:=
112 - >=media-libs/libmtp-1.1.11:=
113 - >=media-libs/libwmf-0.2.8
114 - >=media-gfx/optipng-0.7.6
115 - >=sys-libs/zlib-1.2.11:=
116 - virtual/libusb:1=
117 - x11-libs/libxkbcommon:=
118 - x11-libs/libX11:=
119 - x11-libs/libXext:=
120 - x11-libs/libXrender:=
121 - x11-misc/shared-mime-info
122 - >=x11-misc/xdg-utils-1.0.2-r2
123 - ios? (
124 - >=app-pda/usbmuxd-1.0.8
125 - >=app-pda/libimobiledevice-1.2.0
126 - )
127 - udisks? ( virtual/libudev )"
128 -RDEPEND="${COMMON_DEPEND}
129 - udisks? ( || ( sys-fs/udisks:2 sys-fs/udisks:0 ) )"
130 -DEPEND="${COMMON_DEPEND}
131 - $(python_gen_cond_dep '
132 - >=dev-python/setuptools-23.1.0[${PYTHON_MULTI_USEDEP}]
133 - dev-python/sip[${PYTHON_MULTI_USEDEP}]
134 - ')
135 - >=virtual/podofo-build-0.9.6_pre20171027
136 - virtual/pkgconfig"
137 -
138 -pkg_pretend() {
139 - if [[ ${MERGE_TYPE} != binary && $(gcc-major-version) -lt 6 ]]; then
140 - eerror "Calibre cannot be built with this version of gcc."
141 - eerror "You need at least gcc-6.0"
142 - die "Your C compiler is too old for this package."
143 - fi
144 -}
145 -
146 -src_prepare() {
147 - # no_updates: do not annoy user with "new version is availible all the time
148 - # disable_plugins: walking sec-hole, wait for upstream to use GHNS interface
149 - eapply \
150 - "${FILESDIR}/${PN}-2.9.0-no_updates_dialog.patch" \
151 - "${FILESDIR}/${PN}-disable_plugins.patch"
152 -
153 - eapply_user
154 -
155 - # Fix outdated version constant.
156 - #sed -e "s#\\(^numeric_version =\\).*#\\1 (${PV//./, })#" \
157 - # -i src/calibre/constants.py || \
158 - # die "sed failed to patch constants.py"
159 -
160 - # Avoid sandbox violation in /usr/share/gnome/apps when linux.py
161 - # calls xdg-* (bug #258938).
162 - sed -e "s|'xdg-desktop-menu', 'install'|\\0, '--mode', 'user'|" \
163 - -e "s|check_call(\\['xdg-desktop-menu', 'forceupdate'\\])|#\\0|" \
164 - -e "s|\\(CurrentDir(tdir)\\), \\\\\$|\\1:|" \
165 - -e "s|, PreserveMIMEDefaults():|:|" \
166 - -e "s|'xdg-icon-resource', 'install'|\\0, '--mode', 'user'|" \
167 - -e "s|cmd\[2\]|cmd[4]|" \
168 - -e "s|cc(\\['xdg-desktop-menu', 'forceupdate'\\])|#\\0|" \
169 - -e "s|'xdg-mime', 'install'|\\0, '--mode', 'user'|" \
170 - -i src/calibre/linux.py || die "sed failed to patch linux.py"
171 -
172 - # Disable unnecessary privilege dropping for bug #287067.
173 - sed -e "s:if os.geteuid() == 0:if False and os.geteuid() == 0:" \
174 - -i setup/install.py || die "sed failed to patch install.py"
175 -
176 - sed -e "/^ self.check_call(\\[QMAKE\\] + qmc + \\[proname\\])$/a\
177 -\\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ self.check_call(['sed', \
178 -'-e', 's|^CFLAGS .*|\\\\\\\\0 ${CFLAGS}|', \
179 -'-e', 's|^CXXFLAGS .*|\\\\\\\\0 ${CXXFLAGS}|', \
180 -'-e', 's|^LFLAGS .*|\\\\\\\\0 ${LDFLAGS}|', \
181 -'-i', 'Makefile'])" \
182 - -i setup/build.py || die "sed failed to patch build.py"
183 -}
184 -
185 -src_install() {
186 - # Bypass kbuildsycoca and update-mime-database in order to
187 - # avoid sandbox violations if xdg-mime tries to call them.
188 - cat - > "${T}/kbuildsycoca" <<-EOF
189 - #!${BASH}
190 - echo $0 : $@
191 - exit 0
192 - EOF
193 -
194 - cp "${T}"/{kbuildsycoca,update-mime-database} || die
195 - chmod +x "${T}"/{kbuildsycoca,update-mime-database} || die
196 -
197 - export QMAKE="${EPREFIX}/usr/$(get_libdir)/qt5/bin/qmake"
198 -
199 - # Unset DISPLAY in order to prevent xdg-mime from triggering a sandbox
200 - # violation with kbuildsycoca as in bug #287067, comment #13.
201 - export -n DISPLAY
202 -
203 - # Bug #352625 - Some LANGUAGE values can trigger the following ValueError:
204 - # File "/usr/lib/python2.6/locale.py", line 486, in getdefaultlocale
205 - # return _parse_localename(localename)
206 - # File "/usr/lib/python2.6/locale.py", line 418, in _parse_localename
207 - # raise ValueError, 'unknown locale: %s' % localename
208 - #ValueError: unknown locale: 46
209 - export -n LANG LANGUAGE ${!LC_*}
210 - export LC_ALL=C #684484
211 -
212 - # Bug #295672 - Avoid sandbox violation in ~/.config by forcing
213 - # variables to point to our fake temporary $HOME.
214 - export HOME="${T}/fake_homedir"
215 - export XDG_CONFIG_HOME="${HOME}/.config"
216 - export XDG_DATA_HOME="${HOME}/.local/share"
217 - export CALIBRE_CONFIG_DIRECTORY="${XDG_CONFIG_HOME}/calibre"
218 - mkdir -p "${XDG_DATA_HOME}" "${CALIBRE_CONFIG_DIRECTORY}" || die
219 -
220 - tc-export CC CXX
221 - # Bug #334243 - respect LDFLAGS when building extensions
222 - export OVERRIDE_CFLAGS="$CFLAGS" OVERRIDE_LDFLAGS="$LDFLAGS"
223 - local libdir=$(get_libdir)
224 - [[ -n $libdir ]] || die "get_libdir returned an empty string"
225 -
226 - addpredict /dev/dri #665310
227 -
228 - PATH=${T}:${PATH} PYTHONPATH=${S}/src${PYTHONPATH:+:}${PYTHONPATH} \
229 - "${PYTHON}" setup.py install \
230 - --root="${D}" \
231 - --prefix="${EPREFIX}/usr" \
232 - --libdir="${EPREFIX}/usr/${libdir}" \
233 - --staging-root="${ED}/usr" \
234 - --staging-libdir="${ED}/usr/${libdir}" || die
235 -
236 - rm "${ED}/usr/share/applications/defaults.list" || die
237 - find "${ED}"/usr/share -type d -empty -delete
238 -
239 - cd "${ED}"/usr/share/calibre/fonts/liberation || die
240 - local x
241 - for x in * ; do
242 - [[ -f ${EPREFIX}/usr/share/fonts/liberation-fonts/${x} ]] || continue
243 - ln -sf "../../../fonts/liberation-fonts/${x}" "${x}" || die
244 - done
245 -
246 - einfo "Converting python shebangs"
247 - python_fix_shebang --force "${ED}"
248 -
249 - einfo "Compiling python modules"
250 - python_optimize "${ED}"/usr/lib/calibre
251 -
252 - newinitd "${FILESDIR}"/calibre-server-3.init calibre-server
253 - newconfd "${FILESDIR}"/calibre-server-3.conf calibre-server
254 -
255 - bashcomp_alias calibre \
256 - lrfviewer \
257 - calibre-debug \
258 - ebook-meta \
259 - calibre-server \
260 - ebook-viewer \
261 - ebook-polish \
262 - fetch-ebook-metadata \
263 - lrf2lrs \
264 - ebook-convert \
265 - ebook-edit \
266 - calibre-smtp \
267 - ebook-device
268 -
269 -}
270 -
271 -pkg_preinst() {
272 - # Indentify stray directories from upstream's "Binary install"
273 - # method (see bug 622728).
274 - CALIBRE_LIB_DIR=/usr/$(get_libdir)/calibre
275 - CALIBRE_LIB_CONTENT=$(for x in "${ED}${CALIBRE_LIB_DIR}"/*; do
276 - printf -- "${x##*/} "; done) || die "Failed to list ${ED}${CALIBRE_LIB_DIR}"
277 -}
278 -
279 -pkg_postinst() {
280 - [[ -n ${CALIBRE_LIB_DIR} ]] || die "CALIBRE_LIB_DIR is unset"
281 - local x
282 - for x in "${EROOT}${CALIBRE_LIB_DIR}"/*; do
283 - if [[ " ${CALIBRE_LIB_CONTENT} " != *" ${x##*/} "* ]]; then
284 - elog "Purging '${x}'"
285 - rm -rf "${x}"
286 - fi
287 - done
288 - xdg_desktop_database_update
289 - xdg_mimeinfo_database_update
290 - xdg_icon_cache_update
291 -}
292 -
293 -pkg_postrm() {
294 - xdg_desktop_database_update
295 - xdg_mimeinfo_database_update
296 - xdg_icon_cache_update
297 -}