Page 1 of 2

Compilation test error

Posted: Mon Feb 27, 2017 3:24 am
by Thunderbirds747
G'day mates,
Tim here,
I have trouble with the makefile. I tried to make a makefile and as a result, the output says: "[Error] bootinfo.h: No such file or directory".
I tried adding the header for my test OS and it didn't work. I know I didn't yet finish the project, but I was trying to figure out the problem, but it didn't work. Any suggestions?

Sincerely,
Tim Ryazanoff (Tim Williams)

Re: Compilation test error

Posted: Mon Feb 27, 2017 4:26 am
by dozniak
It says "Tim" five times in this post but not a single word about your project structure or contents of your makefile.

Re: Compilation test error

Posted: Mon Feb 27, 2017 5:15 am
by iansjack
TimRyazanoff wrote:the output says: "[Error] bootinfo.h: No such file or directory".
Any suggestions?
I suggest that bootinfo.h doesn't exist in your INCLUDE path.

Re: Compilation test error

Posted: Mon Feb 27, 2017 5:34 am
by Solar
Well, it isn't where the computer is looking for it. So check your assumptions. (Paths, file names, current work directories, etc.)

Re: Compilation test error

Posted: Mon Feb 27, 2017 8:37 am
by Thunderbirds747
Here is the example: #include <bootinfo.h>
#include <fat.h> and that's it. Note that I am not yet done with coding. The kernel is well organised by folders, such as: Kernel, Lib, FAT12, floppy, Include and proc.

Re: Compilation test error

Posted: Mon Feb 27, 2017 10:29 am
by Solar
So where is bootinfo.h, and how did you tell your compiler where to find it?

Oh, and while we're at it:

Do not try to learn C, debugging C, the intricacies of your toolchain, and writing an operating system at the same time. Please.

Re: Compilation test error

Posted: Mon Feb 27, 2017 10:33 am
by iansjack
I have no doubt that you are #including the file. But that doesn't guarantee that it exists in your INCLUDE path, does it? The compiler is telling you that it doesn't.

Re: Compilation test error

Posted: Mon Feb 27, 2017 10:51 am
by Thunderbirds747
Problem no. 2: "**recipe commences before first target. Stop".
Linked bootinfo.h in Dev C++, but MinGW is being a real pain in the arse. I use Dev C++ with GCC in MinGW.

Re: Compilation test error

Posted: Mon Feb 27, 2017 12:43 pm
by iansjack
Have you tried Googling that error message? It's probably more productive than expecting people to guess what your makefile looks like.

Re: Compilation test error

Posted: Mon Feb 27, 2017 1:06 pm
by Thunderbirds747
I tried, but they were all for different IDEs, especially Linux. I am using Dev-C++, as I told you, so I need a bit of assistance, then I can go on my own.

Re: Compilation test error

Posted: Mon Feb 27, 2017 1:11 pm
by iansjack
So we're left with guessing. I'm not sure that's very productive.

Hint: I'm not convinced that which IDE you are using is relevant.

Re: Compilation test error

Posted: Mon Feb 27, 2017 2:23 pm
by Schol-R-LEA
iansjack wrote:Hint: I'm not convinced that which IDE you are using is relevant.
It may be, at least in regards to advice on ways to check how it is configured; it may be using a different search path than the one you think it is using, for example. In other words, it may matter iff you aren't sure what it is doing, and need help with the IDE itself (as opposed to the programming).

However, such a problem is something that should be addressed before you even consider OS dev. You might also find it better to try a message board specifically about C++ and/or the IDE you are using (and by that I assume you mean the Orwell fork; if you are using the older, unmaintained Bloodshed Dev-C++, then for Eris' sake, delete it right now and get one that has been updated more recently than 2005). I have used Dev-C++ before, and a few others here may have as well, but I doubt there is anyone here who is an expert on it.

EDIT: OK, I can see from the screenshot that it is indeed the current version of Orwell Dev-C++. That's at least something. Unfortunately, checking the SF repo, it looks like that fork has stalled as well, with no updates since June 2015. Have you considered using something like Eclipse, Code::Blocks, or Geany, instead? For that matter, you might want to set aside the IDEs entirely and get your hands dirty with the command-line tools for a bit, if you haven't done that before, as it can really help you understand the things those tools are doing for you - automation is great, but to use it well you have to understand what is being automated.

Re: Compilation test error

Posted: Mon Feb 27, 2017 2:37 pm
by iansjack
The "recipe" error message normally refers to a malformed makefile raher than a search path.

But this is all just guessork without a sight of the code or the makefile.

i agree that this is not the best forum to deal with such errors.

Re: Compilation test error

Posted: Tue Feb 28, 2017 2:44 am
by Thunderbirds747
I have seen that my project is a Win32 Console Application, although I started on an empty project (no files whatsoever), but I will keep trying to get it to work.

Re: Compilation test error

Posted: Tue Feb 28, 2017 3:07 am
by iansjack
The cause of your error is listed in the error messages section of the GNU make manual. https://www.gnu.org/software/make/manua ... ed-by-Make

Check your makefile. (No-one else can do so.)