Closed Bug 1290045 Opened 3 years ago Closed 3 years ago

JS_STANDALONE is always set in js subconfigure when running under msys2's mingw python

Categories

(Firefox Build System :: General, defect)

defect
Not set

Tracking

(firefox50 fixed)

RESOLVED FIXED
mozilla50
Tracking Status
firefox50 --- fixed

People

(Reporter: glandium, Assigned: glandium)

References

Details

Attachments

(1 file)

The reason this happens is:

$ cat <<EOF >test.sh
export JS_STANDALONE=
env | grep JS_STANDALONE
python -c "import os; print 'JS_STANDALONE' in os.environ"
EOF

In a mozilla-build shell:
$ ./test.sh
JS_STANDALONE=
True

In a msys2 shell with mingw python:
$ ./test.sh
JS_STANDALONE=
False

Yet another way mingw python is different from native win32 python... despite being win32...
Python configure "environment variables" can be passed as actual
environment variables, but can also be passed as command line arguments
(unless they also make it to old-configure, which doesn't support that).

Passing empty environment variables is broken in msys2/cygwin: the
subprocess doesn't see the environment variable being set, so it can't
tell the difference between "not set" and "set to nothing", which has a
different meaning for python configure environment variables.

Currently, JS_STANDALONE is passed this way. Passing it as a command
line argument makes it properly passed down to the subconfigure.

Review commit: https://reviewboard.mozilla.org/r/67960/diff/#index_header
See other reviews: https://reviewboard.mozilla.org/r/67960/
Attachment #8775973 - Flags: review?(cmanchester)
Comment on attachment 8775973 [details]
Bug 1290045 - Pass JS_STANDALONE as a configure argument, instead of an environment variable.

https://reviewboard.mozilla.org/r/67960/#review65188
Attachment #8775973 - Flags: review?(cmanchester) → review+
Pushed by mh@glandium.org:
https://hg.mozilla.org/integration/autoland/rev/70e0031ebf1c
Pass JS_STANDALONE as a configure argument, instead of an environment variable. r=chmanchester
https://hg.mozilla.org/mozilla-central/rev/70e0031ebf1c
Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla50
Product: Core → Firefox Build System
You need to log in before you can comment on or make changes to this bug.