reactos/sdk/tools/spec2def
Timo Kreuzer 6e80f4d037 [SPEC2DEF] Set ordinals explicitly in export def file
The reason is that dlltool orders the exports differently than MSVC builds (MSVC orders the exports by symbol name, rather than by export name), so we rely on sorting in the spec file, which was only respected, when ordinals were put into the def file.
On MSVC builds it is left to the linker to determine the correct order, which helps to get the differences between architectures right (different symbol decoration, difference between order for functions like NtLoadKey vs NtLoadKey2, which results from the stdcall decoration on x86, which is missing on other architectures.

TODO: To correctly handle non-x86 architectures with GCC builds, spec2def would need to reorder the export list based on symbol names, which would work for C functions, by taking the calling convention into account, but would require an extra c++-stdcall calling convention to be added to know the corresponding symbol starts with "?".
2020-01-03 13:00:45 +01:00
..
spec2def.c [SPEC2DEF] Set ordinals explicitly in export def file 2020-01-03 13:00:45 +01:00