LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
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-24-2015, 06:06 PM   #1
HashNoob
Member
 
Registered: Jun 2015
Posts: 37

Rep: Reputation: Disabled
Can you safely remove GCC, binutils after LFS installation


I already have LFS working and stable.

I just tested the LFS after removing the usr folder and it was still working. Never mind this, ignore it.

Because gcc(includes/is just a compiler) and binutils a (linker).
I'm just curios can i remove gcc and binutils from LFS. Is it safe to remove it, after removal can i still install upgrade packages without gcc or binutils, on the working and stable LFS that I'm in.

And why do i need gcc, or binutils after LFS installation.
Is it just for development and compiling ,writing programs etc.

Can someone explain it shortly.

Last edited by HashNoob; 07-24-2015 at 06:09 PM.
 
Old 07-24-2015, 06:18 PM   #2
Keith Hedger
Senior Member
 
Registered: Jun 2010
Location: Wiltshire, UK
Distribution: Linux From Scratch, Slackware64, Partedmagic
Posts: 3,137

Rep: Reputation: 855Reputation: 855Reputation: 855Reputation: 855Reputation: 855Reputation: 855Reputation: 855
If you mean the tools you built in chapter 5 yes you can remove them, but I would tar them up for future use.
If on the other hand you mean the gcc/binutils you built in chapter 6 then no you cant remove them because then you cant build any more software.
I you have removed /usr and your system is still working, its NOT, most software is in /usr if you remove it and your system still works you are not using the /usr you think you are..
 
Old 07-24-2015, 06:32 PM   #3
HashNoob
Member
 
Registered: Jun 2015
Posts: 37

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by Keith Hedger View Post
If you mean the tools you built in chapter 5 yes you can remove them, but I would tar them up for future use.
If on the other hand you mean the gcc/binutils you built in chapter 6 then no you cant remove them because then you cant build any more software.
I you have removed /usr and your system is still working, its NOT, most software is in /usr if you remove it and your system still works you are not using the /usr you think you are..
Forget the chapters - I already have LFS installed and working.
My questions is - What happens if you remove gcc and binutils. Will the LFS still work, and can i install other favorite packages after this.( I mean directly installing form LFS via - sudo apt-get install something)

Last edited by HashNoob; 07-24-2015 at 06:38 PM.
 
Old 07-24-2015, 06:40 PM   #4
Keith Hedger
Senior Member
 
Registered: Jun 2010
Location: Wiltshire, UK
Distribution: Linux From Scratch, Slackware64, Partedmagic
Posts: 3,137

Rep: Reputation: 855Reputation: 855Reputation: 855Reputation: 855Reputation: 855Reputation: 855Reputation: 855
please read the answers you have been given.

I will repeat for the hard of thinking.
WITHOUT GCC/BINUTILS ET AL YOU CAN NOT COMPILE AKA BUILD AND INSTALL SOFTWARE.

If you want to install pre-built software from debian repos with apt-get for example whats the point of using LFS in the first place?
 
Old 07-24-2015, 06:49 PM   #5
HashNoob
Member
 
Registered: Jun 2015
Posts: 37

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by Keith Hedger View Post
please read the answers you have been given.

I will repeat for the hard of thinking.
WITHOUT GCC/BINUTILS ET AL YOU CAN NOT COMPILE AKA BUILD AND INSTALL SOFTWARE.

If you want to install pre-built software from debian repos with apt-get for example whats the point of using LFS in the first place?
So basically what ur saying is that any Linux Distro example debian - must have gcc/binutils installed in order to get packages installed. So every program that u want to download it requires gcc/binutils, in order to install it.

But the program that I'm downloading for example is already compiled and build, so i only need to install it. Who makes my program installed.
 
Old 07-24-2015, 06:56 PM   #6
Keith Hedger
Senior Member
 
Registered: Jun 2010
Location: Wiltshire, UK
Distribution: Linux From Scratch, Slackware64, Partedmagic
Posts: 3,137

Rep: Reputation: 855Reputation: 855Reputation: 855Reputation: 855Reputation: 855Reputation: 855Reputation: 855
wow you really dont listen do you.
last tine

GCC/BINUTILZ IS FOR BUILDING SOFTWARE NOT FOR INSTALLING PREBUILT SOFTWARE

if you are installing pre built software read the above again.
 
