LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux From Scratch (https://www.linuxquestions.org/questions/linux-from-scratch-13/)
-   -   Binutils just DENY to install!!! (https://www.linuxquestions.org/questions/linux-from-scratch-13/binutils-just-deny-to-install-556069/)

help_a_newbie 05-23-2007 08:27 AM

Binutils just DENY to install!!!
 
Hi, all. I'm a new user here. I just have a problem when trying to install Binutils that's gonna drive me crazy!

Well, first things first. I recently downloaded the Linux from scratch book (version 6.2) and the lfs live cd from the official linux from scratch site. I started building my lfs, and everything seemed to go right.
I'm now at the chapter 5.3 (Binutils-2.16.1 - Pass 1). When I type the command "mkdir -v ../binutils-build" it says that it can't create the directory folder, because the access denied. Anyway, i was able solve this problem and go on. After I typed "cd ../binutils-build" it was time to prepare them for compilation (as i've learned the time command was not necessary). When i typed this command: "../binutils-2.16.1/configure --prefix=/tools --disable-nls" it said that "No such file or directory existed". What shall i do?

I would really appreciate your help, as i'm a newbie. I hope I'll learn a lot while building the lfs!

P.S. Do you know if I can shut down my computer even if i haven't finished the whole building? If yes, how (without loosing all of the progress i've made).

Thank you and sorry for my bad english (maybe)

:newbie:

druuna 05-23-2007 08:47 AM

Hi,
Quote:

....(Binutils-2.16.1 - Pass 1). When I type the command "mkdir -v ../binutils-build" it says that it can't create the directory folder, because the access denied. Anyway, i was able solve this problem and go on.
You don't mention this but you are probably executing the command from the wrong directory. You should first unpack/tar the package and enter the newly created directory (as stated in chapter 5.1).

In the case of binutils, you should be in $LFS/sources/binutils-2.16.1 and enter the mkdir -v ..... command from there.

You also don't tell how you solved the problem, all the other problems are probably related to the above.

Quote:

After I typed "cd ../binutils-build" it was time to prepare them for compilation (as i've learned the time command was not necessary). When i typed this command: "../binutils-2.16.1/configure --prefix=/tools --disable-nls" it said that "No such file or directory existed". What shall i do?
Without knowing how you solved the first problem, and more importent: Was it done correctly, it's impossible to say what went wrong.

Quote:

P.S. Do you know if I can shut down my computer even if i haven't finished the whole building? If yes, how (without loosing all of the progress i've made).
There's a LFS hint about that subject. It's a bit outdated, but with a little common sense you can adjust it.

Hope this helps.

biniou 05-23-2007 08:47 AM

Hello !

Did you correctly unpack the sources and enter the directory ?

Regards,
Biniou

biniou 05-23-2007 08:52 AM

For your question concerning the shutdown of the computer during build :

You can safely leave during chapter 5 as far as when you return you set $LFS, mount the partition and log as lfs user.

In chapter 6, you can leave, but you have to set $LFS, mount the partition, populate /dev and mount /proc (etc) filesystems and chroot the correct way (all these steps are desribed in the book).

After chapter 6, you can leave and come back with the same, but with an adjusted chroot command (everything in the book again)

So, don't worry, you won't loose anything if you follow the book correctly ;)

help_a_newbie 05-23-2007 09:02 AM

thank you for your replies!
Well, druuna, it may seem funny but i don't know how i solved the problem! The sure thing is that I hadn't done what you just told me. So, after sourcing the bash (source ~/.bash_profile) I type unpack/tar? and then how do i enter the $LFS/sources/binutils-2.16.1 dir? I would really appreciate your help and sorry for those noob questions.

And biniou, thank you for solving the "shut down" issue but i really don't know how to unpack, I just stop in the command mentioned above and i don't know what to type next!

help_a_newbie 05-23-2007 09:13 AM

i've just read the lfs hint druuna. It was prety informative thanx

druuna 05-23-2007 09:18 AM

Hi,

Quote:

So, after sourcing the bash (source ~/.bash_profile) I type unpack/tar? and then how do i enter the $LFS/sources/binutils-2.16.1 dir?
After becoming user LFS and sourcing .bash_profile:

cd $LFS/sources
tar jxf binutils-2.16.1.tar.bz2
cd binutils-2.16.1
mkdir -v ../binutils-build
cd ../binutils-build
.
.
.


You should unpack the package and enter the created directory (it's in one of the 'important' boxes in chapter 5.1).

Quote:

I would really appreciate your help and sorry for those noob questions.
BTW: A certain level of experience is expected when building a LFS system. If you are really new at this, expect to do a lot of reading and trial/error. The upside is learning a lot during the process.

help_a_newbie 05-23-2007 09:31 AM

Thanx druuna! You are really helping me. I think that i have to read alot too, but i'm planning to do it in summer, now i have to study for school exams!

Anyway, I'll try it. and one last question, do i have to repeat this command for every package I install? (gcc, glibc, etc)

thanx

biniou 05-23-2007 09:33 AM

Corporate summary:

before issuing the commands for a package:
cd $LFS/sources
tar xf package.tar.bz2 (or tar xzf package.tar.gz)
cd package
(of course, you'll have to replace "package" by the actual name of the package)
(this will extract the package and place you in the directory)

After the commands for the package:
cd ..
rm -rf package
(this will erase the source/build directory as recommended)

Please, be patient enough to read completely the book (yes, for A to Z ... And yes, it takes time !)

help_a_newbie 05-23-2007 09:40 AM

I know, I've read once the chapters 1 to 5. I understood that i had to replace the package. And thank you for the command that erases the packages after the installation, sth was mentioned it the book but i couldnt understand, thanx for makin it clear for me, and for your (really) quick posts! if i have any other problems i'll post my questions, u gyus help me alot!

thanx again and again

help_a_newbie 05-24-2007 10:12 AM

hi, it's me again.
Well, druuna, i followed your advice and ran these commands. but still i get a problem from the tar programm. here's what i get

"tar: binutils-2.16.1.tar.bz2: cannot open: no such file or directory"
and a number of other problems linked to this. I was doing everything right, sourced the bash profile, typed your commands but... i guess i'm sooooo unlucky :(.

Anyway, if you could help me solve this one too, i'd really appreciate it! Why linux has to be so hard?

druuna 05-24-2007 10:22 AM

Hi,

The error states that the binutils package isn't there.

Where are your source packages located (binutils-2.16.1.tar.bz2 and all other packages)? They should reside in $LFS/sources (as stated in chap. 3.1).

help_a_newbie 05-24-2007 11:46 AM

In chapter 3.1 i type:

mkdir -v $LFS/sources
chmod -v a+wt $LFS/sources

Is there anything else i should do?

druuna 05-24-2007 11:56 AM

Hi,

Read more carefully, this from chap 3.1:
Quote:

Downloaded packages and patches will need to be stored somewhere that is conveniently available throughout the entire build. A working directory is also required to unpack the sources and build them. $LFS/sources can be used both as the place to store the tarballs and patches and as a working directory. By using this directory, the required elements will be located on the LFS partition and will be available during all stages of the building process.
So I gather that you did not copy the packages and patches to $LFS/sources (yet).

help_a_newbie 05-24-2007 12:00 PM

No, coz i dont know how to. This book is not so good written for newbies. What's the command i have to give to copy all this files? (Oh, god! I don't know what to do! If i start getting on your nerves plz tell me, I know i do alot of questions!)

druuna 05-24-2007 12:09 PM

Hi,

I don't mind answering questions, but if your linux knowledge is this basic (nearly none-existing??) installing LFS is going to be very, very difficult..... And you probably need a lot of help in the weeks to come ;)

That said:

cp is used to copy files from one place to another. cp /path/to/files/* $LFS/sources/ will do the trick. I don't know where your packages are located, so substitute /path/to/files/ with the proper directory.

Here's an URL that's cp related, including a few basic examples.

Hope this helps.

help_a_newbie 05-24-2007 12:16 PM

Yes, my knowledge to linux is nearly zero! I don't know if i chose the better way to start! As i said before, i use a live cd, so the files must be somewhere there, right? I hope I'll be able to find them. Anyway, thanx for your help, and, I think I'll hire a professional to my home, coz I'll fill a lot of pages with questions here!!! (joke):)

Ok, cu when the next problem will occur!

help_a_newbie 05-24-2007 12:30 PM

Ok, here's the next problem (imagine! i have another problem in 5 minutes!) I search the live cd and it only contains a file named "ROOT" with the extension "EXT2". Do i have to unpack this whole file into the directory or what?

druuna 05-24-2007 12:45 PM

Hi,

Did you boot from the liveCD? If not, do so. This will be your host system.

There should be a sources directory on the liveCD as well (/sources, if I remember correctly), which holds the packages (and the patches).

help_a_newbie 05-24-2007 12:51 PM

of course i boot from the live cd.
But, i opened the contents of it has a file "ROOT.EXT2" that is 485MB and a boot directody that holds the files to boot. Maybe "ROOT.EXT2" is all the packages and patches together? Then how can i copy them all? I wonder if live cd was a bad idea. if i decide to turn to mandriva for host system, will it work (Mandriva One 2007, not sure if all the packages and patches are installed)

I wish i had your level of knowledge!

druuna 05-24-2007 12:59 PM

Hi again,

The liveCD is the best host there is: It's made especially for being a host for building (C|H)LFS.
After booting there should be more then a boot directory and a root.ext2 file. Did you (have to) enter extra boot option during startup?

What does ls /sources show?

help_a_newbie 05-24-2007 02:42 PM

i see the contents with the windows explorer. i must boot from the cd to see the contents? how can i? the only extra option is to press F1 for more options.

PS: Sorry for not answering, i wasnt able to be on net, my dad wanted the modem...

druuna 05-24-2007 03:52 PM

Hi,

You're not making too much sense.....

In post 20 you tell me that you did boot from the cd, in post 22 you ask me how to do that? Did or didn't you boot from the cd? You do know how to boot from cd (insert cd in drive, restart/reboot computer)?

help_a_newbie 05-25-2007 04:30 AM

Hi,

well, i opened the cd contents in windows, but when i duild the lfs i boot from cd.
anyway, i'm now in a good way. i haven't noticed at the beggining of the boot, that the location was mentioned (it was /lfs-sources) so i managed to install the packs and the patches. i installed binutils succesfully (about 3 minutes) and i ran the command rm -rf binutils-2.16.1, as u said me. now i'm compiling gcc, it's gonna take too much time!!

Anyway, I'm happy i finally made it!! let's see what the next problem will be. Can i ask you sth more? What will I be able to do when i'll complete the lfs? it will be like any other linux? Or do i have to build blfs as well?

Thanx!

druuna 05-25-2007 04:53 AM

Hi,

Glad to read that you are finally on your way!

LFS is 'just' a base linux system. After installing it you probably want to install certain parts of BLFS and/or packages that are not mentioned in BLFS. Which packages depend on what you want to do with your linux box.

Most people want a desktop environment, which includes X, a WM (KDE or Gnome is used a lot) and other (GUI based) programs (a browser, mailer etc etc).

Some will want a server environment, which needs other programs (X and all that goes with it isn't needed/wanted).

In the end it's all up to you.

Hope this clears things up.

Cluracan 05-25-2007 05:35 AM

After you've created the folder in chapter 3.1 and changed the permissions using the commands in the book:

mkdir -v $LFS/sources
chmod -v a+wt $LFS/sources

you just need to type in (if my memory serves me right):

cp -v /blfs-sources/* $LFS/sources

to copy the sources from the CD to the folder you created on your LFS drive.

EDIT: Sorry, just realized I missed the whole second page of posts, was wondering why the posts were fast and furious for a while and then just stopped... :-/

biniou 05-25-2007 07:35 AM

Hello !

Just now that I think of it ... At the end of LFS, you'll need to configure and build the kernel ... There are a huge amount of options, so if you have the possibility to gather informations on your hardware and what you use, maybe it's worth doing it ...

Indeed, LFS will bring you the base system (something you can boot and have a console), but if you use DHCP, you won't have networking ready (DHCP comes with BLFS), your mouse won't work as it does on LFS liveCD (GPM is part of BLFS), you won't be able to read correctly HTML files (lynx -> BLFS) and I don't even speak of eye candies in graphical environment (it took me 3 evenings to build a raw Xorg on my old PC)

help_a_newbie 05-26-2007 06:25 AM

hi, and thank you all for your answers.

Cluracan, u deserve especially thanx, coz i didn't know that i can copy all of the contents in the cd and till now i was doing it one by one package!!! Thanx.

Secondly, druuna, thanx for explaining me what lfs will be like when it is complete. so no gui at all, hu? anyway, if i ever finish it, I'll care about the graphical environment.

Thirdly, biniou, what is an Xorg? can you plz explain me how can i build it? thanx

and forthly, just another problem came up: I was compiling gcc package and, because it was gonna take a lil time, i thought i might do sth else. i left the computer to compile, and i went to eat sth. When I returned into my room the screen was off (like it had no signal from the computer) and when i tried to press any key the system wouldn't "wake up". When i also tried to press Num Lock, he green light on my keyboard didn't turn off and on (it was like the sysem crashed). What has happened? Can I avoid turning off the screen?

z3r0.0v3rrid3 05-26-2007 06:10 PM

Quote:

Originally Posted by help_a_newbie
No, coz i dont know how to. This book is not so good written for newbies. What's the command i have to give to copy all this files? (Oh, god! I don't know what to do! If i start getting on your nerves plz tell me, I know i do alot of questions!)


It's written pretty well, but keep in mind this book assumes you know basic linux commands and basic knowledge on how/why things happen, I don't think it was ever intended for starters.

help_a_newbie 05-27-2007 03:40 AM

hi,

i know that z3r0.override, but i think they should publish a book for total newbies also. Anyway, can anyone help me with that screen problem?

Thanx!

biniou 05-27-2007 05:06 PM

Hello !

Xorg is an X server, it that piece of software that handles all the graphical stuff ... So no GUI without Xorg or XFree ... You can build it in BLFS, after your LFS is perfect ...

help_a_newbie 05-28-2007 08:41 AM

hey, biniou

Thanx for explainin me what xorg is. I'll find it difficult to make my LFS perfect (I don't know even if I'll ever finish it). I finished chapter 5. I changed the ownership of the $LFS/tools folder and now how can I shut down my computer? What do I need to type next time I start the live cd? Thanx!

P.S. Ignore the next text, it's a stupid program, that got stuck in my computer (windows safety system sucks)

[Posted by 8

[Posted by 85.74.70.220 via http://algart.net/ww This is added while posting a message to avoid misuse.
Try: http://webwarper.net/webwarper.exe Exa

Cluracan 05-28-2007 04:28 PM

I don't think shutting down in the middle of the build is recommended; however, I also know that building one of these systems can take days, and you can't always leave the computer running for that whole time. :-P

The command to shutdown should be "shutdown -h now" (shutdown = command to shut down, -h = halt, now = do it now instead of later).

After you start up again (and anyone else feel free to correct me if I'm wrong :-P), I think you'd have to make sure $LFS was set again (export LFS=/mnt/lfs), then redo the commands in 2.4 Mounting the New Partition, then continue on from the beginning of chapter 6.

help_a_newbie 05-29-2007 11:59 AM

thanx, very much


All times are GMT -5. The time now is 05:06 PM.