mirror of
https://codeberg.org/guix/guix.git
synced 2025-10-02 02:15:12 +00:00
gnu: libbpf: Install uAPI headers.
* gnu/packages/linux.scm (libbpf) [phases] {install-linux-bpf-headers}: Replace with... {install}: ... this new phase override. Change-Id: I596c17dcf3af5bce70cffe6949443f4d409dda89
This commit is contained in:
parent
9bbaae304b
commit
c11b7aacc2
1 changed files with 10 additions and 24 deletions
|
@ -10639,30 +10639,16 @@ persistent over reboots.")
|
||||||
(add-before 'build 'pre-build
|
(add-before 'build 'pre-build
|
||||||
(lambda _
|
(lambda _
|
||||||
(chdir "src")))
|
(chdir "src")))
|
||||||
(add-after 'install 'install-linux-bpf-headers
|
(replace 'install
|
||||||
;; Workaround users such as 'dwarves' requiring btf_enum64
|
(lambda* (#:key make-flags #:allow-other-keys #:rest args)
|
||||||
;; definition from the kernel Linux >= 6 headers (see:
|
(apply (assoc-ref %standard-phases 'install)
|
||||||
;; https://github.com/acmel/dwarves/issues/49).
|
(append args
|
||||||
;; TODO: Remove once our 'linux-libre-headers' package is
|
(list #:make-flags
|
||||||
;; upgraded to a >= 6 release.
|
(append (list "install"
|
||||||
(lambda _
|
;; Also install the kernel
|
||||||
(let ((linux-libre-headers #$(this-package-native-input
|
;; user API (uAPI) headers.
|
||||||
"linux-libre-headers")))
|
"install_uapi_headers")
|
||||||
(for-each (lambda (f)
|
make-flags)))))))))
|
||||||
(install-file (string-append linux-libre-headers
|
|
||||||
"/include/" f)
|
|
||||||
(string-append #$output "/include/"
|
|
||||||
(dirname f))))
|
|
||||||
;; This list contains btf.h and its transitive
|
|
||||||
;; dependencies.
|
|
||||||
(list "asm/posix_types.h"
|
|
||||||
"asm/types.h"
|
|
||||||
"asm-generic/types.h"
|
|
||||||
"asm-generic/int-ll64.h"
|
|
||||||
"linux/btf.h"
|
|
||||||
"linux/posix_types.h"
|
|
||||||
"linux/stddef.h"
|
|
||||||
"linux/types.h"))))))))
|
|
||||||
(native-inputs (list linux-libre-headers-latest pkg-config))
|
(native-inputs (list linux-libre-headers-latest pkg-config))
|
||||||
(propagated-inputs (list elfutils zlib)) ;in Requires.private of libbpf.pc
|
(propagated-inputs (list elfutils zlib)) ;in Requires.private of libbpf.pc
|
||||||
(home-page "https://github.com/libbpf/libbpf")
|
(home-page "https://github.com/libbpf/libbpf")
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue