summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Deutschmann <whissi@gentoo.org>2020-06-27 00:12:05 +0200
committerThomas Deutschmann <whissi@gentoo.org>2020-06-27 00:12:36 +0200
commit64a03158c6620085ccc0850bfc8c9c2d673cc402 (patch)
treec12665485cf7c4280093243e931fd1c3c9f92aea /net-nntp/sabnzbd
parentdev-perl/Compress-Bzip2: Bump to versoin 2.270.0 (diff)
downloadgentoo-64a03158c6620085ccc0850bfc8c9c2d673cc402.tar.gz
gentoo-64a03158c6620085ccc0850bfc8c9c2d673cc402.tar.bz2
gentoo-64a03158c6620085ccc0850bfc8c9c2d673cc402.zip
net-nntp/sabnzbd: bump to v3.0.0_rc1
Drop keywords for now until version was tested. Ebuild is still a draft. Package-Manager: Portage-2.3.101, Repoman-2.3.22 Signed-off-by: Thomas Deutschmann <whissi@gentoo.org>
Diffstat (limited to 'net-nntp/sabnzbd')
-rw-r--r--net-nntp/sabnzbd/Manifest1
-rw-r--r--net-nntp/sabnzbd/sabnzbd-3.0.0_rc1_pre0.ebuild125
2 files changed, 126 insertions, 0 deletions
diff --git a/net-nntp/sabnzbd/Manifest b/net-nntp/sabnzbd/Manifest
index 92e4571130df..74a6e591077d 100644
--- a/net-nntp/sabnzbd/Manifest
+++ b/net-nntp/sabnzbd/Manifest
@@ -1 +1,2 @@
DIST SABnzbd-2.3.9-src.tar.gz 2738773 BLAKE2B fbb765732c0aab6a47a4d4827d21b1b029c6d40c1c6c335692964210dc4c389e94cd1cdca45bfb3fb8c2fa9adc84f33df0fe3d23a0e4f9143a095eec042a5cf0 SHA512 10a39db9ad7f6d441166da97194b7a281aacd1900f7687bca72c6c2b555114bc2bbdaaba51cb9fcec57aa1b782f20609a07528484ad911ffd9f9eabb54a324fa
+DIST SABnzbd-3.0.0RC1-src.tar.gz 2762495 BLAKE2B 5b623e8cc141426459f3d62c3652df41559946a0fd691163428e7b10dfda5518e9701b1a250ed0a7cda6bfda705869ee6a038184ba8f86cfea70d9ea2d09d613 SHA512 00205b1cb4a74455fc48b0ce0579e6849d08b1cedb28ab01f53da8f37bd75268ced201c9e0510ffdf7b51eee6e666e73bec01f537e1ecbdb7f3f6115422b3074
diff --git a/net-nntp/sabnzbd/sabnzbd-3.0.0_rc1_pre0.ebuild b/net-nntp/sabnzbd/sabnzbd-3.0.0_rc1_pre0.ebuild
new file mode 100644
index 000000000000..634f3717c4fe
--- /dev/null
+++ b/net-nntp/sabnzbd/sabnzbd-3.0.0_rc1_pre0.ebuild
@@ -0,0 +1,125 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="7"
+
+# Require python-2 with sqlite USE flag
+PYTHON_COMPAT=( python3_{6..8} )
+PYTHON_REQ_USE="sqlite"
+
+inherit python-single-r1 user systemd
+
+MY_P="${P/sab/SAB}"
+MY_P="${MY_P/_rc/RC}"
+MY_P="${MY_P//_pre*}"
+
+MY_PV="${PV/_rc/RC}"
+
+DESCRIPTION="Binary newsgrabber with web-interface"
+HOMEPAGE="https://sabnzbd.org/"
+SRC_URI="https://github.com/sabnzbd/sabnzbd/releases/download/${MY_PV}/${MY_P}-src.tar.gz"
+
+# Sabnzbd is GPL-2 but bundles software with the following licenses.
+LICENSE="GPL-2 BSD LGPL-2 MIT BSD-1"
+SLOT="0"
+KEYWORDS=""
+IUSE="+7za +rar unzip"
+
+# Sabnzbd is installed to /usr/share/ as upstream makes it clear they should not
+# be in python's sitedir. See: https://sabnzbd.org/wiki/advanced/unix-packaging
+
+COMMON_DEPS="
+ ${PYTHON_DEPS}
+ $(python_gen_cond_dep '
+ dev-python/chardet[${PYTHON_MULTI_USEDEP}]
+ dev-python/cheetah3[${PYTHON_MULTI_USEDEP}]
+ dev-python/cherrypy[${PYTHON_MULTI_USEDEP}]
+ dev-python/configobj[${PYTHON_MULTI_USEDEP}]
+ dev-python/cryptography[${PYTHON_MULTI_USEDEP}]
+ dev-python/feedparser[${PYTHON_MULTI_USEDEP}]
+ dev-python/notify2[${PYTHON_MULTI_USEDEP}]
+ dev-python/portend[${PYTHON_MULTI_USEDEP}]
+ >=dev-python/sabyenc-3.3.1[${PYTHON_MULTI_USEDEP}]
+ ')
+"
+
+DEPEND="${COMMON_DEPS}"
+
+RDEPEND="
+ ${COMMON_DEPS}
+ >=app-arch/par2cmdline-0.4
+ net-misc/wget
+ 7za? ( app-arch/p7zip )
+ rar? ( || ( app-arch/unrar app-arch/rar ) )
+ unzip? ( >=app-arch/unzip-5.5.2 )
+"
+
+REQUIRED_USE="${PYTHON_REQUIRED_USE}"
+
+S="${WORKDIR}/${MY_P}"
+
+pkg_setup() {
+ MY_HOMEDIR="/var/lib/${PN}"
+ python-single-r1_pkg_setup
+
+ # Create sabnzbd group
+ enewgroup "${PN}"
+ # Create sabnzbd user, put in sabnzbd group
+ enewuser "${PN}" -1 -1 "${MY_HOMEDIR}" "${PN}"
+}
+
+src_install() {
+ local d
+
+ for d in email icons interfaces locale po sabnzbd scripts tools; do
+ insinto "/usr/share/${PN}/${d}"
+ doins -r ${d}/*
+ done
+
+ exeinto "/usr/share/${PN}"
+ doexe SABnzbd.py
+
+ python_fix_shebang "${ED}/usr/share/${PN}"
+ python_optimize "${ED}/usr/share/${PN}"
+
+ newinitd "${FILESDIR}/${PN}.initd" "${PN}"
+ newconfd "${FILESDIR}/${PN}.confd" "${PN}"
+
+ diropts -o "${PN}" -g "${PN}"
+ dodir "/etc/${PN}"
+ keepdir "/var/log/${PN}"
+
+ insinto "/etc/${PN}"
+ insopts -m 0600 -o "${PN}" -g "${PN}"
+ doins "${FILESDIR}/${PN}.ini"
+
+ dodoc {ABOUT,ISSUES}.txt README.mkd licenses/*
+
+ systemd_newunit "${FILESDIR}"/sabnzbd_at.service 'sabnzbd@.service'
+}
+
+pkg_postinst() {
+ if [[ -z "${REPLACING_VERSIONS}" ]]; then
+ # This is a new installation
+ einfo "Default directory: ${MY_HOMEDIR}"
+ einfo
+ einfo "To add a user to the sabnzbd group so it can edit SABnzbd+ files, run:"
+ einfo
+ einfo " gpasswd -a <user> sabnzbd"
+ einfo
+ einfo "By default, SABnzbd+ will listen on TCP port 8080."
+ fi
+
+ local v
+ for v in ${REPLACING_VERSIONS}; do
+ if ver_test "${v}" -lt 3; then
+ ewarn
+ ewarn "Due to changes in this release, the queue will be converted when ${PN}"
+ ewarn "is started for the first time. Job order, settings and data will be"
+ ewarn "preserved, but all jobs will be unpaused and URLs that did not finish"
+ ewarn "fetching before the upgrade will be lost!"
+ ewarn
+ break
+ fi
+ done
+}