NASM - The Netwide Assembler

NASM Forum => Using NASM => Topic started by: macaswell on November 14, 2010, 05:26:34 AM

Title: TroubleShoot: Fatal error: Unable to open included file
Post by: macaswell on November 14, 2010, 05:26:34 AM
Hi, I've written an OS out of nasm, called Casnix (http://casnix.sourceforge.net/).
This is my first build of the OS at a finished test version, I just need to see if there's any errors, all the code is written.
I'm using cygwin, and I can compile the boot loader, but when I try to compile the kernel...

Kernel source tree:

kernel.asm
features/
   cli.asm
   basic.asm
   math.asm
   ... (lots of files)

Before I completed the test version, I could compile the kernel, but now:

$ nasm -w+orphan-labels -f bin -o kernel/kernel.bin kernel/kernel.asm

kernel/kernel.asm:360: fatal: unable to open include file 'features/cli.asm'

The file cli.asm does exist in the path that it is included to, and I can't find any code error that would cause this.  What's happening?

-Matthew Caswell
Title: Re: TroubleShoot: Fatal error: Unable to open included file
Post by: macaswell on November 14, 2010, 05:39:51 AM
Okay, so I was typing in the wrong file name.  The kernel source is 'casnix.asm'.  But still, I get the same error.
Title: Re: TroubleShoot: Fatal error: Unable to open included file
Post by: Frank Kotler on November 14, 2010, 06:37:41 AM
Code: [Select]
%include "kernel/features/cli.asm"
; etc.

?

... or "nasm -f bin -o kernel/kernel.bin -Ikernel/ kernel/casnix.asm"?
("orphan-labels" should be "on" by default, with a reasonably recent version of Nasm)

... or build it from the "kernel" directory rather than the one above it?

I suppose I could try this, since you supply code... brb.

Best,
Frank

Title: Re: TroubleShoot: Fatal error: Unable to open included file
Post by: Frank Kotler on November 14, 2010, 06:46:56 AM
Nope. Not finding any files. There's a reason Nasm has more-or-less abandoned SourceForge. :)

Best,
Frank

Title: Re: TroubleShoot: Fatal error: Unable to open included file
Post by: macaswell on November 14, 2010, 05:27:54 PM
Okay,  I didn't know about the orphan labels.  But I figured out the problem: Corrupt files/directories.  I fixed it, though.  Thank you.
Part of the time, I'm using nasm versions such as 0.98.36
Title: Re: TroubleShoot: Fatal error: Unable to open included file
Post by: macaswell on November 14, 2010, 07:23:01 PM
heh, still broken.  Compiling from the kernel directory....

Yeah, that worked.  Thankyou!
Title: Re: TroubleShoot: Fatal error: Unable to open included file
Post by: Frank Kotler on November 15, 2010, 04:43:37 PM
Okay. Nice new main page... but still no files! (No wonder Nasm can't find 'em! :) )

Best,
Frank

Title: Re: TroubleShoot: Fatal error: Unable to open included file
Post by: macaswell on November 16, 2010, 08:16:25 PM
No, there aren't any files on the page yet, 'cause I'm still adding functionality.