Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
How to trim fat off a very fat-free distro (GentooLITE?)
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Portage & Programming
View previous topic :: View next topic  
Author Message
hazza
n00b
n00b


Joined: 30 Dec 2002
Posts: 68
Location: Burton on Trent

PostPosted: Mon May 19, 2003 8:24 pm    Post subject: How to trim fat off a very fat-free distro (GentooLITE?) Reply with quote

Hi,

First a little background (I'll try and keep it short!): I've been using Gentoo for about six months now and I'm more than happy with the way it behaves, operates and is generally as robust as any of the more well known Distros. With the exception of using RedmondWare for checking compatibility with web site designs, I use Gentoo as my primary OS.

However, I'm looking at building a (semi-)embedded system to live in my new car. Its all being done for educational purposes (read "a bit of a laugh") and, after having used Gentoo, I'm damned if I'm going to be forced back into using something like RedHat 7.2 simply because I don't have to install all of the developer tools.

So, the problem: I need to be able - once everything has been set up - to strip the machine of its development packages, spurious libraries and >>GASP<< portage / python etc. as once the machine's in place, it won't need any of these toys and, more to the point, it needs to fit on to a compact flash card!

Before I start decimating various installs, I was wondering if anyone else had attempted anything similar and to what degree of success? I'm going to be using VMWare to run the system initially so I can build and install, then copy the virtual disk files and then tear the guts out, hence allowing me to always add bits by using the "master" image.

Once how to unmerge the development / portage subsystems has been defined, it strikes me that you'd have a very configurable, versatile base on which to build semi-embedded systems...

If anyone has their two cents, they'd be great to hear :D

ATB,
Harry
Back to top
View user's profile Send private message
ctford0
l33t
l33t


Joined: 25 Oct 2002
Posts: 774
Location: Lexington, KY,USA

PostPosted: Mon May 19, 2003 10:42 pm    Post subject: Reply with quote

if you dont care about anything but booting the system, just delete the gcc dir... del the portage dir....

with *nix, you dont have to worry about uninstall something, just delete it.

As far as I can see if you leave the basic things that the system needs to run you should be fine.

Chris
Back to top
View user's profile Send private message
El_Presidente_Pufferfish
Veteran
Veteran


Joined: 11 Jul 2002
Posts: 1179
Location: Seattle

PostPosted: Mon May 19, 2003 11:56 pm    Post subject: Reply with quote

go through the base system profile (what you get when you emerge system) and you can trim programs
i think its in /etc/profile/packages

you can also delete the /usr/src/linux/ directory if you dont plan on compiling anything against the kernel headers
Back to top
View user's profile Send private message
krinkle
Guru
Guru


Joined: 04 Feb 2003
Posts: 338
Location: Garden Grove, CA

PostPosted: Tue May 20, 2003 12:40 am    Post subject: Reply with quote

could just be talking out my ass, but maybe could you use distcc or something similar and do all the compiling on a seperate computer with all the developer libraries installed and then just copy the binaries on the small machine? that way you would optimize for the computers architecture, get faster compile times, and not waste space. I've been thinking of making a carputer myself (based on a via c3 most likely), and that was the route i was looking at... let me know how it turns out
Back to top
View user's profile Send private message
id10t
Tux's lil' helper
Tux's lil' helper


Joined: 18 May 2002
Posts: 100

PostPosted: Tue May 20, 2003 2:52 am    Post subject: Reply with quote

Right tool for the job - and as much as i hate to say it, in this case Gentoo is not quite the right tool. For the minimal systems I've done, I just use whatver version of Slack I can lay my hands on (I have all of them from 7.0 up laying around in stratiegic locations) and install all of the A, AP, and N disk sets. When I did my dumb X terminal project a few months ago, I added the X (but not XAP) directory.
_________________
---
this space for rent
Back to top
View user's profile Send private message
mlynx
n00b
n00b


Joined: 07 Feb 2003
Posts: 27

PostPosted: Tue May 20, 2003 4:31 am    Post subject: Reply with quote

Another thing to consider would be the flags you choose when installing the system. Make sure that USE flags are in order and remember that while a -O3 can really increase performance, -Os produces much smaller binaries.

I would also look at some of the smaller disk based distros for ideas on what to include, the bootable business card distros come to mind with (IIRC) about 50M in size.
_________________
mlynx
-------------------------
Did your mom -Os your brain when you were a baby?
Back to top
View user's profile Send private message
rac
Bodhisattva
Bodhisattva


Joined: 30 May 2002
Posts: 6553
Location: Japanifornia

PostPosted: Tue May 20, 2003 4:33 am    Post subject: Reply with quote

krinkle wrote:
maybe could you use distcc or something similar and do all the compiling on a seperate computer with all the developer libraries installed and then just copy the binaries on the small machine?
Would that it were so. Unfortunately, the current incarnation of distcc does the preprocessing and liking on the target, so you still need a fully functional toolchain on the target.
_________________
For every higher wall, there is a taller ladder
Back to top
View user's profile Send private message
krinkle
Guru
Guru


Joined: 04 Feb 2003
Posts: 338
Location: Garden Grove, CA

PostPosted: Tue May 20, 2003 7:42 am    Post subject: Reply with quote

Quote:
krinkle wrote:
Quote:
maybe could you use distcc or something similar and do all the compiling on a seperate computer with all the developer libraries installed and then just copy the binaries on the small machine?

Would that it were so. Unfortunately, the current incarnation of distcc does the preprocessing and liking on the target, so you still need a fully functional toolchain on the target.


heh, talking out my ass... my bad =)
Back to top
View user's profile Send private message
hazza
n00b
n00b


Joined: 30 Dec 2002
Posts: 68
Location: Burton on Trent

PostPosted: Tue May 20, 2003 8:28 pm    Post subject: Reply with quote

Quote:
Right tool for the job - and as much as i hate to say it, in this case Gentoo is not quite the right tool.
I know what you're saying mate, and I do tend to agree, but I just like the gentoo setups too much! The way init is handled, the way portage is tweakable to your heart's content... Don't want to loose that during the setup / development stage of this project...

Quote:
if you dont care about anything but booting the system, just delete the gcc dir... del the portage dir....
Quote:
go through the base system profile (what you get when you emerge system) and you can trim programs
i think its in /etc/profile/packages
This looks like a better plan: once I've done it a couple of times hopefully I'll be able to automate it :D
Thanks for your help guys,
--Harry
Back to top
View user's profile Send private message
fidzysss
Tux's lil' helper
Tux's lil' helper


Joined: 16 Feb 2003
Posts: 109
Location: Paris (France)

PostPosted: Tue May 20, 2003 9:52 pm    Post subject: Reply with quote

You could also take a look at
Code:
ebuild foo.ebuild package

or
Code:
ebuild foo.ebuild rpm

and also
Code:
emerge --buildpkg foo

since these instructions tell portage to compile the source and then build a binary package ready to be installed (tbz2 or rpm). So by tweaking the use flags and gcc options you should be able to create your own distrib. In fact I think gentoo could be the perfect tool to create customized distribution :P , even if I didn't personnally try those feature.

fid
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Portage & Programming All times are GMT
Page 1 of 1

 
Jump to:  
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 vote in polls in this forum