Initial import of ucspi-ipc, command-line tools for building

local-domain client-server applications. They conform to the UNIX
Client-Server Program Interface, UCSPI.

The ipcserver program listens for connections on a local-domain
stream socket, and runs a program for each connection it accepts. The
program environment includes variables that hold the local and remote
socket addresses, and the effective user and group IDs of the process
that called connect. ipcserver offers a concurrency limit on
acceptance of new connections, and selective handling of connections
based on client identity.

The ipcclient program requests a connection to a local-domain socket,
and runs a program. The program environment includes a variable that
holds the local socket address.

The ipcperl program is an example of an ipchandle server. It invokes a
perl subroutine for each request.
This commit is contained in:
schmonz 2020-11-18 15:18:39 +00:00
parent da6da51aee
commit 9b04382fb1
5 changed files with 101 additions and 0 deletions

18
net/ucspi-ipc/DESCR Normal file
View file

@ -0,0 +1,18 @@
The ipcserver and ipcclient programs are command-line tools for building
local-domain client-server applications. They conform to the UNIX
Client-Server Program Interface, UCSPI.
The ipcserver program listens for connections on a local-domain
stream socket, and runs a program for each connection it accepts. The
program environment includes variables that hold the local and remote
socket addresses, and the effective user and group IDs of the process
that called connect. ipcserver offers a concurrency limit on
acceptance of new connections, and selective handling of connections
based on client identity.
The ipcclient program requests a connection to a local-domain socket,
and runs a program. The program environment includes a variable that
holds the local socket address.
The ipcperl program is an example of an ipchandle server. It invokes a
perl subroutine for each request.

40
net/ucspi-ipc/Makefile Normal file
View file

@ -0,0 +1,40 @@
# $NetBSD: Makefile,v 1.1 2020/11/18 15:18:39 schmonz Exp $
DISTNAME= ucspi-ipc-0.67
CATEGORIES= net sysutils
MASTER_SITES= ${HOMEPAGE}
MAINTAINER= schmonz@NetBSD.org
HOMEPAGE= http://www.superscript.com/ucspi-ipc/
COMMENT= UCSPI local-domain client-server command-line tools
WRKSRC= ${WRKDIR}/host/superscript.com/net/${DISTNAME}
DJB_SLASHPACKAGE= yes
DJB_RESTRICTED= no
BUILD_DEFS+= VARBASE
DJB_CONFIG_CMDS= \
${ECHO} ${VARBASE}/service/ipcexec > conf-ipcexec; \
${ECHO} it-base > it=d;
INSTALLATION_DIRS= bin
.include "options.mk"
do-test:
cd ${WRKSRC}; \
./package/rts
do-install: do-install-ipcperl
for f in ipccat ipcconnect ipcdo ipcrun; do \
${INSTALL_SCRIPT} ${WRKSRC}/command/$$f ${DESTDIR}${PREFIX}/bin; \
done
for f in ipcclient ipccommand ipcconnect-io ipcexec ipcexec-config \
ipcexecrules ipcexecrulescheck \
ipcrules ipcrulescheck ipcserver; do \
${INSTALL_PROGRAM} ${WRKSRC}/command/$$f ${DESTDIR}${PREFIX}/bin; \
done
.include "../../mk/djbware.mk"
.include "../../mk/bsd.pkg.mk"

16
net/ucspi-ipc/PLIST Normal file
View file

@ -0,0 +1,16 @@
@comment $NetBSD: PLIST,v 1.1 2020/11/18 15:18:39 schmonz Exp $
bin/ipccat
bin/ipcclient
bin/ipccommand
bin/ipcconnect
bin/ipcconnect-io
bin/ipcdo
bin/ipcexec
bin/ipcexec-config
bin/ipcexecrules
bin/ipcexecrulescheck
${PLIST.perl}bin/ipcperl
bin/ipcrules
bin/ipcrulescheck
bin/ipcrun
bin/ipcserver

6
net/ucspi-ipc/distinfo Normal file
View file

@ -0,0 +1,6 @@
$NetBSD: distinfo,v 1.1 2020/11/18 15:18:39 schmonz Exp $
SHA1 (ucspi-ipc-0.67.tar.gz) = 5f53c5fa487f4baa46eb071f40117454ee1eeef8
RMD160 (ucspi-ipc-0.67.tar.gz) = a79b68dbfdf16cc15232f97e8339d0e874a6e1a6
SHA512 (ucspi-ipc-0.67.tar.gz) = 4836d4e3fa7896bc218099c7b0092385a448ae6151cc277bc8bab140ab1447b155bd0673647aec147f4fd8b4d8e2c43042fd57e83df9a55fea06c0cb9cd104e4
Size (ucspi-ipc-0.67.tar.gz) = 51281 bytes

21
net/ucspi-ipc/options.mk Normal file
View file

@ -0,0 +1,21 @@
# $NetBSD: options.mk,v 1.1 2020/11/18 15:18:39 schmonz Exp $
PKG_OPTIONS_VAR= PKG_OPTIONS.ucspi-ipc
PKG_SUPPORTED_OPTIONS+= perl
.include "../../mk/bsd.options.mk"
PLIST_VARS+= perl
.PHONY: do-install-ipcperl
.if !empty(PKG_OPTIONS:Mperl)
.include "../../lang/perl5/buildlink3.mk"
USE_TOOLS+= perl:run
DJB_CONFIG_CMDS+= ${ECHO} ${PERL5} > conf-perl; \
${ECHO} it-ipcperl >> it=d;
PLIST.perl= yes
do-install-ipcperl:
${INSTALL_PROGRAM} ${WRKSRC}/command/ipcperl ${DESTDIR}${PREFIX}/bin
.else
do-install-ipcperl:
${DO_NADA}
.endif