From e4d3fca2285b349318190a6e4cd3efda77cad28f Mon Sep 17 00:00:00 2001 From: Stefan Date: Fri, 13 Sep 2019 16:08:12 +0200 Subject: [PATCH 1/4] added termux-services to lnd --- packages/lnd/build.sh | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/packages/lnd/build.sh b/packages/lnd/build.sh index 328220c6c..cf25b6016 100644 --- a/packages/lnd/build.sh +++ b/packages/lnd/build.sh @@ -6,7 +6,7 @@ TERMUX_PKG_SRCURL=(https://github.com/lightningnetwork/lnd/releases/download/v$T https://github.com/lightningnetwork/lnd/releases/download/v$TERMUX_PKG_VERSION/vendor.tar.gz) TERMUX_PKG_SHA256=(ae8cb77eb7567ed9f8041a17eb6f65280cf81f4fbc3bf10eb671a423f62fc948 3bbfa000e2b4c7702f92d24235b5a098f37fd7b5830ca42586678f03d7cf9da3) -TERMUX_PKG_DEPENDS="bitcoin" +TERMUX_PKG_DEPENDS="bitcoin,termux-services" TERMUX_PKG_BUILD_IN_SRC=true termux_step_extract_package() { #modded without stripping @@ -58,3 +58,15 @@ termux_step_make() { termux_step_make_install() { install -Dm700 lnd lncli "$TERMUX_PREFIX"/bin/ } + +termux_step_post_make_install() { + mkdir -p $TERMUX_PREFIX/var/service + cd $TERMUX_PREFIX/var/service + mkdir -p lnd/log + echo "#!$TERMUX_PREFIX/bin/sh" > lnd/run + echo 'exec lnd 2>&1' >> lnd/run + chmod +x lnd/run + touch lnd/down + + ln -sf $TERMUX_PREFIX/share/termux-services/svlogger lnd/log/run +} From 0da84687b5b01cd381a2f77e814feb0880ab16a0 Mon Sep 17 00:00:00 2001 From: Stefan Date: Fri, 13 Sep 2019 16:43:14 +0200 Subject: [PATCH 2/4] removed termux-services dependency for bitcoin,lnd --- packages/bitcoin/build.sh | 2 +- packages/lnd/build.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/bitcoin/build.sh b/packages/bitcoin/build.sh index 4b1e335b7..ecd505f30 100644 --- a/packages/bitcoin/build.sh +++ b/packages/bitcoin/build.sh @@ -4,7 +4,7 @@ TERMUX_PKG_LICENSE="MIT" TERMUX_PKG_VERSION=0.18.1 TERMUX_PKG_SRCURL=https://github.com/bitcoin/bitcoin/archive/v$TERMUX_PKG_VERSION.tar.gz TERMUX_PKG_SHA256=db3c76ac913adfd67e3c7ff243b443c9706f81dd382d1212875fefc2de1ea5ff -TERMUX_PKG_DEPENDS="boost, libdb, libevent, libzmq, termux-services" +TERMUX_PKG_DEPENDS="boost, libdb, libevent, libzmq" TERMUX_PKG_BUILD_IN_SRC=true TERMUX_PKG_EXTRA_CONFIGURE_ARGS=" diff --git a/packages/lnd/build.sh b/packages/lnd/build.sh index cf25b6016..a4d1567e0 100644 --- a/packages/lnd/build.sh +++ b/packages/lnd/build.sh @@ -6,7 +6,7 @@ TERMUX_PKG_SRCURL=(https://github.com/lightningnetwork/lnd/releases/download/v$T https://github.com/lightningnetwork/lnd/releases/download/v$TERMUX_PKG_VERSION/vendor.tar.gz) TERMUX_PKG_SHA256=(ae8cb77eb7567ed9f8041a17eb6f65280cf81f4fbc3bf10eb671a423f62fc948 3bbfa000e2b4c7702f92d24235b5a098f37fd7b5830ca42586678f03d7cf9da3) -TERMUX_PKG_DEPENDS="bitcoin,termux-services" +TERMUX_PKG_DEPENDS="bitcoin" TERMUX_PKG_BUILD_IN_SRC=true termux_step_extract_package() { #modded without stripping From 168dfe699f824aec7e97b4ca4e6a3ac61b6de8ae Mon Sep 17 00:00:00 2001 From: Stefan Date: Fri, 13 Sep 2019 16:51:17 +0200 Subject: [PATCH 3/4] added conffiles to bitcoin,lnd --- packages/bitcoin/build.sh | 3 ++- packages/lnd/build.sh | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/bitcoin/build.sh b/packages/bitcoin/build.sh index ecd505f30..6243738d4 100644 --- a/packages/bitcoin/build.sh +++ b/packages/bitcoin/build.sh @@ -4,7 +4,8 @@ TERMUX_PKG_LICENSE="MIT" TERMUX_PKG_VERSION=0.18.1 TERMUX_PKG_SRCURL=https://github.com/bitcoin/bitcoin/archive/v$TERMUX_PKG_VERSION.tar.gz TERMUX_PKG_SHA256=db3c76ac913adfd67e3c7ff243b443c9706f81dd382d1212875fefc2de1ea5ff -TERMUX_PKG_DEPENDS="boost, libdb, libevent, libzmq" +TERMUX_PKG_DEPENDS="boost, libdb, libevent, libzmq +TERMUX_PKG_CONFFILES="var/service/bitcoind/run var/service/bitcoind/log/run"" TERMUX_PKG_BUILD_IN_SRC=true TERMUX_PKG_EXTRA_CONFIGURE_ARGS=" diff --git a/packages/lnd/build.sh b/packages/lnd/build.sh index a4d1567e0..06c50ac76 100644 --- a/packages/lnd/build.sh +++ b/packages/lnd/build.sh @@ -7,6 +7,7 @@ TERMUX_PKG_SRCURL=(https://github.com/lightningnetwork/lnd/releases/download/v$T TERMUX_PKG_SHA256=(ae8cb77eb7567ed9f8041a17eb6f65280cf81f4fbc3bf10eb671a423f62fc948 3bbfa000e2b4c7702f92d24235b5a098f37fd7b5830ca42586678f03d7cf9da3) TERMUX_PKG_DEPENDS="bitcoin" +TERMUX_PKG_CONFFILES="var/service/lnd/run var/service/lnd/log/run" TERMUX_PKG_BUILD_IN_SRC=true termux_step_extract_package() { #modded without stripping From 21d0d2f6276cf1a89bb9825cc1cadba2ea47d795 Mon Sep 17 00:00:00 2001 From: Henrik Grimler Date: Fri, 13 Sep 2019 17:14:15 +0200 Subject: [PATCH 4/4] bitcoin: fix typo --- packages/bitcoin/build.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/bitcoin/build.sh b/packages/bitcoin/build.sh index 6243738d4..ad7b13252 100644 --- a/packages/bitcoin/build.sh +++ b/packages/bitcoin/build.sh @@ -4,8 +4,8 @@ TERMUX_PKG_LICENSE="MIT" TERMUX_PKG_VERSION=0.18.1 TERMUX_PKG_SRCURL=https://github.com/bitcoin/bitcoin/archive/v$TERMUX_PKG_VERSION.tar.gz TERMUX_PKG_SHA256=db3c76ac913adfd67e3c7ff243b443c9706f81dd382d1212875fefc2de1ea5ff -TERMUX_PKG_DEPENDS="boost, libdb, libevent, libzmq -TERMUX_PKG_CONFFILES="var/service/bitcoind/run var/service/bitcoind/log/run"" +TERMUX_PKG_DEPENDS="boost, libdb, libevent, libzmq" +TERMUX_PKG_CONFFILES="var/service/bitcoind/run var/service/bitcoind/log/run" TERMUX_PKG_BUILD_IN_SRC=true TERMUX_PKG_EXTRA_CONFIGURE_ARGS="