@@ -1375,3 +1375,32 @@ (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")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/google/nsync")
+ (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")))
+ (home-page "https://github.com/google/nsync")
+ (synopsis "C library for synchronization primitives")
+ (description
+ "nsync is a C library that exports various synchronization primitives:
+@itemize
+@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 itemize")
+ (license license:asl2.0)))