summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Seifert <soap@gentoo.org>2021-06-18 12:04:48 +0200
committerSam James <sam@gentoo.org>2021-06-18 12:26:30 +0100
commit2d4a9bbe950fbbdc14cf7b19d86dbbd200b0bed5 (patch)
tree61416ccb4b939fb143a0164e253ff27c23699cbf /net-p2p
parentsys-kernel/vanilla-sources: Automated version bump to {5.4.127,5.10.45,5.12.1... (diff)
downloadgentoo-2d4a9bbe950fbbdc14cf7b19d86dbbd200b0bed5.tar.gz
gentoo-2d4a9bbe950fbbdc14cf7b19d86dbbd200b0bed5.tar.bz2
gentoo-2d4a9bbe950fbbdc14cf7b19d86dbbd200b0bed5.zip
net-p2p/litecoind: add 0.18.1
Closes: https://bugs.gentoo.org/607842 Bug: https://bugs.gentoo.org/672326 Bug: https://bugs.gentoo.org/768768 Bug: https://bugs.gentoo.org/788844 Signed-off-by: David Seifert <soap@gentoo.org> Closes: https://github.com/gentoo/gentoo/pull/21302 Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'net-p2p')
-rw-r--r--net-p2p/litecoind/Manifest1
-rw-r--r--net-p2p/litecoind/files/litecoind-0.18.1-system-leveldb.patch37
-rw-r--r--net-p2p/litecoind/litecoind-0.18.1.ebuild87
3 files changed, 125 insertions, 0 deletions
diff --git a/net-p2p/litecoind/Manifest b/net-p2p/litecoind/Manifest
index a9ff48ef9e72..d318bafd732f 100644
--- a/net-p2p/litecoind/Manifest
+++ b/net-p2p/litecoind/Manifest
@@ -1 +1,2 @@
DIST litecoin-0.10.4.0.tar.gz 4730189 BLAKE2B 3b3e4db10ca7ebb048853a424438d888a239cc736b1b2aa29dd0b6571daec5a64f95aee98a82991cd3e69b26965151f298655ca09745f103ebde1d15216ae2f8 SHA512 ae17e754d188efb1b51a376a52fe03e43b58c5059673b7dd4ecbf4f48574290b84011525fef2e10893f53e4da3d6ad9b5577001bb40aef7080d4c2479f4714a9
+DIST litecoin-0.18.1.tar.gz 5122629 BLAKE2B c6cb220bb893518eaf04e1b4b825dc0318103c955da6f262ef13fc9d925b7bae1bb0407a701a04a17bb3040c613b666e6de3331d443046e9d83aec4ed559e02e SHA512 59605cc0c4fd67c128bad0e2cabcc7b6bda1ebf5b23b7fcaee9fa69e86a4349598feba413f0ad42aef9338a42b0d6f8c04306634bd543856a2e7a203aa717f40
diff --git a/net-p2p/litecoind/files/litecoind-0.18.1-system-leveldb.patch b/net-p2p/litecoind/files/litecoind-0.18.1-system-leveldb.patch
new file mode 100644
index 000000000000..d00748a584fc
--- /dev/null
+++ b/net-p2p/litecoind/files/litecoind-0.18.1-system-leveldb.patch
@@ -0,0 +1,37 @@
+--- a/configure.ac
++++ b/configure.ac
+@@ -894,10 +894,22 @@
+ [AC_MSG_ERROR([Cannot set default symbol visibility. Use --disable-reduce-exports.])])
+ fi
+
++dnl Check for leveldb, only if explicitly requested
+ LEVELDB_CPPFLAGS=
+ LIBLEVELDB=
+ LIBMEMENV=
+-AM_CONDITIONAL([EMBEDDED_LEVELDB],[true])
++AC_ARG_WITH([system-leveldb],
++ [AS_HELP_STRING([--with-system-leveldb],
++ [Build with system LevelDB (default is no; DANGEROUS; NOT SUPPORTED)])],
++ [system_leveldb=$withval],
++ [system_leveldb=no]
++)
++if test x$system_leveldb != xno; then
++ LEVELDB_CPPFLAGS=
++ LIBLEVELDB=-lleveldb
++ LIBMEMENV=-lmemenv
++fi
++AM_CONDITIONAL([EMBEDDED_LEVELDB],[test x$system_leveldb = xno])
+ AC_SUBST(LEVELDB_CPPFLAGS)
+ AC_SUBST(LIBLEVELDB)
+ AC_SUBST(LIBMEMENV)
+--- a/src/dbwrapper.cpp
++++ b/src/dbwrapper.cpp
+@@ -10,7 +10,7 @@
+ #include <leveldb/cache.h>
+ #include <leveldb/env.h>
+ #include <leveldb/filter_policy.h>
+-#include <memenv.h>
++#include <leveldb/helpers/memenv.h>
+ #include <stdint.h>
+ #include <algorithm>
+
diff --git a/net-p2p/litecoind/litecoind-0.18.1.ebuild b/net-p2p/litecoind/litecoind-0.18.1.ebuild
new file mode 100644
index 000000000000..03ac46dc52de
--- /dev/null
+++ b/net-p2p/litecoind/litecoind-0.18.1.ebuild
@@ -0,0 +1,87 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+DB_VER="4.8"
+
+inherit autotools db-use flag-o-matic systemd
+
+MY_PV="${PV/_/-}"
+MY_PN="litecoin"
+MY_P="${MY_PN}-${MY_PV}"
+
+DESCRIPTION="The offical daemon to run your own (full) Litecoin node"
+HOMEPAGE="https://litecoin.org/"
+SRC_URI="https://github.com/${MY_PN}-project/${MY_PN}/archive/v${MY_PV}.tar.gz -> ${MY_P}.tar.gz"
+S="${WORKDIR}/${MY_P}"
+
+LICENSE="MIT ISC GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="cpu_flags_x86_sse2 upnp +wallet"
+
+RDEPEND="
+ acct-group/litecoin
+ acct-user/litecoin
+ dev-libs/boost:=[threads(+)]
+ dev-libs/leveldb:=
+ dev-libs/libevent:=[threads(+)]
+ dev-libs/openssl:=[-bindist(-)]
+ sys-libs/db:$(db_ver_to_slot ${DB_VER})[cxx]
+ upnp? ( net-libs/miniupnpc:= )"
+DEPEND="${RDEPEND}"
+
+PATCHES=( "${FILESDIR}"/${P}-system-leveldb.patch )
+
+src_prepare() {
+ default
+ rm -r src/leveldb || die
+ eautoreconf
+}
+
+src_configure() {
+ # To avoid executable GNU stack.
+ append-ldflags -Wl,-z,noexecstack
+
+ local myeconfargs=(
+ $(use_enable wallet)
+ $(use_with upnp miniupnpc)
+ $(use_enable upnp upnp-default)
+ $(use_enable cpu_flags_x86_sse2 sse2)
+ --disable-ccache
+ --disable-static
+ # tests are broken and segfault
+ --disable-tests
+ --with-system-leveldb
+ --without-libs
+ --with-daemon
+ --without-gui
+ --without-qrencode
+ )
+ econf "${myeconfargs[@]}"
+}
+
+src_install() {
+ default
+
+ insinto /etc/litecoin
+ doins "${FILESDIR}"/litecoin.conf
+ fowners litecoin:litecoin /etc/litecoin/litecoin.conf
+ fperms 600 /etc/litecoin/litecoin.conf
+
+ newconfd "${FILESDIR}"/litecoin.confd ${PN}
+ newinitd "${FILESDIR}"/litecoin.initd-r1 ${PN}
+ systemd_dounit "${FILESDIR}"/litecoin.service
+
+ keepdir /var/lib/litecoin/.litecoin
+ fperms 700 /var/lib/litecoin
+ fowners litecoin:litecoin /var/lib/litecoin/
+ fowners litecoin:litecoin /var/lib/litecoin/.litecoin
+ dosym /etc/litecoin/litecoin.conf /var/lib/litecoin/.litecoin/litecoin.conf
+
+ dodoc doc/README.md doc/release-notes.md
+
+ insinto /etc/logrotate.d
+ newins "${FILESDIR}"/litecoind.logrotate litecoind
+}