diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2020-12-14 13:26:14 +0000 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2020-12-14 13:26:14 +0000 |
commit | 6abbf81ef2f298e3221ff5e67a1f3c5f23958212 (patch) | |
tree | 25413d1cb3a0cbfe36029db32398c0f333609215 /app-text/calibre | |
parent | 9c417bacd51da6d8b57fa9f37425161d30d4b95b (diff) |
gentoo resync : 14.12.2020
Diffstat (limited to 'app-text/calibre')
-rw-r--r-- | app-text/calibre/Manifest | 11 | ||||
-rw-r--r-- | app-text/calibre/calibre-4.22.0.ebuild | 2 | ||||
-rw-r--r-- | app-text/calibre/calibre-4.23.0.ebuild | 2 | ||||
-rw-r--r-- | app-text/calibre/calibre-5.4.2-r1.ebuild (renamed from app-text/calibre/calibre-5.4.2.ebuild) | 4 | ||||
-rw-r--r-- | app-text/calibre/calibre-5.6.0.ebuild | 264 | ||||
-rw-r--r-- | app-text/calibre/files/calibre-4.22.0-icu68.patch | 49 | ||||
-rw-r--r-- | app-text/calibre/metadata.xml | 3 |
7 files changed, 327 insertions, 8 deletions
diff --git a/app-text/calibre/Manifest b/app-text/calibre/Manifest index 80cd03021e2b..15d22894613c 100644 --- a/app-text/calibre/Manifest +++ b/app-text/calibre/Manifest @@ -1,4 +1,5 @@ AUX calibre-2.9.0-no_updates_dialog.patch 1661 BLAKE2B c75fc49a621e8dbd16ee1bad748110399cf09a404b4a905d3f723bac1827787e4749f464ba026700b6e5b3cc0ee646a92de00f1f58d10cf12dc9bc91195ee8b6 SHA512 9663b95ed64bdc2bc40692922384d1c6073177eee58a49c412883c4d2ae098e4e0b4ea51b80443108b7c0c3e4f3fda60c00fc3be4d0b62a5d79d982697927235 +AUX calibre-4.22.0-icu68.patch 1552 BLAKE2B 481b2c1f61aadab677360419f56dc6db8fa54c3d36ad1c01a9cca42f929a75b13948a417c763a5ee36a72df316db360990ec1f83cbe74df3b45794c6839a145a SHA512 3f8d29294b4bdcd1ddb1de68ce38dde52508889721f897b93afd7f595e2f405c7636e421d9d4ad3a8406593f3ada8d32bc5b7570812c5190d5ed7150e8484ca3 AUX calibre-disable_plugins.patch 1042 BLAKE2B 92a56016c2c54f1b156bc91031420594445545b98b701f7cce99cf4bb86847eebad1ccebdc20a0d1b67f9fa88a9250fc4926d7c04cb36405323388b3171cf502 SHA512 c152ddd92728a89db10c75a4d00a968bf119bef68da8b9116c76827e3cdc8f8a7e5c45fbb973f6ca8db1f79e461518351ce2d47e5e059c282f36d2df499d1629 AUX calibre-server-3.conf 541 BLAKE2B 06593633721e6adf2cf2077dffa83953eea46ccdcdc857ad468a9b74788326e9424f6ab9058be344dbbac8e49d343f5a1e53ddb486f2018b77319a7f8f713cf4 SHA512 12ef793a5b6ffd4413f780a13cad63927a95f15d17d85d4229eb5005ead68e51779abb822f9898ab5ae8c2094affeec1f9e85c34f109499739e6726b7641542a AUX calibre-server-3.init 1796 BLAKE2B f87d785d6f6fc10fa648d40944ec8538027854bb872d9a3be6b5b35b0abf3cda1e4e93874a9422914da5eb4287f193459733956e3f1e25e61bec0c214c552c99 SHA512 88110ded1b9c6cf8d3bfc3d5889654f77578f9d299e88daea9023767b930082e00fbddbb92a6e43c46d900248f3684232d93396ec1d0e784c7ec14b44783f98a @@ -6,7 +7,9 @@ DIST calibre-4.22.0.tar.xz 36924876 BLAKE2B 19576d5cfc1a4ed6a505ef46656675980b67 DIST calibre-4.23.0.tar.xz 36908740 BLAKE2B 3a950ac2b3aade547bb686cc99b963357e76b5931049ecb4a5e09ddaf1db26c74fa3b4ebd74e42d83f68c5c9827c534c0247a3c6a9b000641a778cfe5ac33599 SHA512 2a512f29ddc2fed7f6a229314a9f7fceac198c9422b3be19078685032f1d1cb3b9258ac2609c33d15da20683c1277ed09419ea1e9bbc70430cdc676f60395719 DIST calibre-5.4.2-SIP-v4.patch.xz 4640 BLAKE2B e8d20d9e23922885ecc3d24b7dd83579911dc83520037bad4e9323725c3127d348dc745dc725d137a3172e8891764355d3fcdee640a26cd6b142a2c26d00da0b SHA512 e79ee69ba0ca7e44c10c6670743889d0391d708e75c798e345e6228f483347f72b070e01e2a258590420a1eea6313d88d816817886747c699e6783bd965ab557 DIST calibre-5.4.2.tar.xz 36596800 BLAKE2B 00373cdc9af56a8dacc70096d1e7925f8d3da4eaf37727ad58c211d18e6c593a21c3ad0f283048ae28b1bb83889c8c801baaa5e240eb65d972ebc78a79922ec1 SHA512 ef3839f5ff4ceecb3bbd6c84819d6f57cc4bb2a1ae789a9dcf8f029680bc778ef86f9c2eb01832c4990f68c2de892eedafa449205470cec4d86a3bbe9d4b4527 -EBUILD calibre-4.22.0.ebuild 8692 BLAKE2B 7d394fc987120030e3ca6dfc593ddaf103a52983f13bb95e02c063da6ca9c3500f6c1d60148040bb8c19e70d731145b1ef086493f2817b4512b036c95daf8a1d SHA512 4fbd12df71e6ad2371540595b4aeeed833a465d5c9b6bff70d20949d27671a875e209e5d98a84cad0d16176879d8f4c1b7f7dd46427f5e32a7c9fc600d508955 -EBUILD calibre-4.23.0.ebuild 8735 BLAKE2B dcec79565840c0fca422ea5a973072e46a5233b5440c6eaa2db8049151e4110a1dadc8af8c65e43bd2d1010f7dd63a0f39d30192e4fa1bf28a5141753f923363 SHA512 6fde8b0929df69346aa619e2398ea7f43d03984eef2db967e3047e490c22845641883b78b049c59be62b9053f4ba77a29e325138d7c5c3820456d063fbe7b0ee -EBUILD calibre-5.4.2.ebuild 8659 BLAKE2B 1b5bac25d97ef4543c94a8646fb44c024918f2302286813fefd328b984368a49cf8ffea55410a339aa4acb407a78b165cd9566ac31d35f538561c96aa54ceea4 SHA512 5a533b3858f0ca63fb7e4a1a9abe0cd44906ce9c1cb54e4045c3e802cca147ff78691a83000daa561c4c1a956a5c63ea047c380c86a6e04a51c3b6c8aa62268b -MISC metadata.xml 382 BLAKE2B 87fa7e63a6ed7a4ea55247b362288b43f7edd312cc3085bb8c1b947402ae4aa0df01fac4f6646d260653ff8af7fe28d3dabb8a213dbf3e206181b69835b33d5f SHA512 8503e0a4a48d93682c386eb1d6507b4b26585afc9d62b7cd52bc00b457a887bd17422a03669ff404570ff7f5ff6f0bba14ee935979f8b54722870d6620097de5 +DIST calibre-5.6.0.tar.xz 36653328 BLAKE2B 44941c50873c285aa552c5b4ac716e5d3dd6bc3e1a4f13b1003d42adb808566ec3a5083c683a40d9679524e4ae70eed6ec8bc4c70770991f9791bcea25387c42 SHA512 5d06b60467bbf332acb8666d4117407c2876cfe2726dca3e9d9ed5d77561614406c7150c2800aacefe3cecb0869c1cd7b2681eba27830248b3c32e362123d50f +EBUILD calibre-4.22.0.ebuild 8777 BLAKE2B 98571cdd9f4f5af94d5845e72916be4bc7e3b0ece2e0179045bf4799e219a09a107d0e93f665e2980001b802705392aa5bb8709604e1ac319a65edd452d0b539 SHA512 e9488d9110911d33c7568f608f825e4481e3de0659c8304a5d9e4a3734602bf126806e3e460b2cde45866d0c2976fe45238f3bae67d2bde299f9326ce12e2ff8 +EBUILD calibre-4.23.0.ebuild 8820 BLAKE2B be3ea817795c0476cc19b1b0421df52030ac27e4a3ed3651c3d3dad9c3e3d2ce5d276442cec72a6eb2451684f5196beecbc70d8f02d520601ff9546ae145a2d2 SHA512 e42af2e3e12d811690586a4af4d66854e2c9e8096e31abb32ebd1181e6d982f93aadce3d26b5e00f15572b9b1aa0badca8de27781adc9f3aa9966b26554fa4f9 +EBUILD calibre-5.4.2-r1.ebuild 8769 BLAKE2B 8fffa73b1f6f9ccfc6bed49e8beab87f3b0c77b8a967f8248efdbf9b96ed99f8ccdbead2f2244f8090e3735e1da5036660fea607d0e098b45314949a3f42f0c1 SHA512 2b8702a7e7066b6f4de86b3dcd709afceecfa8cb810e65a2f03b327b6938ed6b6e562812f8af51a311285ed66080be9f53daac4289be823c8473d89ac88d8fba +EBUILD calibre-5.6.0.ebuild 8713 BLAKE2B a26ee08f18f7e819a6d28e18162036b67a1bbb6459a7a3be5afee012ee9fc254f83c29fb0953ed9310cda882dbdd36a6819101e707418be2b70f26077a78d6a4 SHA512 592fce01d289f6c3206e0ba9d7139122f767bb035acff99bc5c73a88752759458b03eb50c93c99b941b6b39b59b1dc6a16b3cceb8929dd501caace7c38d829f7 +MISC metadata.xml 303 BLAKE2B f50da5b3e8c1e9b4553180ccce38939e7c8e11e5a0527f94c3df7ac4d93a37d5e838c633e58b3fe960dc60ce52c6c6ec6901eedbcd99039c0cc1ccf6dc8a0a44 SHA512 38da4e43d91a3a1d1adf6daf32e4ec69696ab7df6179788fbda75a40219acf01cedbff28943c0b169b2de9f490f3a324285294a9b2783c90757c8cd23aa9e847 diff --git a/app-text/calibre/calibre-4.22.0.ebuild b/app-text/calibre/calibre-4.22.0.ebuild index 7dca7d16c3d3..e4e9240c23ba 100644 --- a/app-text/calibre/calibre-4.22.0.ebuild +++ b/app-text/calibre/calibre-4.22.0.ebuild @@ -124,6 +124,8 @@ src_prepare() { "${FILESDIR}/${PN}-2.9.0-no_updates_dialog.patch" \ "${FILESDIR}/${PN}-disable_plugins.patch" + has_version ">=dev-libs/icu-68.1" && eapply "${FILESDIR}/${PN}-4.22.0-icu68.patch" + eapply_user # Fix outdated version constant. diff --git a/app-text/calibre/calibre-4.23.0.ebuild b/app-text/calibre/calibre-4.23.0.ebuild index 2e529363d2c8..52871226e47f 100644 --- a/app-text/calibre/calibre-4.23.0.ebuild +++ b/app-text/calibre/calibre-4.23.0.ebuild @@ -124,6 +124,8 @@ src_prepare() { "${FILESDIR}/${PN}-2.9.0-no_updates_dialog.patch" \ "${FILESDIR}/${PN}-disable_plugins.patch" + has_version ">=dev-libs/icu-68.1" && eapply "${FILESDIR}/${PN}-4.22.0-icu68.patch" + eapply_user # Fix outdated version constant. diff --git a/app-text/calibre/calibre-5.4.2.ebuild b/app-text/calibre/calibre-5.4.2-r1.ebuild index 6c46bbdb0639..85080bb9aa86 100644 --- a/app-text/calibre/calibre-5.4.2.ebuild +++ b/app-text/calibre/calibre-5.4.2-r1.ebuild @@ -42,7 +42,6 @@ COMMON_DEPEND="${PYTHON_DEPS} >=app-text/hunspell-1.7:= >=app-text/podofo-0.9.6_pre20171027:= >=app-text/poppler-0.26.5[qt5] - >=dev-libs/chmlib-0.40:= dev-libs/glib:2= dev-libs/hyphen:= >=dev-libs/icu-57.1:= @@ -67,6 +66,7 @@ COMMON_DEPEND="${PYTHON_DEPS} >=dev-python/netifaces-0.10.5[${PYTHON_MULTI_USEDEP}] >=dev-python/pillow-3.2.0[${PYTHON_MULTI_USEDEP}] >=dev-python/psutil-4.3.0[${PYTHON_MULTI_USEDEP}] + >=dev-python/pychm-0.8.6[${PYTHON_MULTI_USEDEP}] >=dev-python/pygments-2.3.1[${PYTHON_MULTI_USEDEP}] >=dev-python/python-dateutil-2.5.3[${PYTHON_MULTI_USEDEP}] >=dev-python/PyQt5-5.12[gui,svg,widgets,network,printsupport,${PYTHON_MULTI_USEDEP}] @@ -126,6 +126,8 @@ src_prepare() { "${FILESDIR}/${PN}-disable_plugins.patch" \ "${WORKDIR}/${PN}-5.4.2-SIP-v4.patch" + has_version ">=dev-libs/icu-68.1" && eapply "${FILESDIR}/${PN}-4.22.0-icu68.patch" + eapply_user # Fix outdated version constant. diff --git a/app-text/calibre/calibre-5.6.0.ebuild b/app-text/calibre/calibre-5.6.0.ebuild new file mode 100644 index 000000000000..1547c3b7358e --- /dev/null +++ b/app-text/calibre/calibre-5.6.0.ebuild @@ -0,0 +1,264 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +PYTHON_COMPAT=( python3_{8..9} ) +PYTHON_REQ_USE="ipv6,sqlite,ssl" + +inherit bash-completion-r1 desktop toolchain-funcs python-single-r1 xdg-utils + +DESCRIPTION="Ebook management application" +HOMEPAGE="https://calibre-ebook.com/" +SRC_URI="https://download.calibre-ebook.com/${PV}/${P}.tar.xz + https://dev.gentoo.org/~zmedico/dist/calibre-5.4.2-SIP-v4.patch.xz" + +LICENSE=" + GPL-3+ + GPL-3 + GPL-2+ + GPL-2 + GPL-1+ + LGPL-3+ + LGPL-2.1+ + LGPL-2.1 + BSD + MIT + Old-MIT + Apache-2.0 + public-domain + || ( Artistic GPL-1+ ) + CC-BY-3.0 + OFL-1.1 + PSF-2 +" +KEYWORDS="~amd64 ~arm ~x86" +SLOT="0" +IUSE="ios +udisks" + +REQUIRED_USE="${PYTHON_REQUIRED_USE}" + +COMMON_DEPEND="${PYTHON_DEPS} + >=app-text/hunspell-1.7:= + >=app-text/podofo-0.9.6_pre20171027:= + >=app-text/poppler-0.26.5[qt5] + dev-libs/glib:2= + dev-libs/hyphen:= + >=dev-libs/icu-57.1:= + dev-libs/libinput:= + >=dev-libs/dbus-glib-0.106 + >=sys-apps/dbus-1.10.8 + $(python_gen_cond_dep ' + >=dev-python/apsw-3.25.2_p1[${PYTHON_MULTI_USEDEP}] + dev-python/beautifulsoup:4[${PYTHON_MULTI_USEDEP}] + >=dev-python/chardet-3.0.3[${PYTHON_MULTI_USEDEP}] + >=dev-python/cssselect-0.7.1[${PYTHON_MULTI_USEDEP}] + >=dev-python/css-parser-1.0.4[${PYTHON_MULTI_USEDEP}] + >=dev-python/dbus-python-1.2.4[${PYTHON_MULTI_USEDEP}] + dev-python/dnspython[${PYTHON_MULTI_USEDEP}] + >=dev-python/feedparser-5.2.1[${PYTHON_MULTI_USEDEP}] + >=dev-python/html2text-2019.8.11[${PYTHON_MULTI_USEDEP}] + >=dev-python/html5-parser-0.4.9[${PYTHON_MULTI_USEDEP}] + >=dev-python/lxml-3.8.0[${PYTHON_MULTI_USEDEP}] + >=dev-python/markdown-3.0.1[${PYTHON_MULTI_USEDEP}] + >=dev-python/mechanize-0.3.5[${PYTHON_MULTI_USEDEP}] + >=dev-python/msgpack-0.6.2[${PYTHON_MULTI_USEDEP}] + >=dev-python/netifaces-0.10.5[${PYTHON_MULTI_USEDEP}] + >=dev-python/pillow-3.2.0[${PYTHON_MULTI_USEDEP}] + >=dev-python/psutil-4.3.0[${PYTHON_MULTI_USEDEP}] + >=dev-python/pychm-0.8.6[${PYTHON_MULTI_USEDEP}] + >=dev-python/pygments-2.3.1[${PYTHON_MULTI_USEDEP}] + >=dev-python/python-dateutil-2.5.3[${PYTHON_MULTI_USEDEP}] + >=dev-python/PyQt5-5.12[gui,svg,widgets,network,printsupport,${PYTHON_MULTI_USEDEP}] + >=dev-python/PyQtWebEngine-5.12[${PYTHON_MULTI_USEDEP}] + dev-python/regex[${PYTHON_MULTI_USEDEP}] + dev-python/zeroconf[${PYTHON_MULTI_USEDEP}] + ') + dev-qt/qtcore:5= + dev-qt/qtdbus:5= + dev-qt/qtgui:5=[jpeg] + >=dev-qt/qtwebengine-5.12 + dev-qt/qtwidgets:5= + dev-util/desktop-file-utils + dev-util/gtk-update-icon-cache + media-fonts/liberation-fonts + media-libs/fontconfig:= + >=media-libs/freetype-2:= + >=media-libs/libmtp-1.1.11:= + >=media-libs/libwmf-0.2.8 + >=media-gfx/optipng-0.7.6 + >=sys-libs/zlib-1.2.11:= + virtual/libusb:1= + x11-libs/libxkbcommon:= + x11-libs/libX11:= + x11-libs/libXext:= + x11-libs/libXrender:= + x11-misc/shared-mime-info + >=x11-misc/xdg-utils-1.0.2-r2 + ios? ( + >=app-pda/usbmuxd-1.0.8 + >=app-pda/libimobiledevice-1.2.0 + ) + udisks? ( virtual/libudev )" +RDEPEND="${COMMON_DEPEND} + udisks? ( sys-fs/udisks:2 )" +DEPEND="${COMMON_DEPEND} + $(python_gen_cond_dep ' + >=dev-python/setuptools-23.1.0[${PYTHON_MULTI_USEDEP}] + dev-python/sip[${PYTHON_MULTI_USEDEP}] + ') + >=virtual/podofo-build-0.9.6_pre20171027 + virtual/pkgconfig" + +pkg_pretend() { + if [[ ${MERGE_TYPE} != binary ]] && tc-is-gcc && [[ $(gcc-major-version) -lt 6 ]]; then + eerror "Calibre cannot be built with this version of gcc." + eerror "You need at least gcc-6.0" + die "Your C compiler is too old for this package." + fi +} + +src_prepare() { + # no_updates: do not annoy user with "new version is availible all the time + # disable_plugins: walking sec-hole, wait for upstream to use GHNS interface + eapply \ + "${FILESDIR}/${PN}-2.9.0-no_updates_dialog.patch" \ + "${FILESDIR}/${PN}-disable_plugins.patch" \ + "${WORKDIR}/${PN}-5.4.2-SIP-v4.patch" + + has_version ">=dev-libs/icu-68.1" && eapply "${FILESDIR}/${PN}-4.22.0-icu68.patch" + + eapply_user + + # Fix outdated version constant. + #sed -e "s#\\(^numeric_version =\\).*#\\1 (${PV//./, })#" \ + # -i src/calibre/constants.py || \ + # die "sed failed to patch constants.py" + + # Avoid sandbox violation in /usr/share/gnome/apps when linux.py + # calls xdg-* (bug #258938). + sed -e "s|'xdg-desktop-menu', 'install'|\\0, '--mode', 'user'|" \ + -e "s|check_call(\\['xdg-desktop-menu', 'forceupdate'\\])|#\\0|" \ + -e "s|\\(CurrentDir(tdir)\\), \\\\\$|\\1:|" \ + -e "s|, PreserveMIMEDefaults():|:|" \ + -e "s|'xdg-icon-resource', 'install'|\\0, '--mode', 'user'|" \ + -e "s|cmd\[2\]|cmd[4]|" \ + -e "s|cc(\\['xdg-desktop-menu', 'forceupdate'\\])|#\\0|" \ + -e "s|'xdg-mime', 'install'|\\0, '--mode', 'user'|" \ + -i src/calibre/linux.py || die "sed failed to patch linux.py" + + # Disable unnecessary privilege dropping for bug #287067. + sed -e "s:if os.geteuid() == 0:if False and os.geteuid() == 0:" \ + -i setup/install.py || die "sed failed to patch install.py" + + sed -e "/^ self.check_call(\\[QMAKE\\] + qmc + \\[proname\\])$/a\ +\\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ self.check_call(['sed', \ +'-e', 's|^CFLAGS .*|\\\\\\\\0 ${CFLAGS}|', \ +'-e', 's|^CXXFLAGS .*|\\\\\\\\0 ${CXXFLAGS}|', \ +'-e', 's|^LFLAGS .*|\\\\\\\\0 ${LDFLAGS}|', \ +'-i', 'Makefile'])" \ + -e "s|open(self.j(bdir, '.qmake.conf'), 'wb').close()|open(self.j(bdir, '.qmake.conf'), 'wb').write(b'QMAKE_LFLAGS += ${LDFLAGS}')|" \ + -i setup/build.py || die "sed failed to patch build.py" +} + +src_install() { + # calibre works with python 3, so remove the python 2 constraint + export CALIBRE_PY3_PORT=1 + + # Bypass kbuildsycoca and update-mime-database in order to + # avoid sandbox violations if xdg-mime tries to call them. + mkdir "${T}/bin" || die + cat - > "${T}/bin/kbuildsycoca" <<-EOF + #!${BASH} + echo $0 : $@ + exit 0 + EOF + + cp "${T}"/bin/{kbuildsycoca,update-mime-database} || die + chmod +x "${T}"/bin/{kbuildsycoca,update-mime-database} || die + + export QMAKE="${EPREFIX}/usr/$(get_libdir)/qt5/bin/qmake" + + # Unset DISPLAY in order to prevent xdg-mime from triggering a sandbox + # violation with kbuildsycoca as in bug #287067, comment #13. + export -n DISPLAY + + # Bug #352625 - Some LANGUAGE values can trigger the following ValueError: + # File "/usr/lib/python2.6/locale.py", line 486, in getdefaultlocale + # return _parse_localename(localename) + # File "/usr/lib/python2.6/locale.py", line 418, in _parse_localename + # raise ValueError, 'unknown locale: %s' % localename + #ValueError: unknown locale: 46 + export -n LANG LANGUAGE ${!LC_*} + export LC_ALL=C.utf8 #709682 + + # Bug #295672 - Avoid sandbox violation in ~/.config by forcing + # variables to point to our fake temporary $HOME. + export HOME="${T}/fake_homedir" + export XDG_CONFIG_HOME="${HOME}/.config" + export XDG_DATA_HOME="${HOME}/.local/share" + export CALIBRE_CONFIG_DIRECTORY="${XDG_CONFIG_HOME}/calibre" + mkdir -p "${XDG_DATA_HOME}" "${CALIBRE_CONFIG_DIRECTORY}" || die + + tc-export CC CXX + # Bug #334243 - respect LDFLAGS when building extensions + export OVERRIDE_CFLAGS="$CFLAGS" OVERRIDE_LDFLAGS="$LDFLAGS" + local libdir=$(get_libdir) + [[ -n $libdir ]] || die "get_libdir returned an empty string" + + addpredict /dev/dri #665310 + + PATH=${T}/bin:${PATH} PYTHONPATH=${S}/src${PYTHONPATH:+:}${PYTHONPATH} \ + "${PYTHON}" setup.py install \ + --root="${D}" \ + --prefix="${EPREFIX}/usr" \ + --libdir="${EPREFIX}/usr/${libdir}" \ + --staging-root="${ED}/usr" \ + --staging-libdir="${ED}/usr/${libdir}" || die + + find "${ED}"/usr/share -type d -empty -delete + + cd "${ED}"/usr/share/calibre/fonts/liberation || die + local x + for x in * ; do + [[ -f ${EPREFIX}/usr/share/fonts/liberation-fonts/${x} ]] || continue + ln -sf "../../../fonts/liberation-fonts/${x}" "${x}" || die + done + + einfo "Converting python shebangs" + python_fix_shebang --force "${ED}" + + einfo "Compiling python modules" + python_optimize "${ED}"/usr/$(get_libdir)/calibre "${D}/$(python_get_sitedir)" + + newinitd "${FILESDIR}"/calibre-server-3.init calibre-server + newconfd "${FILESDIR}"/calibre-server-3.conf calibre-server +} + +pkg_preinst() { + # Indentify stray directories from upstream's "Binary install" + # method (see bug 622728). + CALIBRE_LIB_DIR=/usr/$(get_libdir)/calibre + CALIBRE_LIB_CONTENT=$(for x in "${ED}${CALIBRE_LIB_DIR}"/*; do + printf -- "${x##*/} "; done) || die "Failed to list ${ED}${CALIBRE_LIB_DIR}" +} + +pkg_postinst() { + [[ -n ${CALIBRE_LIB_DIR} ]] || die "CALIBRE_LIB_DIR is unset" + local x + for x in "${EROOT}${CALIBRE_LIB_DIR}"/*; do + if [[ " ${CALIBRE_LIB_CONTENT} " != *" ${x##*/} "* ]]; then + elog "Purging '${x}'" + rm -rf "${x}" + fi + done + xdg_desktop_database_update + xdg_mimeinfo_database_update + xdg_icon_cache_update +} + +pkg_postrm() { + xdg_desktop_database_update + xdg_mimeinfo_database_update + xdg_icon_cache_update +} diff --git a/app-text/calibre/files/calibre-4.22.0-icu68.patch b/app-text/calibre/files/calibre-4.22.0-icu68.patch new file mode 100644 index 000000000000..c4b3baf05703 --- /dev/null +++ b/app-text/calibre/files/calibre-4.22.0-icu68.patch @@ -0,0 +1,49 @@ +From c211f9b17af410463ce9cfc9b1b100228b51720f Mon Sep 17 00:00:00 2001 +From: Lars Wendler <polynomial-c@gentoo.org> +Date: Sat, 31 Oct 2020 10:44:36 +0100 +Subject: [PATCH] Fix build with icu-68.1 + +icu-68.1 removed public macro definitions for TRUE and FALSE + +Signed-off-by: Lars Wendler <polynomial-c@gentoo.org> +--- + src/calibre/utils/icu.c | 4 ++-- + src/calibre/utils/matcher.c | 1 - + 2 files changed, 2 insertions(+), 3 deletions(-) + +diff --git a/src/calibre/utils/icu.c b/src/calibre/utils/icu.c +index 62d05de310..4e918492d9 100644 +--- a/src/calibre/utils/icu.c ++++ b/src/calibre/utils/icu.c +@@ -238,14 +238,14 @@ icu_Collator_contains(icu_Collator *self, PyObject *args) { + + a = python_to_icu(a_, &asz); + if (a == NULL) goto end; +- if (asz == 0) { found = TRUE; goto end; } ++ if (asz == 0) { found = 1; goto end; } + b = python_to_icu(b_, &bsz); + if (b == NULL) goto end; + + search = usearch_openFromCollator(a, asz, b, bsz, self->collator, NULL, &status); + if (U_SUCCESS(status)) { + pos = usearch_first(search, &status); +- if (pos != USEARCH_DONE) found = TRUE; ++ if (pos != USEARCH_DONE) found = 1; + } + end: + if (search != NULL) usearch_close(search); +diff --git a/src/calibre/utils/matcher.c b/src/calibre/utils/matcher.c +index f38a7082ce..8e57947867 100644 +--- a/src/calibre/utils/matcher.c ++++ b/src/calibre/utils/matcher.c +@@ -15,7 +15,6 @@ + #define inline + #endif + +-typedef unsigned char bool; + #define TRUE 1 + #define FALSE 0 + #define MAX(x, y) ((x > y) ? x : y) +-- +2.29.2 + diff --git a/app-text/calibre/metadata.xml b/app-text/calibre/metadata.xml index 2196cbeb104f..c7f35ac2f858 100644 --- a/app-text/calibre/metadata.xml +++ b/app-text/calibre/metadata.xml @@ -2,9 +2,6 @@ <!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> <pkgmetadata> <maintainer type="person"> - <email>axs@gentoo.org</email> - </maintainer> - <maintainer type="person"> <email>zmedico@gentoo.org</email> </maintainer> <upstream> |