misc/nq: import nq-0.5 from wip.

These small utilities allow creating very lightweight job queue systems
which require no setup, maintenance, supervision, or any long-running
processes.

The intended purpose is ad-hoc queuing of command lines (e.g. for building
several targets of a Makefile, downloading multiple files one at a time,
running benchmarks in several configurations, or simply as a glorified
`nohup`), but as any good Unix tool, it can be abused for whatever you like.
This commit is contained in:
vins 2023-08-26 10:54:11 +00:00
parent 8cb582560f
commit 15cedb118b
5 changed files with 84 additions and 0 deletions

8
misc/nq/DESCR Normal file
View File

@ -0,0 +1,8 @@
These small utilities allow creating very lightweight job queue systems
which require no setup, maintenance, supervision, or any long-running
processes.
The intended purpose is ad-hoc queuing of command lines (e.g. for building
several targets of a Makefile, downloading multiple files one at a time,
running benchmarks in several configurations, or simply as a glorified
`nohup`), but as any good Unix tool, it can be abused for whatever you like.

21
misc/nq/Makefile Normal file
View File

@ -0,0 +1,21 @@
# $NetBSD: Makefile,v 1.1 2023/08/26 10:54:11 vins Exp $
DISTNAME= nq-0.5
CATEGORIES= misc sysutils
MASTER_SITES= https://git.vuxu.org/nq/snapshot/
MAINTAINER= pkgsrc-users@NetBSD.org
HOMEPAGE= https://git.vuxu.org/nq/about/
COMMENT= Command line queueing utility
LICENSE= public-domain
USE_TOOLS+= perl:test
REPLACE_SH= tq
TEST_TARGET= check
MAKE_FLAGS+= PREFIX=${PREFIX}
MAKE_FLAGS+= MANDIR=${PREFIX}/${PKGMANDIR}
.include "../../mk/bsd.pkg.mk"

7
misc/nq/PLIST Normal file
View File

@ -0,0 +1,7 @@
@comment $NetBSD: PLIST,v 1.1 2023/08/26 10:54:11 vins Exp $
bin/fq
bin/nq
bin/tq
man/man1/fq
man/man1/nq
man/man1/tq

6
misc/nq/distinfo Normal file
View File

@ -0,0 +1,6 @@
$NetBSD: distinfo,v 1.1 2023/08/26 10:54:11 vins Exp $
BLAKE2s (nq-0.5.tar.gz) = 2e677c13154b3bd0026795a172dcb9fb00f33cd667592b3a8edc0246eac372e0
SHA512 (nq-0.5.tar.gz) = 784031971df0585c38c8e47b37d1a5ce73c35c71ab6c9abb7c3df6450eb26a53ad0e649f86a40a742201125ef88e246db34781491935e709ae8fc66afcdf6c0e
Size (nq-0.5.tar.gz) = 12229 bytes
SHA1 (patch-Makefile) = f21ad79a4ec3862f61c0f8152c67bd3b1c78ed6e

View File

@ -0,0 +1,42 @@
$NetBSD: patch-Makefile,v 1.1 2023/08/26 10:54:11 vins Exp $
* Do not override CFLAGS.
* Provide a pkgsrc-compliant install target.
--- Makefile.orig 2022-03-26 14:57:40.000000000 +0000
+++ Makefile
@@ -1,25 +1,26 @@
-ALL=nq fq tq
+ALL=nq fq
+MAN=nq fq tq
-CFLAGS=-g -Wall -O2
+CFLAGS=-Wall
DESTDIR=
PREFIX=/usr/local
BINDIR=$(PREFIX)/bin
MANDIR=$(PREFIX)/share/man
-INSTALL=install
-
all: $(ALL)
clean: FRC
- rm -f nq fq
+ rm -f $(ALL)
check: FRC all
prove -v ./tests
install: FRC all
- mkdir -p $(DESTDIR)$(BINDIR) $(DESTDIR)$(MANDIR)/man1
- $(INSTALL) -m0755 $(ALL) $(DESTDIR)$(BINDIR)
- $(INSTALL) -m0644 $(ALL:=.1) $(DESTDIR)$(MANDIR)/man1
+ $(BSD_INSTALL_PROGRAM_DIR) $(DESTDIR)$(BINDIR)
+ $(BSD_INSTALL_PROGRAM) $(ALL) $(DESTDIR)$(BINDIR)
+ $(BSD_INSTALL_SCRIPT) tq $(DESTDIR)$(BINDIR)
+ $(BSD_INSTALL_MAN_DIR) $(DESTDIR)$(MANDIR)/man1
+ $(BSD_INSTALL_MAN) $(MAN) $(DESTDIR)$(MANDIR)/man1
FRC: