Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place! |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
12-18-2009, 09:40 AM
|
#1
|
Member
Registered: Jul 2008
Posts: 43
Rep:
|
What's the glibc version used to compile the kernel?
Hi all,
I am compiling my kernel using gcc version 4.4.1 (Ubuntu 4.4.1-4ubuntu8). My question is how can I find out which version of glibc used to build the kernel? Also, if an application needs to use glibc, where can be found? Should I have it on my file system?
Thanks.
|
|
|
12-18-2009, 09:58 AM
|
#2
|
Member
Registered: Oct 2009
Posts: 467
Rep:
|
Quote:
Originally Posted by pmil
Hi all,
I am compiling my kernel using gcc version 4.4.1 (Ubuntu 4.4.1-4ubuntu8). My question is how can I find out which version of glibc used to build the kernel? Also, if an application needs to use glibc, where can be found? Should I have it on my file system?
Thanks.
|
No version of glibc is used to build the kernel. Remember, it's a kernel - libc depends on it, not the other way around.
If you need to develop user-space applications which use the standard c library, you'll need to install your distro-specific development package, something like libc-dev or libc-devel.
Why do you ask?
|
|
|
12-18-2009, 10:34 AM
|
#3
|
Member
Registered: Jul 2008
Posts: 43
Original Poster
Rep:
|
Quote:
Originally Posted by JohnGraham
No version of glibc is used to build the kernel. Remember, it's a kernel - libc depends on it, not the other way around.
If you need to develop user-space applications which use the standard c library, you'll need to install your distro-specific development package, something like libc-dev or libc-devel.
Why do you ask?
|
First of all, thanks for the reply. Ok, so the kernel doesn't need libc to be build. Let's say that I have a hello world program like the following, which is dynamically linked:
Code:
#include <stdio.h>
int main() {
printf("Hello world!\n");
return 0;
}
At run time, the program will search for the printf() routine. Where it will search for the required library? Will it search under the /lib/ folder of the file system? Should somehow provide the glibc library under /lib/? If yes, what version of glibc should I put there? Btw, I am using a vanilla kernel and also my own file system.
Thanks.
Last edited by pmil; 12-18-2009 at 12:06 PM.
|
|
|
12-18-2009, 11:08 AM
|
#4
|
LQ 5k Club
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,519
|
' glibc ' is your system ( together with the kernel ).
And is of course always installed.
Never touch it, please. Changing any libc6 files :
Your system will stop working. For ever.
The command : dpkg -L libc6
will show the files.
You may need libc6-dev , the development files :
sudo apt-get install libc6-dev linux-libc-dev
.....
|
|
|
All times are GMT -5. The time now is 09:57 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|