@@ -31,7 +31,7 @@ (define-module (gnu packages elf)
#:use-module (guix packages)
#:use-module (guix download)
#:use-module (guix build-system gnu)
- #:use-module ((guix licenses) #:select (gpl3+ lgpl3+ lgpl2.0+))
+ #:use-module ((guix licenses) #:select (gpl3+ lgpl3+ lgpl2.0+ lgpl2.1 gpl2 bsd-2))
#:use-module (gnu packages)
#:use-module (gnu packages autotools)
#:use-module (gnu packages compression)
@@ -282,3 +282,26 @@ (define-public patchelf
(properties
'((release-monitoring-url . "https://github.com/NixOS/patchelf/releases")))
(license gpl3+)))
+
+(define-public libdwarf
+ (package
+ (name "libdwarf")
+ (version "0.5.0")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "https://www.prevanders.net/libdwarf-"
+ version ".tar.xz"))
+ (sha256
+ (base32
+ "1a8j05z0rxf5ab9p5av2hqz6kxl8hfgar8h1387a0zric0n85yhi"))))
+ (build-system gnu-build-system)
+ (arguments
+ '(#:configure-flags '("--enable-shared")))
+ (native-inputs (list python))
+ (inputs (list elfutils))
+ (home-page "https://www.prevanders.net/dwarf.html")
+ (synopsis "Handle DWARF debugging information")
+ (description "@code{libdwarf} is a library that handles the DWARF
+debugging information format.")
+ ;; See https://www.prevanders.net/dwarflicense.html:
+ (license (list lgpl2.1 gpl2 bsd-2))))