OSDev.org

The Place to Start for Operating System Developers
It is currently Tue Nov 21, 2017 11:26 am

All times are UTC - 6 hours




Post new topic Reply to topic  [ 2 posts ] 
Author Message
 Post subject: I created my cross-complier but I want to add some headers.
PostPosted: Tue Oct 03, 2017 4:04 am 
Offline

Joined: Sun Sep 24, 2017 8:21 am
Posts: 2
I originally created a cross compiler for a free standing kernel. I made it using the cross compiler guide for barebones all went well. Can I add more libraries without making a new cross compiler.


Top
 Profile  
 
 Post subject: Re: I created my cross-complier but I want to add some heade
PostPosted: Tue Oct 03, 2017 4:50 am 
Offline
Member
Member

Joined: Thu May 17, 2007 1:27 pm
Posts: 373
Libraries and header files are placed into /usr/lib and /usr/include. If you're using a cross compiler, those paths are not resolved relative to the filesystem root but to the directory that was specified by --with-sysroot. So specify --with-sysroot and then put your headers into <sysroot>/usr/include.

EDIT: IIRC, --with-sysroot is incompatible with --without-headers. To still build the freestanding --with-sysroot environment correctly, build GCC via
Code:
make all-gcc inhibit_libc=true


If you want to build an entire userspace, you might want into the OS-specific toolchain page in the wiki.


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 6 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