diff options
author | Gleb Popov <arrowd@FreeBSD.org> | 2023-04-08 18:10:52 +0000 |
---|---|---|
committer | Gleb Popov <arrowd@FreeBSD.org> | 2023-04-08 18:21:43 +0000 |
commit | fffb8ca3cfe00c098d4870c7b7ba00e92dbc059b (patch) | |
tree | 270835bf8386d6fb82871e3a6823e97d16c84dd1 | |
parent | c6a4b634d7d4457572f9b5fcd9a866dfb2fb43d1 (diff) | |
download | ports-fffb8ca3cfe00c098d4870c7b7ba00e92dbc059b.tar.gz ports-fffb8ca3cfe00c098d4870c7b7ba00e92dbc059b.zip |
net-p2p/cardano-node: Fix "reload" command of the rc script.
While there enable LTO for this port, as it benefits greatly from this
optimization. It was reported to run without issues with LTO.
Reported by: Boris Polujin <boris@zfs.ninja>
(cherry picked from commit f23cd3d99022696882e4ff7c68091037b36aa4f3)
-rw-r--r-- | net-p2p/cardano-node/Makefile | 3 | ||||
-rwxr-xr-x | net-p2p/cardano-node/files/cardano_node.in | 4 |
2 files changed, 6 insertions, 1 deletions
diff --git a/net-p2p/cardano-node/Makefile b/net-p2p/cardano-node/Makefile index 680990d785b1..881263e8c1f9 100644 --- a/net-p2p/cardano-node/Makefile +++ b/net-p2p/cardano-node/Makefile @@ -1,5 +1,6 @@ PORTNAME= cardano-node PORTVERSION= 1.35.7 +PORTREVISION= 1 CATEGORIES= net-p2p MASTER_SITES= https://input-output-hk.github.io/cardano-haskell-packages/package/:chap @@ -443,6 +444,8 @@ CABAL_PROJECT= append CABAL_EXECUTABLES= cardano-node cardano-cli cardano-submit-api cardano-tracer CABAL_REPOSITORIES= chap +WITH_LTO= yes + post-patch: ${REINPLACE_CMD} -e 's/$$(gitRevFromGit)/"${CARDANO_NODE_HASH}"/' \ -e '/Cardano.Git.RevFromGit/d' \ diff --git a/net-p2p/cardano-node/files/cardano_node.in b/net-p2p/cardano-node/files/cardano_node.in index df010e544630..1b9a59443e2e 100755 --- a/net-p2p/cardano-node/files/cardano_node.in +++ b/net-p2p/cardano-node/files/cardano_node.in @@ -159,6 +159,7 @@ if checkyesno "_jail_enable"; then _socket_arg="${jail_socket}" _topology_arg="${jail_topology}" _config_arg="${jail_config}" + _db_arg="/db" # We need to override ${command} to make check_pidfile work correctly when # rc.subr calls it as "check_pidfile ${pidfile} ${command}" command=/usr/sbin/jail @@ -166,11 +167,12 @@ else _socket_arg="${_socket}" _topology_arg="${_topology}" _config_arg="${_config}" + _db_arg="${_db}" fi pidfile="/var/run/${name}.pid" flags="run +RTS ${_rts_flags} -RTS \ - --database-path /db \ + --database-path ${_db_arg} \ --host-addr ${_host} \ --port ${_port} \ --socket-path ${_socket_arg} \ |