Old 07-24-2015, 07:05 PM   #7
HashNoob
Member
 
Registered: Jun 2015
Posts: 37

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by Keith Hedger View Post
wow you really dont listen do you.
last tine

GCC/BINUTILZ IS FOR BUILDING SOFTWARE NOT FOR INSTALLING PREBUILT SOFTWARE

if you are installing pre built software read the above again.
Lol - that's what i said in the first post
- Quote -
"And why do i need gcc, or binutils after LFS installation.
Is it just for development and compiling ,writing programs etc."
- End Quote -

So GCC/BINUTILZ can be removed from LFS( it's objective is to compile, link and via make - build software) and not install per-build software. Is that correct?

Last edited by HashNoob; 07-24-2015 at 07:25 PM.
 
Old 07-25-2015, 10:35 AM   #8
ReaperX7
LQ Guru
 
Registered: Jul 2011
Location: California
Distribution: Slackware64-15.0 Multilib
Posts: 6,554
Blog Entries: 15

Rep: Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097
LFS is not a prepackaged distribution. You build it from source and because the compilers are tightly knit into the system, you can not remove them or else you will break not only the toolchain, but the underlying libraries that support the core of the system, rendering the system useless.

It is also extremely unwise to import ANY prepackaged software sets into LFS because many of the libraries used are linked against different versions.

All packages built and installed to LFS are all-or-nothing packages very similar to Slackware. There are no broken down -dev, -bin, -lib, -src, -doc, -meta, etc. packages like Debian.

Even if you have completed the entire LFS, BLFS, and even adventured into CBLFS or on your own, you can not remove compilers like GCC and LLVM later on due to the fact many libraries used with each set of compilers would be removed also. Because LFS uses dynamic linking of shared libraries, rather than static, to save tons of space and memory overhead, it's impossible to do so.
 
Old 07-25-2015, 02:32 PM   #9
HashNoob
Member
 
Registered: Jun 2015
Posts: 37

Original Poster
Rep: Reputation: Disabled
Thnx ReaperX7, that makes sense.
Sorry about the confusion, just wanted to be sure a bit about it.

Last edited by HashNoob; 07-25-2015 at 02:33 PM.
 
Old 07-30-2015, 12:05 PM   #10
hendrickxm
Member
 
Registered: Feb 2014
Posts: 344

Rep: Reputation: Disabled
It is possible to build a custom LFS, add a package manager and use binaries from an existing (and maintained) distro. But I would not recommend it.
There are a few methods to add a package manager from another distro and/or use binaries from other distros. Makes it easier and faster to upgrade certain software.
 
Old 08-03-2015, 04:08 AM   #11
ReaperX7
LQ Guru
 
Registered: Jul 2011
Location: California
Distribution: Slackware64-15.0 Multilib
Posts: 6,554
Blog Entries: 15

Rep: Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097
Whenever you use a package manager for LFS, just build everything in-house and create your own repository of packages and link the configuration to your repository. Be aware there is ONE royal pain of a package that will require a series of patches to make to portable into a package.

Glibc

There are several patches used by various distributions just to make glibc portable. By nature glibc, when built, hard locks to your system path. If you build it and install it to the DEST= path, the system cache file created by glibc during make install, will hard lock the path to say for example: /tmp/package-glibc rather than /. The same patches are used by roughly every distribution, but are not used by LFS due to the fact its directly built into the main system.

My suggestion, study how glibc is built by distributions like CRUX, Arch, and Slackware, and reincorporate it.
 
1 members found this post helpful.
  


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
[SOLVED] LFS 7.2, chapter 5., section 5.4.1 Installation of Cross Binutils Lakhan Kumar Linux From Scratch 7 11-12-2012 04:22 PM
LFS-5.0 GCC problem with binutils-2.14 pass 1 NCappaZoo Linux From Scratch 6 06-14-2009 03:47 AM
LFS 6.3 - binutils 2.17 installation seb_01630 Linux From Scratch 5 07-31-2008 06:52 AM
GCC doesn't work Binutils configuration or installation error fadelhomsi Linux From Scratch 2 09-20-2007 08:00 AM
gcc binutils installation for programming m68k ratnakarreddy Linux - Newbie 3 05-20-2006 07:23 AM

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

All times are GMT -5. The time now is 03:38 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