#14296: Force consistency of $LD and $AS with $CC
----------------------------+-----------------------------------------------
Reporter: jdemeyer | Owner: GeorgSWeber
Type: defect | Status: new
Priority: major | Milestone: sage-5.9
Component: build | Resolution:
Keywords: | Work issues:
Report Upstream: N/A | Reviewers:
Authors: | Merged in:
Dependencies: | Stopgaps:
----------------------------+-----------------------------------------------
Comment (by leif):
In `sage-env`, `stdout` of `command -v ...` should also be redirected to
`/dev/null`.
Replying to [comment:10 jdemeyer]:
> leif, would you agree with keeping the changes to `sage-env` in
[attachment:14296_ld_as.patch]
This should be ok, although a user might still intentionally have a
different `ld` or `as` first in his/her `PATH`. (Then we'd have to
document that setting `AS` and/or `LD` might be necessary to get the
previous behaviour.)
> but changing the detection in `spkg/install` to an error if the values
of as or ld don't match (where there would never be an error if we're
building GCC, since the newly-built GCC would use the setting of `$LD` as
default linker).
Hmmm. It should be possible to override the error (probably by setting
`SAGE_PORT`).
There are some subtle issues with the comparisons, not sure how artificial
the following scenarios are:
* `AS` and/or `LD` are set to (e.g.) `as -foo` or `ld -foo`, respectively
(likewise `/path/to/as -foo` etc.).
Then e.g. `command -v "$AS"` gives an error (whilst `command -v $AS`
probably doesn't.)
* `AS` and/or `LD` are set to something like `as-2.22`, while (e.g.) GCC
was configured with something else.
* Opposite of the previous: GCC was configured to (e.g.) use `as-2.22`
(or `/path/to/as`, or `/path/to/as-2.22`), while e.g. `AS` is meanwhile
just `as`, `as-2.23`, or `/other/path/to/as` etc.
* Probably more weirdnesses.
Filename mismatches don't necessarily mean that the programs are
different, or incompatible.
I don't think one couldn't work around the above situations by changing
the setup, but this might be difficult for "ordinary" users, especially
those without admin rights.
----
How does this fit your "If a user sets $VAR, assume he/she knows what
he/she's doing, so don't override it; he/she doesn't need a nanny."? ;-)
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/14296#comment:11>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica,
and MATLAB
--
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-trac?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.