Closed Bug 1417663 Opened 7 years ago Closed 3 years ago

Don't clobber PATH

Categories

(Firefox Build System :: MozillaBuild, task)

task
Not set
normal

Tracking

(Not tracked)

RESOLVED DUPLICATE of bug 1725895

People

(Reporter: jrmuizel, Unassigned)

Details

I've run into this a bunch of times and it's a pain to have to remember. I can't think of any reason that just appending our things to PATH would not be sufficient to get what we need.
This probably mattered more back to the days when we were still calling the MSVC vcvars scripts from start-shell*.bat and didn't have as much control over the PATH setting they did. Now that start-shell.bat only does minimal work in that respect, maybe we can revisit it and just prepend everything. What are your thoughts, Greg?
Flags: needinfo?(gps)
The current/clobber method is more robust because the end state if very well-defined and we don't have to worry about the user's tools from "leaking" into the MozillaBuild environment. For example, if the user has a Python install not provided by MozillaBuild and they've `pip install`'d a program, we could find ourselves using a Python/.exe from non-MozillaBuild Python and this could lead to chaos. Repeat that for every other tool provided by MozillaBuild. While I sympathize with the argument for inheriting the user's PATH, we've almost gotten to 2018 without it being a big enough deal to change. I'd prefer to stay the course and tell people to adjust PATH in their ~/.profile if they want to customize the environment.
Flags: needinfo?(gps)

If MozillaBuild's entries are prioritized in the PATH, then ideally it will be acceptable to inherit the system path - that's the plan as part of the port to MSYS2 anyways.

The amount of issues there's been around tools not being in the path (cargo, git cinnabar, etc, etc) has made the path resetting less worthwhile.

Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → DUPLICATE
Product: mozilla.org → Firefox Build System
You need to log in before you can comment on or make changes to this bug.