diff mbox series

[bug#56202,v2] gnu: Add nsync.

Message ID 20221115222601.15094-1-antero@mailbox.org
State New
Headers show
Series [bug#56202,v2] gnu: Add nsync. | expand

Commit Message

Antero Mejr Nov. 15, 2022, 10:26 p.m. UTC
* gnu/packages/c.scm (nsync): New variable.
---
Update to 1.25.0 and build shared libs.

 gnu/packages/c.scm | 30 ++++++++++++++++++++++++++++++
 1 file changed, 30 insertions(+)
diff mbox series

Patch

diff --git a/gnu/packages/c.scm b/gnu/packages/c.scm
index fb876eeb71..e1d8105585 100644
--- a/gnu/packages/c.scm
+++ b/gnu/packages/c.scm
@@ -1376,3 +1376,33 @@  (define-public utest-h
       (description
        "This package provides a header-only unit testing library for C/C++.")
       (license license:unlicense))))
+
+(define-public nsync
+  (package
+    (name "nsync")
+    (version "1.25.0")
+    (home-page "https://github.com/google/nsync")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                    (url home-page)
+                    (commit version)))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32
+                "1nnavsm5m0yl65r9nyxzzg0y1z1dr0r9933b5329k7n1r6ndinbd"))))
+    (build-system cmake-build-system)
+    (arguments
+     (list #:configure-flags #~(list "-DBUILD_SHARED_LIBS=ON")))
+    (synopsis "C library for synchronization primitives")
+    (description
+     "@code{nsync} is a C library that exports various synchronization
+primitives:
+@enumerate
+@item locks
+@item condition variables
+@item run-once initialization
+@item waitable counter (useful for barriers)
+@item waitable bit (useful for cancellation, or other conditions)
+@end enumerate\n")
+    (license license:asl2.0)))