diff --git a/net/cjdns/Makefile b/net/cjdns/Makefile index d796f6e75a8b..71b31f5a14d6 100644 --- a/net/cjdns/Makefile +++ b/net/cjdns/Makefile @@ -1,42 +1,40 @@ # Created by: Yuri Victorovich PORTNAME= cjdns DISTVERSIONPREFIX= cjdns-v DISTVERSION= 21.1 CATEGORIES= net security MAINTAINER= yuri@FreeBSD.org COMMENT= Routing engine designed for security, scalability, speed LICENSE= GPLv3 LICENSE_FILE= ${WRKSRC}/LICENSE -BROKEN_powerpc64= fails to install: cjdns-cjdns-v20.3/cjdroute: No such file or directory - BUILD_DEPENDS= node:www/node \ bash:shells/bash USES= gmake python USE_GITHUB= yes GH_ACCOUNT= cjdelisle USE_RC_SUBR= cjdns SUB_FILES= cjdns pkg-message SUB_LIST= LOCALBASE=${LOCALBASE} PLIST_FILES= bin/cjdroute bin/run-cjdroute man/man5/cjdroute.conf.5.gz post-patch: @${REINPLACE_CMD} -i '' -e 's|/etc/|${LOCALBASE}/etc/|g' \ ${WRKSRC}/contrib/sh/run-cjdroute.sh do-build: @cd ${WRKSRC} && ./do do-install: ${INSTALL_PROGRAM} ${WRKSRC}/cjdroute ${STAGEDIR}${PREFIX}/bin ${INSTALL_SCRIPT} ${WRKSRC}/contrib/sh/run-cjdroute.sh ${STAGEDIR}${PREFIX}/bin/run-cjdroute ${INSTALL_MAN} ${WRKSRC}/doc/man/cjdroute.conf.5 ${STAGEDIR}${MANPREFIX}/man/man5 do-test: ${WRKSRC}/cjdroute --bench .include diff --git a/net/cjdns/files/patch-node__build_builder.js b/net/cjdns/files/patch-node__build_builder.js new file mode 100644 index 000000000000..e67ae0da7927 --- /dev/null +++ b/net/cjdns/files/patch-node__build_builder.js @@ -0,0 +1,11 @@ +--- node_build/builder.js.orig 2021-10-26 18:19:15 UTC ++++ node_build/builder.js +@@ -779,7 +779,7 @@ module.exports.configure = function ( + // if it returns undefined let's just assume 1 + // workaround, nodejs seems to be broken on openbsd (undefined result after second call) + const cpus = Os.cpus(); +- const jobs = Math.floor((typeof cpus === 'undefined' ? 1 : cpus.length) * 1.25); ++ const jobs = Math.floor((cpus == 0 ? 1 : cpus.length) * 1.25); + + const pctx /*:Builder_PreCtx_t*/ = { + buildStage: (_x,_y)=>{},