unofficial mirror of bug-guix@gnu.org 
 help / color / mirror / code / Atom feed
From: Hartmut Goebel <h.goebel@crazy-compilers.com>
To: Zhu Zihao <all_but_last@163.com>
Cc: 45193@debbugs.gnu.org
Subject: bug#45193: Wrapper of Qt programs doesn't extend existing environment variable
Date: Sat, 19 Dec 2020 14:13:11 +0100	[thread overview]
Message-ID: <1cc6eb46-813b-ba3c-f796-30d545f35941@crazy-compilers.com> (raw)
In-Reply-To: <86wnxns81f.fsf@163.com>

[-- Attachment #1: Type: text/plain, Size: 2002 bytes --]

Zhu Zihao wrote

> When building QT program, Guix builder populates qt related 
> environmentvariable, and wrap-qt-program just record it into wrapper.
>
> However, the wrap behaviour in qt-build-system is quite different, 
> itsearch all inputs and mark them should be included in envvar 
> definitionif correspond directory exists.

This will have the same result in must cases:

The environment variables used in qt-utils are defined as 
"native-search-paths" by some package. So these variables will be set 
when creating the build environment, based in the inputs. So if the 
package does not touch these variables, the output should be the same 
(beside perhaps the order).

When using the environment-variables, this would allow the package 
definition to remove unwanted parts. Nevertheless this is cumbersome 
(fetching the input, string-append, manipulating the variable value). 
And AFAIS none of the pacakges using wrap-qt-program does this.

I agree that leaking the environments variables from the build 
environment to the package is not a good idea. Also we might want to add 
some filters to avoid all imports (including cmake) are going into the 
wrapping variables - which is much easier when dealing with inputs nor 
strings.


> Another difference is, wrap-qt-program will include the directory 
> ofoutput in envvar but qt-build-system won't do.

If I understand the code correctly,  line 103 of qt-build-system also 
handle the output directories

                              (append (list directory)
                                      input-directories))))

and the qt-build-system should even handle different outputs (while 
qt-tuils does not):

   (for-each handle-output outputs)

(I may be wrong on this, please double check.

-- 
Regards
Hartmut Goebel

| Hartmut Goebel          |h.goebel@crazy-compilers.com                |
|www.crazy-compilers.com  | compilers which you thought are impossible |


[-- Attachment #2: Type: text/html, Size: 2986 bytes --]

  parent reply	other threads:[~2020-12-19 13:14 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-12  9:11 bug#45193: Wrapper of Qt programs doesn't extend existing environment variable Zhu Zihao
     [not found] ` <handler.45193.B.160776432713396.ack@debbugs.gnu.org>
2020-12-12  9:19   ` bug#45193: Acknowledgement (Wrapper of Qt programs doesn't extend existing environment variable) Zhu Zihao
2020-12-14 20:45 ` bug#45193: Wrapper of Qt programs doesn't extend existing environment variable Mark H Weaver
2020-12-15  1:50   ` Zhu Zihao
2020-12-17 11:35   ` Zhu Zihao
2020-12-19 13:13 ` Hartmut Goebel [this message]
2020-12-19 18:20   ` Zhu Zihao
2020-12-19 19:12     ` Hartmut Goebel
2021-01-10 16:34   ` Zhu Zihao
2021-01-11  8:17     ` Hartmut Goebel

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

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1cc6eb46-813b-ba3c-f796-30d545f35941@crazy-compilers.com \
    --to=h.goebel@crazy-compilers.com \
    --cc=45193@debbugs.gnu.org \
    --cc=all_but_last@163.com \
    /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 public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).