diff options
-rw-r--r-- | .SRCINFO | 23 | ||||
-rw-r--r-- | PKGBUILD | 48 | ||||
-rw-r--r-- | boost.patch | 31 |
3 files changed, 102 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..79d33f07f57d --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,23 @@ +pkgbase = curecoind-git + pkgdesc = GUI client (wallet) for CureCoin cryptocurrency + pkgver = v2.0.0.1.r1.gb307e32 + pkgrel = 1 + url = https://curecoin.net/ + arch = x86_64 + arch = i686 + license = MIT + makedepends = boost + makedepends = db + makedepends = git + depends = miniupnpc + depends = boost-libs + depends = openssl-1.0 + provides = curecoind + conflicts = curecoind + source = git+https://github.com/cygnusxi/CurecoinSource.git#branch=master + source = boost.patch + sha256sums = SKIP + sha256sums = 3a984b6236e60cd34d31f24935e4c8cc92b5b725bd2f4159b8de375b3e0bb77a + +pkgname = curecoind-git + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..6f643a3d1122 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,48 @@ +# Maintainer: Dmitry Kharitonov <darksab0r at gmail com> +# Contributor: Michael Thalmeier <michael@thalmeier.at> + +pkgname=curecoind-git +pkgver=v2.0.0.1.r1.gb307e32 +pkgrel=1 +pkgdesc="GUI client (wallet) for CureCoin cryptocurrency" +arch=('x86_64' 'i686') +url="https://curecoin.net/" +license=('MIT') +provides=('curecoind') +conflicts=('curecoind') +depends=('miniupnpc' 'boost-libs' 'openssl-1.0') +makedepends=('boost' 'db' 'git') +source=("git+https://github.com/cygnusxi/CurecoinSource.git#branch=master" + "boost.patch") + +sha256sums=('SKIP' + '3a984b6236e60cd34d31f24935e4c8cc92b5b725bd2f4159b8de375b3e0bb77a') + +pkgver() { + cd ${srcdir}/CurecoinSource + set -o pipefail + git describe --tags --long | sed -r 's/([^-]*-g)/r\1/;s/-/./g' || + printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)" +} + +prepare() { + cd "${srcdir}/CurecoinSource" + # Fix compilation error with miniupnpc v 1.9 and new boost + patch -p1 <"${srcdir}/boost.patch" + + #cd "${srcdir}/CurecoinSource/src" + # Switch to OpenSSL 1.0 + #echo "INCLUDEPATH += /usr/include/openssl-1.0" >> "makefile.unix" + #echo "LIBS += -L/usr/lib/openssl-1.0 -lcrypto -lz" >> "makefile.unix" +} + +build() { + cd "${srcdir}/CurecoinSource/src" + make -f makefile.unix OPENSSL_INCLUDE_PATH='/usr/include/openssl-1.0' OPENSSL_LIB_PATH='/usr/lib/openssl-1.0 -lcrypto -lz' ${MAKEFLAGS} +} + +package() { + cd "${srcdir}/CurecoinSource" + install -Dm755 "${srcdir}/CurecoinSource/src/curecoind" "${pkgdir}/usr/bin/curecoind" + install -Dm644 COPYING "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE" +} diff --git a/boost.patch b/boost.patch new file mode 100644 index 000000000000..35406b23763a --- /dev/null +++ b/boost.patch @@ -0,0 +1,31 @@ +diff --git a/src/makefile.unix b/src/makefile.unix +index 350f40c..57c6f9a 100644 +--- a/src/makefile.unix ++++ b/src/makefile.unix +@@ -7,7 +7,7 @@ USE_IPV6:=1 + + LINK:=$(CXX) + +-DEFS=-DBOOST_SPIRIT_THREADSAFE ++DEFS=-DBOOST_SPIRIT_THREADSAFE -DBOOST_ASIO_ENABLE_OLD_SERVICES + + DEFS += $(addprefix -I,$(CURDIR) $(CURDIR)/obj $(BOOST_INCLUDE_PATH) $(BDB_INCLUDE_PATH) $(OPENSSL_INCLUDE_PATH)) + LIBS = $(addprefix -L,$(BOOST_LIB_PATH) $(BDB_LIB_PATH) $(OPENSSL_LIB_PATH)) +--- a/src/net.cpp ++++ b/src/net.cpp +@@ -1031,10 +1031,14 @@ void ThreadMapPort2(void* parg) + #ifndef UPNPDISCOVER_SUCCESS + /* miniupnpc 1.5 */ + devlist = upnpDiscover(2000, multicastif, minissdpdpath, 0); +-#else ++#elif MINIUPNPC_API_VERSION < 14 + /* miniupnpc 1.6 */ + int error = 0; + devlist = upnpDiscover(2000, multicastif, minissdpdpath, 0, 0, &error); ++#else ++ /* miniupnpc 1.9.20150730 */ ++ int error = 0; ++ devlist = upnpDiscover(2000, multicastif, minissdpdpath, 0, 0, 2, &error); + #endif + + struct UPNPUrls urls; |