From 98428689a669def9499cce2883ac33202fa3ac84 Mon Sep 17 00:00:00 2001 From: "Artyom V. Poptsov" Date: Mon, 13 Dec 2021 23:34:29 +0300 Subject: [PATCH] gnu: Add libtree * gnu/packages/linux.scm (libtree): New variable. --- gnu/packages/linux.scm | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 1e51dd8d83..84e7042604 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -53,6 +53,7 @@ ;;; Copyright © 2021 B. Wilson ;;; Copyright © 2021 Ivan Gankevich ;;; Copyright © 2021 Olivier Dion +;;; Copyright © 2021 Artyom V. Poptsov ;;; ;;; This file is part of GNU Guix. ;;; @@ -8690,3 +8691,39 @@ older system-wide @file{/sys} interface.") (license (list license:lgpl2.1+ ;; libgpiod license:gpl2+ ;; gpio-tools license:lgpl3+)))) ;; C++ bindings + +(define-public libtree + (package + (name "libtree") + (version "3.0.0-rc6") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/haampie/libtree") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "1i2v70n0pn7aqa4k2pr049zwp1sf8m975pgpgmnr3d53806zchgs")))) + (arguments + `(#:phases + (modify-phases %standard-phases + (delete 'check) + (delete 'configure) + (add-before 'build 'patch + (lambda* (#:key outputs #:allow-other-keys) + (substitute* "Makefile" + (("\\$\\(DESTDIR\\)\\$\\(BINDIR\\)") + (format #f "~a/bin/" (assoc-ref outputs "out")))))) + (replace 'build + (lambda _ + (setenv "CC" "gcc") + (setenv "LDFLAGS" "-static") + (invoke "make")))))) + (build-system gnu-build-system) + (home-page "https://github.com/haampie/libtree") + (synopsis "@command{ldd} as a tree") + (description + "This tool turns @command{ldd} into a tree and explains how shared +libraries are found or why they cannot be located.") + (license license:expat))) -- 2.25.1