Error: Unable to open include file #297
Replies: 1 comment 1 reply
|
Worth knowing exactly what NASM tries before blaming the paths, because the search is narrower than people usually assume. ip = omode & INC_EXACT ? NULL : strlist_head(ipath_list);
while (1) {
sp = nasm_catfile(prefix, file);
...
prefix = ip->str;
ip = ip->next;
}So it tries the name exactly as written — resolved against the current working directory, not against the directory of the file doing the Given it works on Windows and not on Linux with the same sources, three things are worth checking in this order. Case is the usual one. Linux filesystems are case-sensitive and NTFS effectively isn't, so Backslashes are the next suspect, and they bite hardest when paths are hardwired. On Linux Third, if the paths are relative rather than absolute, check where you're invoking nasm from. Since resolution is against the CWD and never the source file's directory, building from the project root versus from inside the source directory gives different results, and your Windows build may simply be run from a different place — by an IDE, say, rather than by hand. If none of those are it, |
Uh oh!
There was an error while loading. Please reload this page.
Hello everyone,
Compiling programs using NASM (3.02) under Windows 11 produces no errors while under Linux Mint 22.3 (Cinnamon) using NASM version 3.02rc13 compiled on Aug 15 2026 generates errors as per title and yet all files do exist and each file's path is hardwired correctly, I'm at my wits' end trying to figure out the mystery, would appreciate any kind of help and direction that might solve this issue, thank you.
All reactions