gnu: Add rust-packed-struct.
* gnu/packages/crates-io.scm (rust-packed-struct): New variable.master
parent
aa9ba865de
commit
7e25147e15
|
@ -30762,3 +30762,44 @@ implementation that works everywhere, even WASM!")
|
|||
(description
|
||||
"This package provides a library for parsing compiled zoneinfo files.")
|
||||
(license license:expat)))
|
||||
|
||||
(define-public rust-packed-struct
|
||||
(package
|
||||
(name "rust-packed-struct")
|
||||
(version "0.3.0")
|
||||
(source
|
||||
(origin
|
||||
(method url-fetch)
|
||||
(uri (crate-uri "packed_struct" version))
|
||||
(file-name
|
||||
(string-append name "-" version ".tar.gz"))
|
||||
(sha256
|
||||
(base32
|
||||
"10b2fmxchmcigwagnhi42frj74dl02wyv0xwmbr9839qfh7gijlh"))))
|
||||
(build-system cargo-build-system)
|
||||
(arguments
|
||||
`(#:cargo-inputs
|
||||
(("rust-serde" ,rust-serde-1)
|
||||
("rust-serde-derive" ,rust-serde-derive-1))))
|
||||
(home-page "http://www.hashmismatch.net/libraries/packed-struct/")
|
||||
(synopsis "Binary-level structure packing and unpacking generator")
|
||||
(description "This package provides bit-level packing an unpacking
|
||||
of structs. The library provides a meta-programming approach, using
|
||||
attributes to define fields and how they should be packed. The resulting
|
||||
trait implementations provide safe packing, unpacking and runtime debugging
|
||||
formatters with per-field documentation generated for each structure.
|
||||
|
||||
@itemize
|
||||
@item Plain Rust structures, decorated with attributes
|
||||
@item MSB or LSB integers of user-defined bit widths
|
||||
@item Primitive enum code generation helper
|
||||
@item MSB0 or LSB0 bit positioning
|
||||
@item Documents the field's packing table
|
||||
@item Runtime packing visualization
|
||||
@item Nested packed types
|
||||
@item Arrays of packed structures as fields
|
||||
@item Reserved fields, their bits are always 0 or 1
|
||||
@end itemize")
|
||||
;; User can choose either license.
|
||||
(license (list license:expat license:asl2.0))))
|
||||
|
||||
|
|
Reference in New Issue