GNU bug report logs - #52472
[PATCH] gnu: Add libtree

Previous Next

Package: guix-patches;

Reported by: poptsov.artyom <at> gmail.com (Artyom V. Poptsov)

Date: Mon, 13 Dec 2021 20:43:01 UTC

Severity: normal

Tags: patch

Done: Ludovic Courtès <ludo <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


Message #11 received at 52472 <at> debbugs.gnu.org (full text, mbox):

From: Mathieu Othacehe <othacehe <at> gnu.org>
To: poptsov.artyom <at> gmail.com (Artyom V. Poptsov)
Cc: 52472 <at> debbugs.gnu.org
Subject: Re: bug#52472: [PATCH] gnu: Add libtree
Date: Sun, 19 Dec 2021 10:48:28 +0100
Hey Artyom,

>  ;;; Copyright © 2021 Solene Rapenne <solene <at> perso.pw>
> +;;; Copyright © 2021 Artyom V. Poptsov <poptsov.artyom <at> gmail.com>
> +

No need for an extra new-line here.

> +           (lambda* (#:key outputs #:allow-other-keys)
> +             (substitute* "Makefile"
> +               (("\\$\\(DESTDIR\\)\\$\\(BINDIR\\)")
> +                (format #f "~a/bin/" (assoc-ref outputs "out")))
> +               (("\\$\\(DESTDIR\\)\\$\\(SHAREDIR\\)")
> +                (format #f "~a/share/" (assoc-ref outputs "out"))))))

You can now write:

--8<---------------cut here---------------start------------->8---
       ,#~(modify-phases %standard-phases
            (delete 'check)
            (delete 'configure)
            (add-before 'build 'patch
              (lambda* (#:key outputs #:allow-other-keys)
                (substitute* "Makefile"
                  (("\\$\\(DESTDIR\\)\\$\\(BINDIR\\)")
                   (string-append #$output "/bin/"))
                  (("\\$\\(DESTDIR\\)\\$\\(SHAREDIR\\)")
                   (string-append #$output "/share/")))))
--8<---------------cut here---------------end--------------->8---

> +         (replace 'build
> +           (lambda _
> +             (setenv "CC" "gcc")

That would break cross-compilation. You should use something like:

--8<---------------cut here---------------start------------->8---
(string-append "CC=" ,(cc-for-target)).
--8<---------------cut here---------------end--------------->8---

> +             (setenv "LDFLAGS" "-static")

Why are we building a static version of the program?

There's also this linter warning:

gnu/packages/linux.scm:8649:14: libtree <at> 3.0.1: synopsis should start with an upper-case letter or digit

Thanks,

Mathieu




This bug report was last modified 3 years and 153 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.