LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Linux From Scratch
User Name
Password
Linux From Scratch This Forum is for the discussion of LFS.
LFS is a project that provides you with the steps necessary to build your own custom Linux system.

Notices


Reply
  Search this Thread
Old 07-30-2009, 07:21 AM   #1
coolsami
LQ Newbie
 
Registered: Jul 2009
Posts: 6

Rep: Reputation: 0
Smile Glibc make error


Hello Friends,

I am trying to compile my LFS using RHEL 5, so when i try to compile the glibc the make command throws the following error :

/mnt/lfs/build/glibc-build/glibc-2.8-20080929/nscd/nscd_helper.c:406: undefined reference to `__sync_val_compare_and_swap_4'
/mnt/lfs/build/libc_pic.os: In function `*__GI___libc_freeres':
/mnt/lfs/build/glibc-build/glibc-2.8-20080929/malloc/set-freeres.c:39: undefined reference to `__sync_bool_compare_and_swap_4'
collect2: ld returned 1 exit status
make[1]: *** [/mnt/lfs/build/libc.so] Error 1
make[1]: Leaving directory `/mnt/lfs/build/glibc-build/glibc-2.8-20080929'
make: *** [all] Error 2

Friends would really appreciate your help.

Thanks
Sammy
 
Old 07-30-2009, 07:58 AM   #2
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405
Hi,

Please give us the info needed:

- which LFS are you trying to build,
- which chapter (5 or 6),
- is RHEL 5 suitable as base for LFS,
- did the previous steps build without problems.
 
Old 07-30-2009, 08:29 AM   #3
coolsami
LQ Newbie
 
Registered: Jul 2009
Posts: 6

Original Poster
Rep: Reputation: 0
Glibc make error

Quote:
Originally Posted by druuna View Post
Hi,

Please give us the info needed:

- which LFS are you trying to build,
- which chapter (5 or 6),
- is RHEL 5 suitable as base for LFS,
- did the previous steps build without problems.


Hello drunna,

appreciate ur quick response below is my answer for ur questions :

- which LFS are you trying to build,
Am not sure abt this question but am using LFS book ver 6.4 and using rhel 5 as a host OS not using livecd.

- which chapter (5 or 6),
its for chapter 5 section 5.7. Glibc-2.8-20080929.

- is RHEL 5 suitable as base for LFS,
I think it should be it does below is a line from LFS book :

"The LFS system will be built by using a previously installed Linux distribution (such as Debian, Mandriva, Red Hat, or
SUSE)."

- did the previous steps build without problems
Yes i was able to complete following sections in the book :

5.4. Binutils-2.18 - Pass 1
5.5. GCC-4.3.2 - Pass 1
5.6. Linux-2.6.27.4 API Headers

But am stuck on this section 5.7.

Youe help will be appreciated.

Thanks
Sammy
 
Old 07-30-2009, 08:45 AM   #4
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405
Hi,

First of all: Use regular english, not text/sms/whatever speak! It's annoying and not needed, your not limited to 140 chars per message.....

Quote:
- which LFS are you trying to build,
Am not sure abt this question but am using LFS book ver 6.4 and using rhel 5 as a host OS not using livecd.
I hope you also use the packets that belong to 6.4 (did you use chapter 3.2 to download all?).
Before you continue make sure you have the correct package versions that go with the book version you are using.

Quote:
- is RHEL 5 suitable as base for LFS,
I think it should be it does below is a line from LFS book :

"The LFS system will be built by using a previously installed Linux distribution (such as Debian, Mandriva, Red Hat, or
SUSE)."
So I can safely assume that you did not do chapter iv. Host System Requirements......
Make sure rhel is suitable before you continue.

Another thing I noticed: The LFS books suggest using $LFS/sources for storage and starting point for the builds. Is there a particular reason you use $LFS/build?
 
Old 07-31-2009, 12:16 AM   #5
coolsami
LQ Newbie
 
Registered: Jul 2009
Posts: 6

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by druuna View Post
Hi,

First of all: Use regular english, not text/sms/whatever speak! It's annoying and not needed, your not limited to 140 chars per message.....


I hope you also use the packets that belong to 6.4 (did you use chapter 3.2 to download all?).
Before you continue make sure you have the correct package versions that go with the book version you are using.


So I can safely assume that you did not do chapter iv. Host System Requirements......
Make sure rhel is suitable before you continue.

Another thing I noticed: The LFS books suggest using $LFS/sources for storage and starting point for the builds. Is there a particular reason you use $LFS/build?
Hello drunna,

I apologies for my language will ensure in future.

Coming back to the issue here below is my answer :

I did download all the packages and patches from the links mentioned in the book 6.4 and even patched it with the one mentioned in the book and they are the version mentioned in the book.

And as per the book my rhel is perfect because the only thing they have mentioned is RHEL is suitable host OS provided you install all development packages during installation of it please check the line from the book and i have done complete installation of the OS :

"The LFS system will be built by using a previously installed Linux distribution (such as Debian, Mandriva, Red Hat, or
SUSE). This existing Linux system (the host) will be used as a starting point to provide necessary programs, including
a compiler, linker, and shell, to build the new system. Select the “development” option during the distribution
installation to be able to access these tools."

And there is no specific reason to use $LFS/build directory what i believe according to the book is that we can use any build directory so i just created that one for me for easier understanding what i thought $LFS/sources is used to keep all the packages and patches.

Please correct me if am wrong as i am a newbie for Linux.

Again appreciate your help buddy.

Thanks
Sammy

Last edited by coolsami; 07-31-2009 at 12:19 AM. Reason: typo was there and missing information
 
Old 07-31-2009, 01:08 AM   #6
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405
Hi again,

Did or did you not check all the packages mentioned in iv. Host System Requirements? I still think you did not and you should.

In general just about all the distro's are basically suitable as base for LFS. But... some need extra packages, some packet versions are incorrect (too low or too high) etc etc.

The $LFS/build dir is ok, as long as it is a choice by you.
 
Old 07-31-2009, 01:17 AM   #7
coolsami
LQ Newbie
 
Registered: Jul 2009
Posts: 6

Original Poster
Rep: Reputation: 0
Hello drunna,

issue is fixed once i used the $LFS/sources as the build directory issue is resolved.

it was my fault i did not read it properly again thanks for your help and support.

Thanks
Sammy
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
make error with glibc-2.3.4 -fatbass- Linux From Scratch 1 12-20-2017 11:07 AM
Glibc make error lfs_rocks Linux From Scratch 5 02-04-2008 11:13 PM
glibc make error crik91 Linux From Scratch 3 01-14-2008 06:05 AM
Glibc 2.4 *Make error* devoid Linux - Software 1 06-12-2006 04:54 PM
Glibc make error Edgington Linux From Scratch 7 12-23-2004 05:25 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Linux From Scratch

All times are GMT -5. The time now is 02:37 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration