gnu: hurd: Add NFS support.
* gnu/packages/hurd.scm (hurd)[inputs]: Add libtirpc/hurd. [arguments]: Add configure flags to use libtirpc; add phase "find-tirpc" to find the RPC headers; add phase "fix-rpc-headers" to include missing headers.
This commit is contained in:
parent
9a554a7082
commit
2e463d6e2c
1 changed files with 33 additions and 1 deletions
|
@ -44,6 +44,7 @@
|
||||||
#:use-module (gnu packages base)
|
#:use-module (gnu packages base)
|
||||||
#:use-module (gnu packages bash)
|
#:use-module (gnu packages bash)
|
||||||
#:use-module (gnu packages texinfo)
|
#:use-module (gnu packages texinfo)
|
||||||
|
#:use-module (gnu packages onc-rpc)
|
||||||
#:use-module (gnu packages xorg) ; libpciaccess
|
#:use-module (gnu packages xorg) ; libpciaccess
|
||||||
#:use-module (guix git-download)
|
#:use-module (guix git-download)
|
||||||
#:export (hurd-system?
|
#:export (hurd-system?
|
||||||
|
@ -393,6 +394,30 @@ boot, since this cannot be done from GNU/Linux."
|
||||||
(string-append dde "/" dir ) dir))
|
(string-append dde "/" dir ) dir))
|
||||||
'("libmachdev" "libmachdevdde" "libddekit")))
|
'("libmachdev" "libmachdevdde" "libddekit")))
|
||||||
#t))
|
#t))
|
||||||
|
(add-after 'unpack 'find-tirpc
|
||||||
|
(lambda* (#:key inputs #:allow-other-keys)
|
||||||
|
(for-each (lambda (var)
|
||||||
|
(setenv var
|
||||||
|
(string-append (assoc-ref inputs "libtirpc")
|
||||||
|
"/include/tirpc:"
|
||||||
|
(or (getenv var) ""))))
|
||||||
|
'("CROSS_C_INCLUDE_PATH" "C_INCLUDE_PATH"
|
||||||
|
"CROSS_CPATH" "CPATH"))
|
||||||
|
#t))
|
||||||
|
(add-after 'unpack 'fix-rpc-headers
|
||||||
|
(lambda _
|
||||||
|
(substitute* "nfs/mount.c"
|
||||||
|
(("#undef (TRUE|FALSE)") "")
|
||||||
|
(("#include <rpc/pmap_prot.h>" m)
|
||||||
|
(string-append "#include <rpc/xdr.h>\n" m)))
|
||||||
|
(substitute* '("nfsd/cache.c")
|
||||||
|
(("#undef (TRUE|FALSE)") ""))
|
||||||
|
(substitute* '("nfsd/loop.c"
|
||||||
|
"nfsd/main.c"
|
||||||
|
"nfsd/ops.c")
|
||||||
|
(("#include <rpc/pmap_prot.h>" m)
|
||||||
|
(string-append "#include <rpc/types.h>\n#include <rpc/xdr.h>\n" m)))
|
||||||
|
#t))
|
||||||
(add-before 'build 'pre-build
|
(add-before 'build 'pre-build
|
||||||
(lambda _
|
(lambda _
|
||||||
;; Don't change the ownership of any file at this time.
|
;; Don't change the ownership of any file at this time.
|
||||||
|
@ -496,7 +521,11 @@ fsysopts / --writable\n"))
|
||||||
"--disable-ncursesw"
|
"--disable-ncursesw"
|
||||||
"--without-libbz2"
|
"--without-libbz2"
|
||||||
"--without-libz"
|
"--without-libz"
|
||||||
"--without-parted")))
|
"--without-parted"
|
||||||
|
;; This is needed to pass the configure check for
|
||||||
|
;; clnt_create
|
||||||
|
"ac_func_search_save_LIBS=-ltirpc"
|
||||||
|
"ac_cv_search_clnt_create=false")))
|
||||||
(build-system gnu-build-system)
|
(build-system gnu-build-system)
|
||||||
(inputs
|
(inputs
|
||||||
`(("glibc-hurd-headers" ,glibc/hurd-headers)
|
`(("glibc-hurd-headers" ,glibc/hurd-headers)
|
||||||
|
@ -507,6 +536,9 @@ fsysopts / --writable\n"))
|
||||||
("unifont" ,unifont)
|
("unifont" ,unifont)
|
||||||
("libpciaccess" ,libpciaccess)
|
("libpciaccess" ,libpciaccess)
|
||||||
|
|
||||||
|
;; For NFS support
|
||||||
|
("libtirpc" ,libtirpc/hurd)
|
||||||
|
|
||||||
;; Tools for the /libexec/* scripts.
|
;; Tools for the /libexec/* scripts.
|
||||||
("bash-minimal" ,bash-minimal)
|
("bash-minimal" ,bash-minimal)
|
||||||
("coreutils" ,coreutils)
|
("coreutils" ,coreutils)
|
||||||
|
|
Reference in a new issue