OSDev.org

The Place to Start for Operating System Developers
It is currently Mon Mar 18, 2024 10:15 pm

All times are UTC - 6 hours




Post new topic Reply to topic  [ 2 posts ] 
Author Message
 Post subject: need stdint.h using meaty skeleton
PostPosted: Fri Feb 05, 2016 8:36 am 
Offline
Member
Member

Joined: Sat Dec 19, 2015 10:48 am
Posts: 42
I'm trying to compile and link meaty skeleton for debugging. I'm doing it with command line in linux Ubuntu. There are several header files in tty.c which have very little meat to them, in particular, stdint.h. There is no such file in meaty skeleton, so the compiler is trying to use the one from the cross compiler. The one from the cross compiler has no definition of size_t or uint_16 types. It has the line:
# include_next<stdint.h> which gets nothing. Before I can debug tty.c linked with an assembly routine I must add debug option in the command line. I'm not using the makefile and shell files to build this for debugging - I'm using the command line as follows:

i686-elf-gcc tty.c -c && i686-elf-gcc -gdwarf kb1.o tty.o -o tty.o -ffreestanding -fbuiltin -Wall -Wextra -nostdlib -lk -lgcc

with header files copied to appropriate locations. But there is no stdint.h file. I can't proceed without it. I seem to be getting by without stddef.h

TIA. Bill S.


Top
 Profile  
 
 Post subject: Re: need stdint.h using meaty skeleton
PostPosted: Fri Feb 05, 2016 5:27 pm 
Offline
Member
Member
User avatar

Joined: Wed Aug 05, 2015 5:33 pm
Posts: 159
Location: Drenthe, Netherlands
Plz read this first.
At the very least try to google things like this.

But for what it's worth:
  • size_t isn't part of stdint.h, it's in stddef.h.
  • stdint.h contains standard types like uint16_t, int16_t etc. Not custom definitions like uint_16.
Both files are part of a properly compiled gcc like you get after following the instructions on the wiki.

bilsch01 wrote:
i686-elf-gcc tty.c -c && i686-elf-gcc -gdwarf kb1.o tty.o -o tty.o -ffreestanding -fbuiltin -Wall -Wextra -nostdlib -lk -lgcc
I hope you just typed this in a hurry and left stuff out because this is wrong on so many levels.

_________________
"Always code as if the guy who ends up maintaining it will be a violent psychopath who knows where you live." - John F. Woods

Failed project: GoOS - https://github.com/nutterts/GoOS


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

All times are UTC - 6 hours


Who is online

Users browsing this forum: Bing [Bot] and 5 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group