gecko-dev/python/mozbuild
Aaron Klotz f9be0e1c7f Bug 1542830: Part 3 - Add ntdll_freestanding.lib to freestanding; r=mhowell,froydnj
The `freestanding` library is built with specific compiler flags to signify
that it is indeed freestanding code. That is, it does not depend on a
standard library.

One of the requirements of freestanding code is that the toolchain still
expects implementations of `memcpy`, `memmove`, `memcmp`, and `memset`.

I did briefly implement my own naive versions of these functions, but that
solution is less than ideal since the implementations must be `extern` and are
thus picked up by the entire `firefox.exe` binary. This denies the rest of
`firefox.exe` the benefit of optimized implementations. On Windows, the
sandbox is linked into `firefox.exe`, so we cannot just shrug and
assume that naive implementations will not have any effect on anything.

There are, however, optimized implementations of these functions that are
exported by `ntdll.dll`. They are not included in the `ntdll.lib` that is
included in the Windows SDK. Using `llvm-dlltool`, we can build an import
library containing the missing entries and then add that library to `OS_LIBS`.

Depends on D43156

Differential Revision: https://phabricator.services.mozilla.com/D43157

--HG--
extra : moz-landing-system : lando
2019-09-23 20:18:37 +00:00
..
dumbmake Bug 1575375 - Pull mozbuild tests out of make check. r=nalexander 2019-08-21 05:00:50 +00:00
mozbuild Bug 1542830: Part 3 - Add ntdll_freestanding.lib to freestanding; r=mhowell,froydnj 2019-09-23 20:18:37 +00:00
mozpack Bug 1575375 - Pull mozbuild tests out of make check. r=nalexander 2019-08-21 05:00:50 +00:00
setup.py Bug 1559975 - Make python/mozbuild lint with 'py2' and 'py3' r=catlee 2019-07-05 14:36:43 +00:00
TODO