Document and test env vars a bit better#6827
Conversation
| env = { | ||
| 'CC_FOR_BUILD': '"' + os.path.join(testdir, 'build_wrapper.py') + '"', | ||
| 'CC': '"' + os.path.join(testdir, 'host_wrapper.py') + '"', | ||
| } | ||
| crossfile = tempfile.NamedTemporaryFile(mode='w') | ||
| crossfile.write('''[binaries] | ||
| c = ['{0}'] | ||
| '''.format(os.path.join(testdir, 'host_wrapper.py'))) | ||
| crossfile.write('') |
There was a problem hiding this comment.
I don't have to change this test, as this is a non-breaking change. However, doing so makes it less redundant with the previous test, which exclusive uses the native and cross files with no environment variables.
b727296 to
7001c9e
Compare
|
@ePirat Let's not forget about this :). |
ePirat
left a comment
There was a problem hiding this comment.
Sounds like a very good change to me, to be compatible with the existing conventions for these variables.
7001c9e to
969f7ee
Compare
969f7ee to
6c0bf2b
Compare
See comment in code and the PR it references, mesonbuild/meson#6827, for details. We can remove entries from the cross file because they will be gotten from env vars now.
6c0bf2b to
52f1107
Compare
52f1107 to
d6d420d
Compare
Codecov Report
@@ Coverage Diff @@
## master #6827 +/- ##
==========================================
- Coverage 66.16% 66.12% -0.04%
==========================================
Files 406 406
Lines 86660 86660
Branches 19144 19144
==========================================
- Hits 57335 57307 -28
- Misses 24915 24933 +18
- Partials 4410 4420 +10
Continue to review full report at Codecov.
|
|
Updating the tests to help with env2cross seems like a great idea |
Since this PR was first opened, just about everything it was supposed to do already happened, so now it is just refining the docs and tests for existing behavior.