mirror of
https://github.com/netwide-assembler/nasm
synced 2026-08-26 16:23:04 -04:00
No description
nasmlib/file.c included <stringapiset.h> directly (for MultiByteToWideChar()/CompareStringOrdinal()) without first including <windows.h>. Windows SDK headers like <stringapiset.h> are only guaranteed to work when pulled in through the normal <windows.h> pipeline, which sets up SDK-internal architecture macros (_X86_, _AMD64_, ...) derived from the compiler's own _M_IX86/_M_X64/etc. Including them directly skips that setup and can fail with a 'No Target Architecture' #error from <winnt.h> -- which is exactly what happened building with a real cl.exe/nmake in CI. <windows.h> is deliberately *not* pulled in globally from compiler.h: it #defines NEAR and FAR as legacy no-op calling-convention keywords, which clash with NASM's own NEAR/FAR opflags bits (include/opflags.h). Keep the inclusion local to file.c, the only file that currently needs Windows API declarations, guarded by WIN32_LEAN_AND_MEAN to keep the exposed surface minimal. Confirmed fixed with a real MSVC (cl.exe/nmake) build in CI. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> |
||
|---|---|---|
| .github/workflows | ||
| asm | ||
| autoconf | ||
| common | ||
| config | ||
| contrib | ||
| disasm | ||
| doc | ||
| editors | ||
| include | ||
| macros | ||
| misc | ||
| Mkfiles | ||
| nasmlib | ||
| nsis | ||
| output | ||
| perllib | ||
| stdlib | ||
| templates | ||
| test | ||
| tools | ||
| travis | ||
| win | ||
| x86 | ||
| zlib | ||
| .editorconfig | ||
| .gitattributes | ||
| .gitignore | ||
| .travis.yml | ||
| AUTHORS | ||
| autogen.sh | ||
| ChangeLog | ||
| CHANGES | ||
| configure.ac | ||
| INSTALL | ||
| LICENSE | ||
| Makefile.in | ||
| nasm.spec.in | ||
| nasm.spec.sed | ||
| nasm.txt | ||
| ndisasm.txt | ||
| README.md | ||
| SubmittingPatches | ||
| travis.mak.in | ||
| version | ||
| version.pl | ||
NASM, the Netwide Assembler
Many many developers all over the net respect NASM for what it is: a widespread (thus netwide), portable (thus netwide!), very flexible and mature assembler tool with support for many output formats (thus netwide!!).
Now we have good news for you: NASM is licensed under the "simplified" (2-clause) BSD license. This means its development is open to even wider society of programmers wishing to improve their lovely assembler.
Visit our nasm.us website for more details.
With best regards, the NASM crew.