| 1 | |
| 2 | |
| 3 | |
| 4 | |
| 5 | |
| 6 | |
| 7 | |
| 8 | |
| 9 | |
| 10 | |
| 11 | |
| 12 | |
| 13 | |
| 14 | |
| 15 | |
| 16 | |
| 17 | |
| 18 | |
| 19 | |
| 20 | |
| 21 | |
| 22 | |
| 23 |
|
| 24 | (define-module (gnu packages nfs)
|
| 25 | #:use-module (gnu packages)
|
| 26 | #:use-module (gnu packages attr)
|
| 27 | #:use-module (gnu packages autotools)
|
| 28 | #:use-module (gnu packages crypto)
|
| 29 | #:use-module (gnu packages linux)
|
| 30 | #:use-module (gnu packages libevent)
|
| 31 | #:use-module (gnu packages kerberos)
|
| 32 | #:use-module (gnu packages onc-rpc)
|
| 33 | #:use-module (gnu packages pkg-config)
|
| 34 | #:use-module (gnu packages python)
|
| 35 | #:use-module (gnu packages sqlite)
|
| 36 | #:use-module (guix build-system gnu)
|
| 37 | #:use-module (guix download)
|
| 38 | #:use-module (guix git-download)
|
| 39 | #:use-module ((guix licenses) #:prefix license:)
|
| 40 | #:use-module (guix packages)
|
| 41 | #:use-module (guix utils)
|
| 42 | #:use-module (srfi srfi-1)
|
| 43 | #:use-module (srfi srfi-2)
|
| 44 | #:use-module (srfi srfi-26)
|
| 45 | #:use-module (ice-9 match))
|
| 46 |
|
| 47 | (define-public nfs-utils
|
| 48 | (package
|
| 49 | (name "nfs-utils")
|
| 50 | (version "2.4.3")
|
| 51 | (source (origin
|
| 52 | (method url-fetch)
|
| 53 | (uri (string-append
|
| 54 | "mirror://kernel.org/linux/utils/nfs-utils/" version
|
| 55 | "/nfs-utils-" version ".tar.xz"))
|
| 56 | (sha256
|
| 57 | (base32
|
| 58 | "16b5y82cjy1cvijg5zmdvivc6sfdlv2slyynxbwwyw43vpjzqrdg"))))
|
| 59 | (build-system gnu-build-system)
|
| 60 | (arguments
|
| 61 | `(#:configure-flags
|
| 62 | `("--disable-static"
|
| 63 | "--without-tcp-wrappers"
|
| 64 | ,(string-append "--with-start-statd="
|
| 65 | (assoc-ref %outputs "out") "/sbin/start-statd")
|
| 66 | ,(string-append "--with-krb5=" (assoc-ref %build-inputs "mit-krb5"))
|
| 67 | ,(string-append "--with-pluginpath="
|
| 68 | (assoc-ref %outputs "out")
|
| 69 | "/lib/libnfsidmap")
|
| 70 | "--enable-svcgss")
|
| 71 | #:phases
|
| 72 | (modify-phases %standard-phases
|
| 73 | (add-before 'configure 'adjust-command-file-names
|
| 74 | (lambda _
|
| 75 | |
| 76 | (substitute* `("utils/statd/start-statd")
|
| 77 | (("^PATH=.*") "")
|
| 78 | (("^flock")
|
| 79 | (string-append
|
| 80 | (assoc-ref %build-inputs "util-linux")
|
| 81 | "/bin/flock"))
|
| 82 | (("^exec rpc.statd")
|
| 83 | (string-append "exec "
|
| 84 | (assoc-ref %outputs "out") "/sbin/rpc.statd")))
|
| 85 |
|
| 86 | |
| 87 | (substitute* "configure"
|
| 88 | (("/usr/local/bin/rpcgen")
|
| 89 | (which "rpcgen")))
|
| 90 |
|
| 91 | |
| 92 | |
| 93 | (substitute* `("Makefile.in")
|
| 94 | (("^install-data-hook:")
|
| 95 | "install-data-hook-disabled-for-guix:"))
|
| 96 |
|
| 97 | |
| 98 | (substitute* `("utils/nfsd/nfssvc.c")
|
| 99 | (("/bin/mount")
|
| 100 | (string-append
|
| 101 | (assoc-ref %build-inputs "util-linux")
|
| 102 | "/bin/mount")))
|
| 103 | (substitute* `("utils/statd/statd.c")
|
| 104 | (("/usr/sbin/")
|
| 105 | (string-append (assoc-ref %outputs "out") "/sbin/")))
|
| 106 | (substitute* `("utils/mount/Makefile.in"
|
| 107 | "utils/nfsdcld/Makefile.in"
|
| 108 | "utils/nfsdcltrack/Makefile.in")
|
| 109 | (("^sbindir = /sbin")
|
| 110 | (string-append "sbindir = "
|
| 111 | (assoc-ref %outputs "out") "/sbin")))
|
| 112 | #t)))))
|
| 113 | (inputs
|
| 114 | `(("keyutils" ,keyutils)
|
| 115 | ("libevent" ,libevent)
|
| 116 | ("rpcsvc-proto" ,rpcsvc-proto) |
| 117 | ("sqlite" ,sqlite)
|
| 118 | ("lvm2" ,lvm2)
|
| 119 | ("util-linux" ,util-linux) |
| 120 | ("util-linux:lib" ,util-linux "lib") |
| 121 | ("mit-krb5" ,mit-krb5)
|
| 122 | ("libtirpc" ,libtirpc)
|
| 123 | ("python-wrapper" ,python-wrapper))) |
| 124 | (native-inputs
|
| 125 | (list pkg-config))
|
| 126 | (home-page "https://www.kernel.org/pub/linux/utils/nfs-utils/")
|
| 127 | (synopsis "Tools for loading and managing Linux NFS mounts")
|
| 128 | (description "The Network File System (NFS) was developed to allow
|
| 129 | machines to mount a disk partition on a remote machine as if it were a local
|
| 130 | disk. It allows for fast, seamless sharing of files across a network.")
|
| 131 | |
| 132 | |
| 133 | |
| 134 | |
| 135 | |
| 136 | |
| 137 | (license license:gpl2)))
|
| 138 |
|
| 139 | (define-public nfs4-acl-tools
|
| 140 | (package
|
| 141 | (name "nfs4-acl-tools")
|
| 142 | (version "0.3.7")
|
| 143 | (source (origin
|
| 144 | (method git-fetch)
|
| 145 | |
| 146 | |
| 147 | (uri (git-reference
|
| 148 | (url "git://git.linux-nfs.org/projects/bfields/nfs4-acl-tools.git")
|
| 149 | (commit (string-append name "-" version))))
|
| 150 | (file-name (git-file-name name version))
|
| 151 | (sha256
|
| 152 | (base32
|
| 153 | "0lq9xdaskxysggs918vs8x42xvmg9nj7lla21ni2scw5ljld3h1i"))
|
| 154 | (patches (search-patches "nfs4-acl-tools-0.3.7-fixpaths.patch"))))
|
| 155 | (build-system gnu-build-system)
|
| 156 | (arguments
|
| 157 | `(#:tests? #f |
| 158 | #:phases
|
| 159 | (modify-phases %standard-phases
|
| 160 | (add-after 'unpack 'fix-bin-sh
|
| 161 | (lambda _
|
| 162 | (substitute* "include/buildmacros"
|
| 163 | (("/bin/sh") (which "sh")))
|
| 164 | #t)))))
|
| 165 | (native-inputs
|
| 166 | (list automake autoconf libtool))
|
| 167 | (inputs
|
| 168 | (list attr))
|
| 169 | (home-page "https://linux-nfs.org/wiki/index.php/Main_Page")
|
| 170 | (synopsis "Commandline ACL utilities for the Linux NFSv4 client")
|
| 171 | (description "This package provides the commandline utilities
|
| 172 | @command{nfs4_getfacl} and @command{nfs4_setfacl}, which are similar to their
|
| 173 | POSIX equivalents @command{getfacl} and @command{setfacl}. They fetch and
|
| 174 | manipulate access control lists for files and directories on NFSv4 mounts.")
|
| 175 | (license license:bsd-3)))
|