summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.SRCINFO35
-rw-r--r--PKGBUILD71
-rw-r--r--peercoin-qt.desktop10
-rw-r--r--peercoin-qt@.service21
-rw-r--r--peercoin.install11
-rw-r--r--ppcoind@.service18
-rw-r--r--upnp-1.9.patch19
7 files changed, 185 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 00000000000..d8119e6532b
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,35 @@
+# Generated by mksrcinfo v8
+# Mon Feb 29 20:05:19 UTC 2016
+pkgbase = peercoin
+ pkgdesc = Peercoin wallet client.
+ pkgver = 0.4.2
+ pkgrel = 1
+ url = peercoin.net
+ arch = x86_64
+ arch = i686
+ license = MIT
+ source = https://github.com/ppcoin/ppcoin/archive/v0.4.2ppc.tar.gz
+ source = peercoin-qt.desktop
+ source = upnp-1.9.patch
+ source = peercoin-qt@.service
+ source = ppcoind@.service
+ sha256sums = d1217b40f8b9933b4e824eb4a6f9bfefce6e793f3cafdcf32420c9d7b7049125
+ sha256sums = 6cb18e19847bbf4066920dbbf4371ddf07409392408fc6d079487e8759ea322e
+ sha256sums = 3060917f8e327002da842534265392a1849239ec5049f25c1ae8a81c3952e7b1
+ sha256sums = 28d80670d836c57ffa38729508649afbe05338dc92c89a44c64230a7ebd97eae
+ sha256sums = 5123ec91ad8b304f46c53f49b52ffd1e41c66c3df40c23209128ce2761f7c079
+
+pkgname = peercoin-qt
+ pkgdesc = Official implementation of Peercoin, the sustainable and secure cryptocurrency alternative to Bitcoin - QT wallet.
+ install = peercoin.install
+ depends = qt4
+ depends = miniupnpc
+ depends = boost-libs
+ depends = qrencode
+ depends = miniupnpc
+
+pkgname = ppcoind
+ pkgdesc = Official implementation of Peercoin, the sustainable and secure cryptocurrency alternative to Bitcoin - daemon.
+ depends = boost-libs
+ depends = miniupnpc
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..d197428586b
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,71 @@
+## Maintainer: peerchemist <peerchemist@protonmail.ch>
+
+pkgname=('peercoin-qt' 'ppcoind')
+pkgbase=peercoin
+pkgver=0.4.2
+pkgrel=1
+pkgdesc="Peercoin wallet client."
+arch=('x86_64' 'i686')
+url='peercoin.net'
+license=('MIT')
+source=(https://github.com/ppcoin/ppcoin/archive/v${pkgver}ppc.tar.gz
+ peercoin-qt.desktop
+ upnp-1.9.patch
+ peercoin-qt@.service
+ ppcoind@.service)
+sha256sums=('d1217b40f8b9933b4e824eb4a6f9bfefce6e793f3cafdcf32420c9d7b7049125'
+ '6cb18e19847bbf4066920dbbf4371ddf07409392408fc6d079487e8759ea322e'
+ '3060917f8e327002da842534265392a1849239ec5049f25c1ae8a81c3952e7b1'
+ '28d80670d836c57ffa38729508649afbe05338dc92c89a44c64230a7ebd97eae'
+ '5123ec91ad8b304f46c53f49b52ffd1e41c66c3df40c23209128ce2761f7c079')
+
+prepare() {
+ cd "$srcdir/peercoin-${pkgver}ppc"
+ patch -p1 -i ../upnp-1.9.patch
+}
+
+build() {
+ cd "$srcdir/ppcoin-${pkgver}ppc"
+
+ ## make qt gui
+ qmake-qt4 USE_QRCODE=1 USE_UPNP=1 USE_SSL=1 \
+ QMAKE_CFLAGS="${CFLAGS}"\
+ QMAKE_CXXFLAGS="${CXXFLAGS} -pie"
+ make
+
+ ## make ppcoind
+ #cd "$srcdir/peercoin"
+ make -f makefile.unix USE_UPNP=1 USE_SSL=1 -e PIE=1 -C src
+}
+
+package_peercoin-qt() {
+
+ pkgdesc="Official implementation of Peercoin, the sustainable and secure cryptocurrency alternative to Bitcoin - QT wallet."
+ makedepends=('qt4' 'boost' 'gcc' 'make' 'qrencode' 'openssl' 'miniupnpc')
+ depends=('qt4' 'miniupnpc' 'boost-libs' 'qrencode' 'miniupnpc')
+ optdepeds=('systemd')
+ install=peercoin.install
+
+ install -Dm644 ${pkgname}.desktop "${pkgdir}/usr/share/applications/${pkgname}.desktop"
+ install -Dm644 peercoin-qt@.service "${pkgdir}/usr/lib/systemd/system/peercoin-qt@.service"
+
+ cd "$srcdir/peercoin-${pkgver}ppc"
+ install -Dm755 ppcoin-qt "${pkgdir}/usr/bin/peercoin-qt"
+ #install -Dm644 COPYING "${pkgdir}/usr/share/licenses/peercoin/COPYING"
+ install -Dm644 "src/qt/res/icons/ppcoin.png" "${pkgdir}/usr/share/pixmaps/peercoin.png"
+
+}
+
+package_ppcoind() {
+
+ makedepends=('boost' 'gcc' 'make' 'openssl' 'miniupnpc')
+ depends=('boost-libs' 'miniupnpc')
+ optdepeneds=('systemd')
+ pkgdesc="Official implementation of Peercoin, the sustainable and secure cryptocurrency alternative to Bitcoin - daemon."
+
+ install -Dm644 ppcoind@.service "$pkgdir/usr/lib/systemd/system/ppcoind@.service"
+ install -Dm644 "$srcdir/peercoin-${pkgver}ppc/COPYING" "$pkgdir/usr/share/licenses/peercoin/COPYING"
+
+ cd "$srcdir/peercoin-${pkgver}ppc"
+ install -Dm755 "src/ppcoind" "$pkgdir/usr/bin/ppcoind"
+}
diff --git a/peercoin-qt.desktop b/peercoin-qt.desktop
new file mode 100644
index 00000000000..9b6f4802db9
--- /dev/null
+++ b/peercoin-qt.desktop
@@ -0,0 +1,10 @@
+[Desktop Entry]
+Encoding=UTF-8
+Name=Peercoin
+Comment=Core wallet for Peercoin P2P Cryptocurrency
+Exec=/usr/bin/peercoin-qt
+Terminal=false
+Type=Application
+Icon=/usr/share/pixmaps/peercoin.png
+MimeType=x-scheme-handler/peercoin;
+Categories=Application;Network;
diff --git a/peercoin-qt@.service b/peercoin-qt@.service
new file mode 100644
index 00000000000..7a87aef20e2
--- /dev/null
+++ b/peercoin-qt@.service
@@ -0,0 +1,21 @@
+[Unit]
+Description=Peercoin-qt
+After=network.target
+After=graphical.target
+
+[Service]
+User=%i
+Group=users
+Type=simple
+Restart=on-failure
+Environment=DISPLAY=:0
+Environment=XAUTHORITY=%h/.Xauthority
+ExecStart=/usr/bin/ppcoin-qt
+## security
+PrivateTmp=true
+PrivateDevices=true
+ProtectSystem=full
+NoNewPrivileges=true
+
+[Install]
+WantedBy=default.target
diff --git a/peercoin.install b/peercoin.install
new file mode 100644
index 00000000000..f98ba733893
--- /dev/null
+++ b/peercoin.install
@@ -0,0 +1,11 @@
+post_install() {
+ update-desktop-database -q
+}
+
+post_upgrade() {
+ post_install $1
+}
+
+post_remove() {
+ post_install $1
+}
diff --git a/ppcoind@.service b/ppcoind@.service
new file mode 100644
index 00000000000..a6e65c84b9d
--- /dev/null
+++ b/ppcoind@.service
@@ -0,0 +1,18 @@
+[Unit]
+Description=Peercoin Daemon
+After=network.target
+
+[Service]
+User=%i
+Group=users
+Type=simple
+Restart=on-failure
+ExecStart=/usr/bin/ppcoind
+## security
+PrivateTmp=true
+PrivateDevices=true
+ProtectSystem=full
+NoNewPrivileges=true
+
+[Install]
+WantedBy=default.target
diff --git a/upnp-1.9.patch b/upnp-1.9.patch
new file mode 100644
index 00000000000..42e6cf18e8d
--- /dev/null
+++ b/upnp-1.9.patch
@@ -0,0 +1,19 @@
+diff -Naur a/src/net.cpp b/src/net.cpp
+--- a/src/net.cpp 2015-06-15 10:51:30.000000000 +0200
++++ b/src/net.cpp 2015-10-03 16:15:10.441886309 +0200
+@@ -1020,10 +1020,14 @@
+ #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;