From 9b3e3c68372882d1d7da99503775e4b46b7f8427 Mon Sep 17 00:00:00 2001 From: "Robin H. Johnson" Date: Sun, 16 Jun 2019 11:18:29 -0700 Subject: [PATCH] app-misc/dnetc: bump, now with EAPI7 Fixes: https://bugs.gentoo.org/675228 Package-Manager: Portage-2.3.67, Repoman-2.3.12 Signed-off-by: Robin H. Johnson --- app-misc/dnetc/Manifest | 4 + app-misc/dnetc/dnetc-2.9112.521.ebuild | 100 +++++++++++++++++++++++++ 2 files changed, 104 insertions(+) create mode 100644 app-misc/dnetc/dnetc-2.9112.521.ebuild diff --git a/app-misc/dnetc/Manifest b/app-misc/dnetc/Manifest index 6c0d5efac99c..0e37477cf77c 100644 --- a/app-misc/dnetc/Manifest +++ b/app-misc/dnetc/Manifest @@ -1,3 +1,7 @@ DIST dnetc517-linux-amd64.tar.gz 645416 BLAKE2B a6181c82e7bdb8995930b3c93c88dd588f707ea6429e4f7f27961928129423be571f0c63e7aa5d5d9a8e5e3687a8bd54e6dc6835f5317273aa3f99ee863e8320 SHA512 b22b59af2352a95156ea4b584f48d82e4b64080130d922bbb1797b2c62f7c401ec1263f2f0bd57103134f8fc76ef41a7e09d7da083ef0b46c44be4239005c21b DIST dnetc517-linux-x86-elf-uclibc.tar.gz 676398 BLAKE2B 9edfa3f11b837841b362dd81bdd9a39882b6bd45942f11f6c8ebde4966351a0ea4c003eb27a36c2fe187034571d48a5d851d5931dc6121196f2097a22f9a1c30 SHA512 7b56fa8c6819fd7060612c13c8fb17ca1e949abbca965b7599bb072751acd1d0e95f1a90fb67172c6d406b54e0c52549582489802e538670bdb6d12f8354e2a7 DIST dnetc519b-linux-amd64.tar.gz 648333 BLAKE2B 54d787d5e9a98563bba1a0cc62f70900f0fa39becf6f48a66ae888e0ce0f1f2c64a79fc6c6b3fae724ed244e3f0286dc0f266332d851347b982bffcd1807696f SHA512 ea7899772ee8c5fbfbe96b6ec69b1a3237fe5ae96b17bb7e11e387fb833b471f3cce8809cf3c9987dfe33c7ca7082db560c36898094ace3e547077b7a5afc324 +DIST dnetc521-linux-amd64.tar.gz 679350 BLAKE2B 401b83a893111a4b2d07ace93fc642b30ccd41a0273672e496b91d998ce6d38faa08a7ec13ca172d20bf785d010249b87c562b706783c6d3fe3610ef02b214ed SHA512 c5c4d6da4fd1cb6a648553718e708c8d14023d1824298f8070cdc887cbf9559e77c10908d8d9929bc0b48e2215a02c3376c4cf767ad807816abf3eba96650b1d +DIST dnetc521-linux-arm64.tar.gz 629291 BLAKE2B 12554db6c175b828e9e74864955db7e6f54b21408edc6b32a669d52d17465ed45d7985486855a330b295778656579582f208c0e5ecc34f6a2ea195c2ab1fab68 SHA512 cc9c8b76b9d3ada1ed586132c3cc340d2ada55a28d151fb62013aac44dbf13b764dd80498bce1db36536df366497cdc2aa55e761d92cfdd050b701a23336ad80 +DIST dnetc521-linux-ppc-uclibc.tar.gz 718697 BLAKE2B 15f8438531b8074c8a56b86500c55b95eb33c62e4271023bab98601fadd3bc3d2afd1ae8562cadf8d724943515032c97a78084ddd12ef30c388456333ec60893 SHA512 31ad8999d262f0820275773f3387b0a9531ffaab662fa557cad504ed48d7e764d43ae198559b44ef9fe00a0a417e1780b327d2f1c4b7951ff760eb54393742e4 +DIST dnetc521-linux-x86-elf-uclibc.tar.gz 744639 BLAKE2B 71a317c724b91f17c1e67da63d5da2e04479572c6e8c9e9df16c9a0cf5f1d56622a7d20bd791f46b7baa3147fd18c60c312b16cc311bad2e609945620a843f16 SHA512 9178b0d42989302b82d8c62f978e819f5b30bd6acff60501e947038e655096bed3e3382015b50d53f0f3fa819be22ffbba21419a5175a01dbc449030387629fc diff --git a/app-misc/dnetc/dnetc-2.9112.521.ebuild b/app-misc/dnetc/dnetc-2.9112.521.ebuild new file mode 100644 index 000000000000..712ecc12ec4e --- /dev/null +++ b/app-misc/dnetc/dnetc-2.9112.521.ebuild @@ -0,0 +1,100 @@ +# Copyright 1999-2019 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 +inherit user + +MAJ_PV=${PV:0:6} +MIN_PV=${PV:7:9} + +DESCRIPTION="distributed.net client" +HOMEPAGE="http://www.distributed.net" +SRC_URI_BASE="http://http.distributed.net/pub/dcti/v${MAJ_PV}" +SRC_URI_x86="x86? ( ${SRC_URI_BASE}/dnetc${MIN_PV}-linux-x86-elf-uclibc.tar.gz )" +SRC_URI_arm64="arm64? ( ${SRC_URI_BASE}/dnetc${MIN_PV}-linux-arm64.tar.gz )" +SRC_URI_amd64="amd64? ( ${SRC_URI_BASE}/dnetc${MIN_PV}-linux-amd64.tar.gz )" +SRC_URI_ppc="ppc? ( ${SRC_URI_BASE}/dnetc${MIN_PV}-linux-ppc-uclibc.tar.gz )" +#SRC_URI_sparc="sparc? ( ${SRC_URI_BASE}/dnetc${MIN_PV}-linux-sparc-v7.tar.gz )" +SRC_URI="${SRC_URI_amd64} ${SRC_URI_arm64} ${SRC_URI_ppc} ${SRC_URI_x86} ${SRC_URI_sparc}" + +LICENSE="distributed.net GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~arm64 ~ppc ~x86" # sparc not available for this version +IUSE="" +RESTRICT="mirror" + +DEPEND="" +RDEPEND="net-dns/bind-tools" + +QA_PREBUILT="opt/distributed.net/dnetc" + +case $ARCH in + amd64) suffix=amd64 ;; + arm64) suffix=amd64 ;; + ppc) suffix=ppc-elf-uclibc ;; + x86) suffix=x86-elf-uclibc ;; +esac +S="${WORKDIR}/dnetc${MIN_PV:0:3}-linux-${suffix}" +unset suffix + +src_prepare() { + #export S="${WORKDIR}/$(getS)" + #echo "${S}" + #cd "${S}" + [[ -x dnetc ]] || die "Name of dnetc directory/binary for this platform undefined" + eapply_user +} + +src_install() { + exeinto /opt/distributed.net + doexe dnetc + + doman dnetc.1 + dodoc docs/CHANGES.txt docs/dnetc.txt docs/readme.* + + newinitd "${FILESDIR}"/dnetc.initd dnetc + newconfd "${FILESDIR}"/dnetc.confd dnetc + + keepdir /var/spool/dnetc +} + +pkg_preinst() { + # This is the upstream-recommended install process + # Flush buffers first, because the new binary might not be able to read + # them. + if [ -e /opt/distributed.net/dnetc ] && [ -e /etc/init.d/dnetc ]; then + einfo "flushing old buffers" + source /etc/conf.d/dnetc + + if [ -e /opt/distributed.net/dnetc.ini ]; then + # use ini file + /opt/distributed.net/dnetc -quiet -ini /opt/distributed.net/dnetc.ini -flush + elif [ ! -e /opt/distributed.net/dnetc.ini ] && [ ! -z ${EMAIL} ]; then + # email adress from config + /opt/distributed.net/dnetc -quiet -flush -e ${EMAIL} + fi + + einfo "removing old buffer files" + rm -f /opt/distributed.net/buff* + fi + + enewgroup dnetc + enewuser dnetc -1 -1 /opt/distributed.net dnetc +} + +pkg_postinst() { + chown -Rf dnetc:dnetc /opt/distributed.net + chmod 0555 /opt/distributed.net/dnetc + + elog "To run distributed.net client in the background at boot:" + elog " rc-update add dnetc default" + elog "" + elog "Either configure your email address in /etc/conf.d/dnetc" + elog "or create the configuration file /opt/distributed.net/dnetc.ini" +} + +pkg_postrm() { + if [ -d /opt/distributed.net ]; then + elog "All files has not been removed from /opt/distributed.net" + fi +} -- 2.26.2