summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorpho <pho@pkgsrc.org>2022-02-24 01:16:25 +0000
committerpho <pho@pkgsrc.org>2022-02-24 01:16:25 +0000
commit2bc7be3a0de7eb4dc08dbb039976879cdd2c2f33 (patch)
tree15c8faa45582455eb86afff9149e917f7732532e
parent51994edd11db6767e45ffe33f35b123b488594e4 (diff)
downloadpkgsrc-2bc7be3a0de7eb4dc08dbb039976879cdd2c2f33.tar.gz
devel/hs-say: import hs-say-0.1.0.1
Send textual messages to a Handle in a thread-friendly way. The motivation for this package is described in a blog post on Haskell's Missing Concurrency Basics (http://www.snoyman.com/blog/2016/11/haskells-missing-concurrency-basics). The simple explanation is, when writing a line of textual data to a Handle - such as sending some messages t o ther terminal - we'd like to have the following properties: * Properly handle character encoding settings on the Handle * For reasonably sized messages, ensure that the entire message is written in one chunk to avoid interleaving data with other threads * This includes the trailing newline character * Avoid unnecessary memory allocations and copies * Minimize locking * Provide a simple API
-rw-r--r--devel/hs-say/DESCR16
-rw-r--r--devel/hs-say/Makefile11
-rw-r--r--devel/hs-say/PLIST22
-rw-r--r--devel/hs-say/buildlink3.mk13
-rw-r--r--devel/hs-say/distinfo5
5 files changed, 67 insertions, 0 deletions
diff --git a/devel/hs-say/DESCR b/devel/hs-say/DESCR
new file mode 100644
index 00000000000..e0d48ac5810
--- /dev/null
+++ b/devel/hs-say/DESCR
@@ -0,0 +1,16 @@
+Send textual messages to a Handle in a thread-friendly way.
+
+The motivation for this package is described in a blog post on Haskell's
+Missing Concurrency Basics
+(http://www.snoyman.com/blog/2016/11/haskells-missing-concurrency-basics). The
+simple explanation is, when writing a line of textual data to a Handle -
+such as sending some messages t o ther terminal - we'd like to have the
+following properties:
+
+* Properly handle character encoding settings on the Handle
+* For reasonably sized messages, ensure that the entire message is written
+ in one chunk to avoid interleaving data with other threads
+ * This includes the trailing newline character
+* Avoid unnecessary memory allocations and copies
+* Minimize locking
+* Provide a simple API
diff --git a/devel/hs-say/Makefile b/devel/hs-say/Makefile
new file mode 100644
index 00000000000..c9c50f2fb65
--- /dev/null
+++ b/devel/hs-say/Makefile
@@ -0,0 +1,11 @@
+# $NetBSD: Makefile,v 1.1 2022/02/24 01:16:25 pho Exp $
+
+DISTNAME= say-0.1.0.1
+CATEGORIES= devel
+
+MAINTAINER= pkgsrc-users@NetBSD.org
+COMMENT= Send textual messages to a Handle in a thread-friendly way
+LICENSE= mit
+
+.include "../../mk/haskell.mk"
+.include "../../mk/bsd.pkg.mk"
diff --git a/devel/hs-say/PLIST b/devel/hs-say/PLIST
new file mode 100644
index 00000000000..2148a5a4a62
--- /dev/null
+++ b/devel/hs-say/PLIST
@@ -0,0 +1,22 @@
+@comment $NetBSD: PLIST,v 1.1 2022/02/24 01:16:25 pho Exp $
+lib/say-${PKGVERSION}/${HS_VERSION}/package-description
+lib/say-${PKGVERSION}/${HS_VERSION}/package-id
+lib/${HS_PLATFORM}/libHS${HS_PKGID}-${HS_VER}.so
+lib/${HS_PLATFORM}/${HS_PKGID}/Paths_say.dyn_hi
+lib/${HS_PLATFORM}/${HS_PKGID}/Paths_say.hi
+lib/${HS_PLATFORM}/${HS_PKGID}/Paths_say.p_hi
+lib/${HS_PLATFORM}/${HS_PKGID}/Say.dyn_hi
+lib/${HS_PLATFORM}/${HS_PKGID}/Say.hi
+lib/${HS_PLATFORM}/${HS_PKGID}/Say.p_hi
+lib/${HS_PLATFORM}/${HS_PKGID}/libHS${HS_PKGID}.a
+lib/${HS_PLATFORM}/${HS_PKGID}/libHS${HS_PKGID}_p.a
+share/doc/${HS_PLATFORM}/say-${PKGVERSION}/LICENSE
+share/doc/${HS_PLATFORM}/say-${PKGVERSION}/html/Say.html
+share/doc/${HS_PLATFORM}/say-${PKGVERSION}/html/doc-index.html
+share/doc/${HS_PLATFORM}/say-${PKGVERSION}/html/haddock-bundle.min.js
+share/doc/${HS_PLATFORM}/say-${PKGVERSION}/html/index.html
+share/doc/${HS_PLATFORM}/say-${PKGVERSION}/html/linuwial.css
+share/doc/${HS_PLATFORM}/say-${PKGVERSION}/html/meta.json
+share/doc/${HS_PLATFORM}/say-${PKGVERSION}/html/quick-jump.css
+share/doc/${HS_PLATFORM}/say-${PKGVERSION}/html/say.haddock
+share/doc/${HS_PLATFORM}/say-${PKGVERSION}/html/synopsis.png
diff --git a/devel/hs-say/buildlink3.mk b/devel/hs-say/buildlink3.mk
new file mode 100644
index 00000000000..1590612443c
--- /dev/null
+++ b/devel/hs-say/buildlink3.mk
@@ -0,0 +1,13 @@
+# $NetBSD: buildlink3.mk,v 1.1 2022/02/24 01:16:25 pho Exp $
+
+BUILDLINK_TREE+= hs-say
+
+.if !defined(HS_SAY_BUILDLINK3_MK)
+HS_SAY_BUILDLINK3_MK:=
+
+BUILDLINK_API_DEPENDS.hs-say+= hs-say>=0.1.0
+BUILDLINK_ABI_DEPENDS.hs-say+= hs-say>=0.1.0.1
+BUILDLINK_PKGSRCDIR.hs-say?= ../../devel/hs-say
+.endif # HS_SAY_BUILDLINK3_MK
+
+BUILDLINK_TREE+= -hs-say
diff --git a/devel/hs-say/distinfo b/devel/hs-say/distinfo
new file mode 100644
index 00000000000..1e0f07b12f6
--- /dev/null
+++ b/devel/hs-say/distinfo
@@ -0,0 +1,5 @@
+$NetBSD: distinfo,v 1.1 2022/02/24 01:16:25 pho Exp $
+
+BLAKE2s (say-0.1.0.1.tar.gz) = 19204063c2eba9cfcce6f8949e0e7baa4e10932617f4f8673736066a2bf4dc4c
+SHA512 (say-0.1.0.1.tar.gz) = 3de9f6b473a3b4403624c3f6aeac3703a5e8b6cfae82578f7a49a81defa9fa64295cd315664d02fbab70646694d34415d638b5b52424d167d44e93b34a917604
+Size (say-0.1.0.1.tar.gz) = 5931 bytes