| 1 | |
| 2 | |
| 3 | |
| 4 | |
| 5 | |
| 6 | |
| 7 | |
| 8 | |
| 9 | |
| 10 | |
| 11 | |
| 12 | |
| 13 | |
| 14 | |
| 15 | |
| 16 | |
| 17 | |
| 18 | |
| 19 | |
| 20 |
|
| 21 | (define-module (gnu packages scsi)
|
| 22 | #:use-module ((guix licenses) #:prefix license:)
|
| 23 | #:use-module (guix packages)
|
| 24 | #:use-module (guix download)
|
| 25 | #:use-module (guix git-download)
|
| 26 | #:use-module (guix build-system gnu)
|
| 27 | #:use-module (gnu packages autotools))
|
| 28 |
|
| 29 | (define-public sg3-utils
|
| 30 | (package
|
| 31 | (name "sg3-utils")
|
| 32 | (version "1.48")
|
| 33 | (source (origin
|
| 34 | (method url-fetch)
|
| 35 | (uri (string-append "https://sg.danny.cz/sg/p/sg3_utils-"
|
| 36 | version ".tar.xz"))
|
| 37 | (sha256
|
| 38 | (base32
|
| 39 | "1ynv6kijzjj8xab3z87nks26qcrpvg46mhlr3s6yah6mj0ba9ffn"))))
|
| 40 | (build-system gnu-build-system)
|
| 41 | (arguments
|
| 42 | `(#:configure-flags
|
| 43 | (list "--disable-static")))
|
| 44 | (home-page "https://sg.danny.cz/sg/sg3_utils.html")
|
| 45 | (synopsis "SCSI device utilities")
|
| 46 | (description
|
| 47 | "sg3-utils is a collection of utilities for devices that use the Small
|
| 48 | Computer System Interface (@dfn{SCSI}) command set. It includes utilities to
|
| 49 | read data from, write data to, control, modify, and query the state of SCSI
|
| 50 | devices.
|
| 51 |
|
| 52 | For example, this package provides command-line tools to:
|
| 53 | @itemize
|
| 54 | @item copy data based on @code{dd} syntax and semantics (called @command{sg_dd},
|
| 55 | @command{sgp_dd}, and @command{sgm_dd})
|
| 56 | @item check @code{INQUIRY} data and @code{VPD pages} (@command{sg_inq})
|
| 57 | @item check mode and log pages (@command{sginfo}, @command{sg_modes}, and
|
| 58 | @command{sg_logs})
|
| 59 | @item spin up and down disks (@command{sg_start})
|
| 60 | @item do self-tests (@code{sg_senddiag})
|
| 61 | @item parse sense data (@code{sg_decode_sense})
|
| 62 | @item and perform various other functions.
|
| 63 | @end itemize
|
| 64 |
|
| 65 | In addition, this package includes a library, called libsgutils, which can be
|
| 66 | used in C and C++ programs to interact with SCSI devices.")
|
| 67 | |
| 68 | |
| 69 | |
| 70 | |
| 71 | |
| 72 | (license (list license:gpl2+ license:bsd-2 license:bsd-3))))
|
| 73 |
|
| 74 | (define-public libiscsi
|
| 75 | (package
|
| 76 | (name "libiscsi")
|
| 77 | (version "1.19.0")
|
| 78 | (source
|
| 79 | (origin
|
| 80 | (method git-fetch)
|
| 81 | (uri (git-reference
|
| 82 | (url "https://github.com/sahlberg/libiscsi")
|
| 83 | (commit version)))
|
| 84 | (sha256
|
| 85 | (base32
|
| 86 | "0ajrkkg5awmi8m4b3mha7h07ylg18k252qprvk1sgq0qbyd66zy7"))
|
| 87 | (file-name (git-file-name name version))))
|
| 88 | (build-system gnu-build-system)
|
| 89 | (native-inputs (list autoconf automake libtool))
|
| 90 | (synopsis "Client-side library for iSCSI")
|
| 91 | (description "Libiscsi is a client-side library to implement the iSCSI
|
| 92 | protocol that can be used to access the resources of an iSCSI target. It is
|
| 93 | fully asynchronous with regards to iSCSI commands and SCSI tasks, but a
|
| 94 | synchronous layer is also provided for ease of use for simpler applications.")
|
| 95 | (home-page "https://github.com/sahlberg/libiscsi")
|
| 96 | (license (list
|
| 97 | |
| 98 | |
| 99 | license:gpl2+
|
| 100 | |
| 101 | license:lgpl2.1+))))
|
| 102 |
|
| 103 | (define-public lsscsi
|
| 104 | (package
|
| 105 | (name "lsscsi")
|
| 106 | (version "0.32")
|
| 107 | (source (origin
|
| 108 | (method url-fetch)
|
| 109 | (uri (string-append
|
| 110 | "http://sg.danny.cz/scsi/lsscsi-" version ".tar.xz"))
|
| 111 | (sha256
|
| 112 | (base32
|
| 113 | "0jp458m2b3wckr18qkln69i01152qlwz33zm49103lq8fgx0n6d4"))))
|
| 114 | (build-system gnu-build-system)
|
| 115 | (synopsis "Lists information about SCSI or NVMe devices in Linux")
|
| 116 | (home-page "https://sg.danny.cz/scsi/lsscsi.html")
|
| 117 | (description
|
| 118 | "@command{lsscsi} lists SCSI logical units or SCSI targets. It can
|
| 119 | also list NVMe namespaces or controllers and show the relationship between a
|
| 120 | device's primary node name, its SCSI generic (sg) node name and its kernel
|
| 121 | name.")
|
| 122 | (license license:gpl2)))
|