View previous topic :: View next topic |
Author |
Message |
sledge n00b
Joined: 04 Aug 2003 Posts: 6
|
Posted: Mon Aug 04, 2003 8:39 am Post subject: A slimmer Gentoo ;) |
|
|
Size matters. Everbody knows that.
How to install gentoo (stage3) with dietlibc
The easy (time-consuming ) way:
After you have untared your stage3-tarball you have to emerge dietlibc
After that, edit your make.conf and add the following lines anywhere in your make.conf (preferably after the host-settings section):
Code: | # Compiler Setting
# ================
#
# If you want to use a different libc (i.e. fefe`s dietlibc) and
# you are provided with a wrapper script for gcc you want to
# change this line.
#COMPILER="gcc3"
COMPILER="diet" |
and change your CFLAGS:
Code: | # I usually compile with -pipe and -fomit-frame-pointer ,too
CFLAGS="-march=your_arch_here -Os" |
Now you have to rebuild all you packages (that`s why it`s the time-consuming way ):
Code: | # export CONFIG_PROTECT="-* /etc/make.conf"
# emerge -uUDep system
( prints packages )
# emerge -uUDe system
( recompiles all (new) packages using dietlibc )
# unset CONFIG_PROTECT
|
... and continue with step 14 of the Installation Guide.
Don`t forget to backup your make.conf before every portage update. Portage will replace your make.conf with a default one.
Hope that helped |
|
Back to top |
|
|
sledge n00b
Joined: 04 Aug 2003 Posts: 6
|
Posted: Mon Aug 04, 2003 8:46 am Post subject: |
|
|
I just noticed that this should have gone into "Installing Gentoo".
Doh! |
|
Back to top |
|
|
nikai Apprentice
Joined: 02 Oct 2002 Posts: 270 Location: Kitzbühel, Austria
|
Posted: Mon Aug 04, 2003 9:31 am Post subject: |
|
|
In theory, this is a very nice idea.
But I guess it takes to hack ebuilds to actually use that wrapping.
I see other distros (like ROCK) put a lot of work in getting stuff to compile against dietlibc (like gawk, for example). |
|
Back to top |
|
|
puggy Bodhisattva
Joined: 28 Feb 2003 Posts: 1992 Location: Oxford, UK
|
Posted: Mon Aug 04, 2003 9:51 am Post subject: Re: A slimmer Gentoo ;) |
|
|
sledge wrote: | ... and continue with step 14 of the Installation Guide.
Don`t forget to backup your make.conf before every portage update. Portage will replace your make.conf with a default one. |
No it won't. etc-update might but only if you let it or are careless enough to just let etc-update auto-update all files.
Puggy _________________ Where there's open source , there's a way. |
|
Back to top |
|
|
pilla Bodhisattva
Joined: 07 Aug 2002 Posts: 7729 Location: Underworld
|
Posted: Mon Aug 04, 2003 2:06 pm Post subject: |
|
|
Moving to Docs, Tips & Tricks. _________________ "I'm just very selective about the reality I choose to accept." -- Calvin |
|
Back to top |
|
|
DefconAlpha Apprentice
Joined: 25 Feb 2003 Posts: 151 Location: Alabama
|
Posted: Mon Aug 04, 2003 2:23 pm Post subject: Ok |
|
|
So slimmer you say? How big is your install of Dietlibc Gentoo? Do you also have at least an approximation of the size after finishing the stage3 install? With glibc it is almost 1gb, just curious really. _________________ In the end, the love you get is equal to the love you make
--John Lennon & Paul McCartney (The End - Abbey Road, |
|
Back to top |
|
|
Chickpea l33t
Joined: 03 Jun 2002 Posts: 846 Location: Vancouver WA
|
Posted: Mon Aug 04, 2003 2:47 pm Post subject: |
|
|
DefconAlpha wrote
Quote: | So slimmer you say? How big is your install of Dietlibc Gentoo? Do you also have at least an approximation of the size after finishing the stage3 install? With glibc it is almost 1gb, just curious really |
yours is really that high with only a base system...Stage 3? my system currently is at 1.1 gb and that is with X, evolution, a couple of window managers gedit, and Mozillafirebird and some other fun things. |
|
Back to top |
|
|
DefconAlpha Apprentice
Joined: 25 Feb 2003 Posts: 151 Location: Alabama
|
Posted: Mon Aug 04, 2003 5:48 pm Post subject: |
|
|
Chickpea wrote: |
yours is really that high with only a base system...Stage 3? my system currently is at 1.1 gb and that is with X, evolution, a couple of window managers gedit, and Mozillafirebird and some other fun things. |
Umm, i think so, perhaps it was more in the 600 - 700 MB range. But i have slept since then. Like several months worth of sleeping. (Not to mention several other memory-degrading activities)...
Now to get linux on two floppies with dietlibc. Then we can install gentoo on non-cdrom booting computers :) _________________ In the end, the love you get is equal to the love you make
--John Lennon & Paul McCartney (The End - Abbey Road, |
|
Back to top |
|
|
Chickpea l33t
Joined: 03 Jun 2002 Posts: 846 Location: Vancouver WA
|
Posted: Mon Aug 04, 2003 6:14 pm Post subject: |
|
|
Quote: | Now to get linux on two floppies with dietlibc. Then we can install gentoo on non-cdrom booting computers |
can't you just create a grub boot disk and install from a network or hard drive. I installed a couple of times from a spare hard drive...but it has been so long. |
|
Back to top |
|
|
Gibberx Apprentice
Joined: 20 Oct 2002 Posts: 217 Location: UMBC
|
Posted: Tue Aug 05, 2003 12:48 am Post subject: |
|
|
..what is dietlibc? sounds like a replacement of glibc, of course...
does it make your binaries smaller, or what? |
|
Back to top |
|
|
imp n00b
Joined: 03 Dec 2002 Posts: 45 Location: Belgrade, SCG
|
Posted: Thu Aug 07, 2003 3:13 pm Post subject: |
|
|
From diet libc homepage:
Quote: | The diet libc is a libc that is optimized for small size. It can be used to create small statically linked binaries for Linux on alpha, arm, hppa, ia64, i386, mips, s390, sparc, sparc64, ppc and x86_64. |
_________________ blog :: bookmarks |
|
Back to top |
|
|
DefconAlpha Apprentice
Joined: 25 Feb 2003 Posts: 151 Location: Alabama
|
Posted: Fri Aug 08, 2003 7:17 pm Post subject: |
|
|
Chickpea wrote: | can't you just create a grub boot disk and install from a network or hard drive. I installed a couple of times from a spare hard drive...but it has been so long. |
Yes, but it would be really nice to have the two floppies that did all of the above... Boot from the floppies and install from cdrom, network, spare hard drive, etc. Anything really... Perhaps even modify the second floppy for clustering utilities or small servers (dhcp, iptables, ftp, mail, etc)
Just a nifty thing to have lying around for "one of those days" _________________ In the end, the love you get is equal to the love you make
--John Lennon & Paul McCartney (The End - Abbey Road, |
|
Back to top |
|
|
simcop2387 Apprentice
Joined: 14 Aug 2002 Posts: 200 Location: Galactic Sector ZZ9 Plural Z Alpha
|
Posted: Sat Aug 09, 2003 8:56 pm Post subject: |
|
|
seldge i got to hand it to you so far my laptop has been recompiling system and its not even near done and i've got 40+ meg more of free space, everything appears to be working right now, when i'm done i'm doing an emerge world to get X and everything compiled with dietlibc, i was running near 25meg free before this |
|
Back to top |
|
|
someguy Guru
Joined: 10 Jul 2003 Posts: 433 Location: (-_-) .::OH_WELL::. (-_-)
|
Posted: Tue Sep 16, 2003 8:25 am Post subject: |
|
|
wow good howto saving me space on my router _________________ print pack"C*",split/\D+/,`echo "16iII*o\U@{$/=$z;[(pop,pop,unpack"H*",<>
)]}\EsMsKsN0[lN*1lK[d2%Sa2/d0<X+d*lMLa^*lN%0]dsXx++lMlN/dsM0<J]dsJxp"|dc`
while [ 1 ] ; do echo "*" | telnet ip.of.print.er 9100 ; done |
|
Back to top |
|
|
ghardey n00b
Joined: 11 Jun 2003 Posts: 15
|
Posted: Thu Dec 18, 2003 3:08 am Post subject: fomit-frame-pointer caused compiler cannot create executable |
|
|
Quote: | and change your CFLAGS:
Code: | Code:
# I usually compile with -pipe and -fomit-frame-pointer ,too
CFLAGS="-march=your_arch_here -Os" |
|
When I tried using the -fomit-frame-pointer flag I got an error "C compiler cannot create executable" when emerging gnet. config.log showed that it didn't like -fomit-frame-pointer. After I removed that flag emerged without error using dietlibc 0.23. |
|
Back to top |
|
|
dub.wav Tux's lil' helper
Joined: 09 Apr 2003 Posts: 149 Location: Norway
|
Posted: Fri Dec 19, 2003 8:21 am Post subject: Re: A slimmer Gentoo ;) |
|
|
sledge wrote: | Now you have to rebuild all you packages (that`s why it`s the time-consuming way ):
Code: | # export CONFIG_PROTECT="-* /etc/make.conf"
# emerge -uUDep system
( prints packages )
# emerge -uUDe system
( recompiles all (new) packages using dietlibc )
# unset CONFIG_PROTECT
|
|
If you have to rebuild the whole system, why not just start from stage1? |
|
Back to top |
|
|
Aaron_Brown n00b
Joined: 29 Mar 2003 Posts: 14
|
Posted: Sat Dec 20, 2003 10:34 am Post subject: |
|
|
After I have compiled everything with dietlibc can I remove glibc?
Aaron |
|
Back to top |
|
|
_hesoez_ Tux's lil' helper
Joined: 09 Jun 2003 Posts: 103 Location: Belgium-Duffel/Leuven
|
Posted: Thu Dec 25, 2003 3:21 pm Post subject: |
|
|
is it normal that i still see 'gcc ... -Os -... blabla.c'
as an output on the screen when compiling something?
can i let another box that doesn't have dietlibc compile for my box with dietlibc when using distcc?
grtz |
|
Back to top |
|
|
airflow Apprentice
Joined: 14 Dec 2003 Posts: 173 Location: Vienna, Austria
|
Posted: Fri Dec 26, 2003 8:19 pm Post subject: Re: A slimmer Gentoo ;) |
|
|
dub.wav wrote: | sledge wrote: | Now you have to rebuild all you packages (that`s why it`s the time-consuming way :wink: ):
Code: | # export CONFIG_PROTECT="-* /etc/make.conf"
# emerge -uUDep system
( prints packages )
# emerge -uUDe system
( recompiles all (new) packages using dietlibc )
# unset CONFIG_PROTECT
|
|
If you have to rebuild the whole system, why not just start from stage1? :? |
Because as far as I know you wouldn't have the possibility to emerge dietlibc before bootstrapping. So you would have to bootstrap twice... Better to start with a Stage-3 Installation in this case, I think.
regards,
airflow |
|
Back to top |
|
|
airflow Apprentice
Joined: 14 Dec 2003 Posts: 173 Location: Vienna, Austria
|
Posted: Sun Dec 28, 2003 2:51 pm Post subject: Re: A slimmer Gentoo ;) |
|
|
sledge wrote: | After that, edit your make.conf and add the following lines anywhere in your make.conf (preferably after the host-settings section):
Code: | # Compiler Setting
# ================
#
# If you want to use a different libc (i.e. fefe`s dietlibc) and
# you are provided with a wrapper script for gcc you want to
# change this line.
#COMPILER="gcc3"
COMPILER="diet" |
|
Are you sure this works? I had a look into the manpage of make.conf, and this (rather important) variable is not mentioned anywhere... I would like to try it, but it will take a week or so to recompile my system with my laptop, so I would like to be sure.
regards,
airflow |
|
Back to top |
|
|
Serj n00b
Joined: 04 Aug 2003 Posts: 46 Location: Ukraine
|
Posted: Mon Jul 12, 2004 12:13 pm Post subject: |
|
|
Anyway, did anybody try dietlibc?
Does it work now with 2004.1?
Does all packages compile well with dietlibc?
P.S. Sorry for my English! |
|
Back to top |
|
|
kamagurka Veteran
Joined: 25 Jan 2004 Posts: 1026 Location: /germany/munich
|
Posted: Tue Jul 13, 2004 1:24 am Post subject: Re: A slimmer Gentoo ;) |
|
|
sledge wrote: | Don`t forget to backup your make.conf before every portage update. Portage will replace your make.conf with a default one. |
what horrible nonsense. i'm not taking any advice from someone who doesn't even know about etc-update/dispatch-conf _________________ If you loved me, you'd all kill yourselves today.
--Spider Jerusalem, the Word |
|
Back to top |
|
|
Serj n00b
Joined: 04 Aug 2003 Posts: 46 Location: Ukraine
|
Posted: Tue Jul 13, 2004 6:24 am Post subject: |
|
|
Yestarday, I'v try to use diet to reemerge some packages as writing above but nothing happend - the size of binaries have stay the same.
Does anybody now how to use diet in Gentoo 2004.1? |
|
Back to top |
|
|
SDraconis n00b
Joined: 20 Apr 2005 Posts: 53
|
Posted: Wed Jun 08, 2005 8:08 am Post subject: |
|
|
It looks like this thread it pretty old. I was wondering if anybody has had any luck with this in more recent versions of Gentoo. Does setting COMPILER in make.conf work to have things compile with dietlibc still? |
|
Back to top |
|
|
Jeffrey0 n00b
Joined: 31 Dec 2004 Posts: 68
|
Posted: Sat Jun 11, 2005 5:01 am Post subject: Re: A slimmer Gentoo ;) |
|
|
Quote: | It looks like this thread it pretty old. I was wondering if anybody has had any luck with this in more recent versions of Gentoo. Does setting COMPILER in make.conf work to have things compile with dietlibc still? |
I can't find any matches for COMPILER in all of portage... don't think it does anything. Looks like the new way is using profiles. There's one for uclibc.
kamagurka wrote: | what horrible nonsense. i'm not taking any advice from someone who doesn't even know about etc-update/dispatch-conf |
Look at the date. Portage updates *did* overwrite make.conf back then IIRC (used Gentoo for a little while back in 2003). |
|
Back to top |
|
|
|