From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
To: dan <i@dan.games>
Cc: 65106@debbugs.gnu.org
Subject: [bug#65106] [PATCH] gnu: Add tracy.
Date: Tue, 05 Sep 2023 09:46:59 -0400 [thread overview]
Message-ID: <87zg20ka0c.fsf@gmail.com> (raw)
In-Reply-To: <20230806054011.16970-1-i@dan.games> (dan's message of "Sun, 6 Aug 2023 13:40:10 +0800")
Hello!
dan <i@dan.games> writes:
> ---
> gnu/packages/profiling.scm | 48 +++++++++++++++++++++++++++++++++++++-
> 1 file changed, 47 insertions(+), 1 deletion(-)
>
> diff --git a/gnu/packages/profiling.scm b/gnu/packages/profiling.scm
> index 8a1c609669..799b333162 100644
> --- a/gnu/packages/profiling.scm
> +++ b/gnu/packages/profiling.scm
> @@ -2,6 +2,7 @@
> ;;; Copyright © 2017 Dave Love <fx@gnu.org>
> ;;; Copyright © 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
> ;;; Copyright © 2022 Ludovic Courtès <ludo@gnu.org>
> +;;; Copyright © 2023 dan <i@dan.games>
> ;;;
> ;;; This file is part of GNU Guix.
> ;;;
> @@ -21,6 +22,7 @@
> (define-module (gnu packages profiling)
> #:use-module (guix packages)
> #:use-module (guix gexp)
> + #:use-module (guix git-download)
> #:use-module ((guix licenses) #:prefix license:) ; avoid zlib, expat clashes
> #:use-module (guix download)
> #:use-module (guix utils)
> @@ -31,17 +33,20 @@ (define-module (gnu packages profiling)
> #:use-module (gnu packages bison)
> #:use-module (gnu packages compression)
> #:use-module (gnu packages documentation)
> + #:use-module (gnu packages engineering)
> #:use-module (gnu packages fabric-management)
> #:use-module (gnu packages flex)
> + #:use-module (gnu packages fontutils)
> #:use-module (gnu packages gawk)
> #:use-module (gnu packages gcc)
> + #:use-module (gnu packages gl)
> #:use-module (gnu packages glib)
> #:use-module (gnu packages libunwind)
> #:use-module (gnu packages linux)
> #:use-module (gnu packages mpi)
> #:use-module (gnu packages ncurses)
> #:use-module (gnu packages perl)
> - #:use-module (gnu packages perl)
> + #:use-module (gnu packages pkg-config)
> #:use-module (gnu packages python)
> #:use-module (gnu packages qt))
>
> @@ -389,3 +394,44 @@ (define (make-scorep mpi)
> (license license:cpl1.0)))
>
> (define-public scorep-openmpi (make-scorep openmpi))
> +
> +(define-public tracy
> + (package
> + (name "tracy")
> + (version "0.9.1")
> + (source (origin
> + (method git-fetch)
> + (uri (git-reference
> + (url "https://github.com/wolfpld/tracy.git")
> + (commit (string-append "v" version))))
> + (sha256
> + (base32
> + "1znw1r1c4vrb9vrsr08gcwynpjda8xxmb3923yykpymw2hsm0n9b"))
> + (file-name (git-file-name "tracy" version))))
> + (build-system gnu-build-system)
> + (arguments
> + (list #:tests? #f ;no test for the profiler
> + #:make-flags #~(list "LEGACY=1"
Why is LEGACY needed? A comment should say so.
> + (string-append "CC="
> + #$(cc-for-target)))
> + #:phases #~(modify-phases %standard-phases
> + (replace 'configure
> + (lambda _
> + (chdir "profiler/build/unix")))
> + (replace 'install
> + (lambda _
> + (let ((out (string-append #$output "/bin/tracy"))
> + (bin (string-append #$output "/bin")))
> + (mkdir-p bin)
> + (copy-file "Tracy-release" out)
You can simplify this by using the 'install-file' procedure, which is in
scope here (it comes from (guix build utils)). 'Tracy-release' is a
weird name for a binary; is this how it's packaged on other system? I'd
have expected 'tracy' or similar.
> + (wrap-program out
> + `("LD_LIBRARY_PATH" ":" =
> + (,(string-append #$mesa "/lib")))
Since this is also unusual in Guix (usually RUNPATH is baked in the Elf
by the ld-wrapper script and it just works), it deserves an explanatory
comment too.
--
Thanks,
Maxim
next prev parent reply other threads:[~2023-09-05 13:48 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-08-06 5:40 [bug#65106] [PATCH] gnu: Add tracy dan
2023-09-05 13:46 ` Maxim Cournoyer [this message]
2023-09-24 17:13 ` [bug#65106] [PATCH v2 0/2] gnu: Add tracy and tracy-wayland dan
2023-09-24 17:13 ` [bug#65106] [PATCH v2 1/2] gnu: Add tracy-wayland dan
2023-09-26 15:22 ` bug#65106: " Maxim Cournoyer
2023-09-24 17:14 ` [bug#65106] [PATCH v2 2/2] gnu: Add tracy dan
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87zg20ka0c.fsf@gmail.com \
--to=maxim.cournoyer@gmail.com \
--cc=65106@debbugs.gnu.org \
--cc=i@dan.games \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/guix.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.