[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
13/13: gnu: Add uftrace.
From: |
guix-commits |
Subject: |
13/13: gnu: Add uftrace. |
Date: |
Thu, 20 Jan 2022 09:29:59 -0500 (EST) |
civodul pushed a commit to branch master
in repository guix.
commit ee6bf00b2d89f6acab55b7a82896d99e39c1229b
Author: Olivier Dion <olivier.dion@polymtl.ca>
AuthorDate: Mon Jan 17 16:25:11 2022 -0500
gnu: Add uftrace.
* gnu/packages/instrumentation.scm: (uftrace): New variable.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
---
gnu/packages/instrumentation.scm | 66 +++++++++++++++++++++++++++++++++++++++-
1 file changed, 65 insertions(+), 1 deletion(-)
diff --git a/gnu/packages/instrumentation.scm b/gnu/packages/instrumentation.scm
index 41e189ebfb..ab986bfcc7 100644
--- a/gnu/packages/instrumentation.scm
+++ b/gnu/packages/instrumentation.scm
@@ -23,11 +23,16 @@
#:use-module (gnu packages datastructures)
#:use-module (gnu packages documentation)
#:use-module (gnu packages elf)
+ #:use-module (gnu packages engineering)
#:use-module (gnu packages flex)
#:use-module (gnu packages glib)
+ #:use-module (gnu packages haskell-xyz)
+ #:use-module (gnu packages libunwind)
#:use-module (gnu packages linux)
#:use-module (gnu packages llvm)
+ #:use-module (gnu packages lua)
#:use-module (gnu packages man)
+ #:use-module (gnu packages ncurses)
#:use-module (gnu packages perl)
#:use-module (gnu packages pkg-config)
#:use-module (gnu packages popt)
@@ -45,7 +50,8 @@
#:use-module (guix git-download)
#:use-module ((guix licenses) #:prefix license:)
#:use-module (guix packages)
- #:use-module (srfi srfi-26))
+ #:use-module (srfi srfi-26)
+ #:use-module (guix utils))
(define-public babeltrace
(package
@@ -280,3 +286,61 @@ daemon @code{lttng-sessiond} that acts as a tracing
registry, the @command{lttng
line for tracing control, a @code{lttng-ctl} library for tracing control and a
@code{lttng-relayd} for network streaming.")
(license (list license:gpl2 license:lgpl2.1))))
+
+(define-public uftrace
+ (package
+ (name "uftrace")
+ (version "0.11")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/namhyung/uftrace")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
"0gk0hv3rnf5czvazz1prg21rf9qlniz42g5b389n8a29hqj4q6xr"))))
+ (build-system gnu-build-system)
+ (arguments
+ `(#:make-flags
+ (list
+ (string-append "CC=" ,(cc-for-target)))
+ ;; runtest hang at some point -- probably dues to
+ ;; failed socket connection -- but we want to keep the
+ ;; unit tests. Change the target to "test" when fixed.
+ #:test-target "unittest"
+ #:phases
+ (modify-phases %standard-phases
+ (replace 'configure
+ (lambda* (#:key outputs target #:allow-other-keys)
+ (let ((arch ,(system->linux-architecture
+ (or (%current-target-system)
+ (%current-system)))))
+ (setenv "ARCH"
+ (cond
+ ((string=? arch "arm64") "aarch64")
+ (else arch)))
+ (when target
+ (setenv "CROSS_COMPILE" (string-append target "-"))))
+ (setenv "SHELL" (which "sh"))
+ (invoke "./configure"
+ (string-append "--prefix="
+ (assoc-ref outputs "out"))))))))
+ (inputs
+ (list capstone
+ elfutils
+ libunwind
+ ncurses))
+ (native-inputs
+ (list luajit
+ pandoc
+ pkg-config
+ python-wrapper))
+ (home-page "https://github.com/namhyung/uftrace")
+ (synopsis "Function graph tracer for C/C++/Rust")
+ (description "uftrace is a tool for tracing and analyzing the execution of
+programs written in C/C++. It is heavily inspired by the ftrace framework of
+the Linux kernel, while supporting userspace programs. It supports various
+kind of commands and filters to help analysis of the program execution and
+performance. It provides the command @command{uftrace}. User that want to do
+scripting need to install python-3 or luajit in their profile.")
+ (license license:gpl2)))
- branch master updated (d99e42d7f6 -> ee6bf00b2d), guix-commits, 2022/01/20
- 02/13: gnu: dune-common: Update to 2.7.1., guix-commits, 2022/01/20
- 04/13: gnu: dune-uggrid: Update to 2.7.1., guix-commits, 2022/01/20
- 03/13: gnu: dune-geometry: Update to 2.7.1., guix-commits, 2022/01/20
- 01/13: gnu: Modernize add-openmpi-to-dune-package, guix-commits, 2022/01/20
- 05/13: gnu: dune-grid: Update to 2.7.1., guix-commits, 2022/01/20
- 13/13: gnu: Add uftrace.,
guix-commits <=
- 10/13: gnu: dune-typetree: Update to 2.7.1., guix-commits, 2022/01/20
- 09/13: gnu: dune-subgrid: Update to 2.7.1., guix-commits, 2022/01/20
- 11/13: gnu: dune-functions: Update to 2.7.1., guix-commits, 2022/01/20
- 07/13: gnu: dune-localfunctions: Update to 2.7.1., guix-commits, 2022/01/20
- 06/13: gnu: dune-istl: Update to 2.7.1., guix-commits, 2022/01/20
- 12/13: gnu: dune-pdelab: Update to 2.7.1., guix-commits, 2022/01/20
- 08/13: gnu: dune-alugrid: Update to 2.7.1., guix-commits, 2022/01/20