linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* slim kernel source
@ 2002-03-27 18:30 Dan Bethe
  2002-03-28  7:27 ` Michel Lanners
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Dan Bethe @ 2002-03-27 18:30 UTC (permalink / raw)
  To: linuxppc-dev


Hi all.  Is there a utility or procedure which can remove a bunch of the code
from extraneous architectures from my kernel source tree?  I only want to build
kernels for my beloved Powermac 8500 and so I can do without code specific to
ia32, S390, Alpha, MIPS, and friends.

Even if you just know of a few directories I can remove and save a couple dozen
megs of space, that'd be good.

Thanks!


** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: slim kernel source
  2002-03-27 18:30 slim kernel source Dan Bethe
@ 2002-03-28  7:27 ` Michel Lanners
  2002-03-28  9:16 ` Ethan Benson
  2002-03-28  9:19 ` Geert Uytterhoeven
  2 siblings, 0 replies; 5+ messages in thread
From: Michel Lanners @ 2002-03-28  7:27 UTC (permalink / raw)
  To: dan_bethe; +Cc: linuxppc-dev


On  27 Mar, this message from Dan Bethe echoed through cyberspace:
> Hi all.  Is there a utility or procedure which can remove a bunch of the code
> from extraneous architectures from my kernel source tree?  I only want to build
> kernels for my beloved Powermac 8500 and so I can do without code specific to
> ia32, S390, Alpha, MIPS, and friends.

Hmmm...

> Even if you just know of a few directories I can remove and save a couple dozen
> megs of space, that'd be good.

A random benh 2.4 kernel tree has 127 MB once de-tgz'ed. Of these, 69 MB
are drivers, for which it is difficult to know what you need and what
you don't need. Removing random stuff in there might break the kernel
Makefiles, too.

Which leaves arch/ (22 MB) and include/ (15 MB). In arch, 2.6 MB is ppc/
(not one of the leaner arch'es :-), but there have been cases of one
arch relying on code of some other arch.

In include/, the asm-* part is roughly 10 MB, of which asm-ppc eats
600K. Again, the caveat about dependencies between arch'es apply.

In general, the kernel sources are not meant to be cut in pieces. You
can certainly remove large parts, but you're on your own if anything
breaks.

Cheers

Michel

-------------------------------------------------------------------------
Michel Lanners                 |  " Read Philosophy.  Study Art.
23, Rue Paul Henkes            |    Ask Questions.  Make Mistakes.
L-1710 Luxembourg              |
email   mlan@cpu.lu            |
http://www.cpu.lu/~mlan        |                     Learn Always. "


** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: slim kernel source
  2002-03-27 18:30 slim kernel source Dan Bethe
  2002-03-28  7:27 ` Michel Lanners
@ 2002-03-28  9:16 ` Ethan Benson
  2002-03-28 16:20   ` Hollis Blanchard
  2002-03-28  9:19 ` Geert Uytterhoeven
  2 siblings, 1 reply; 5+ messages in thread
From: Ethan Benson @ 2002-03-28  9:16 UTC (permalink / raw)
  To: linuxppc-dev


On Wed, Mar 27, 2002 at 10:30:28AM -0800, Dan Bethe wrote:
>
> Hi all.  Is there a utility or procedure which can remove a bunch of the code
> from extraneous architectures from my kernel source tree?  I only want to build
> kernels for my beloved Powermac 8500 and so I can do without code specific to
> ia32, S390, Alpha, MIPS, and friends.
>
> Even if you just know of a few directories I can remove and save a couple dozen
> megs of space, that'd be good.

you can probably safly rm -rf everything under arch/* except arch/ppc
and include/asm-* except include/asm-ppc.  i haven't tried this but i
would expect this not to break anything (and if it does thats probably
a bug).

--
Ethan Benson
http://www.alaska.net/~erbenson/

** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: slim kernel source
  2002-03-27 18:30 slim kernel source Dan Bethe
  2002-03-28  7:27 ` Michel Lanners
  2002-03-28  9:16 ` Ethan Benson
@ 2002-03-28  9:19 ` Geert Uytterhoeven
  2 siblings, 0 replies; 5+ messages in thread
From: Geert Uytterhoeven @ 2002-03-28  9:19 UTC (permalink / raw)
  To: Dan Bethe; +Cc: Linux/PPC Development


On Wed, 27 Mar 2002, Dan Bethe wrote:
> Hi all.  Is there a utility or procedure which can remove a bunch of the code
> from extraneous architectures from my kernel source tree?  I only want to build
> kernels for my beloved Powermac 8500 and so I can do without code specific to
> ia32, S390, Alpha, MIPS, and friends.
>
> Even if you just know of a few directories I can remove and save a couple dozen
> megs of space, that'd be good.

You can remove everything under arch/ and include/ you don't need. But you'll
be very disappointed when you notice that you haven't saved a couple dozen megs
of space by doing that. The arch-specific code is _very_ small compared to all
the driver code, which is valid for most architectures.

Gr{oetje,eeting}s,

						Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
							    -- Linus Torvalds


** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: slim kernel source
  2002-03-28  9:16 ` Ethan Benson
@ 2002-03-28 16:20   ` Hollis Blanchard
  0 siblings, 0 replies; 5+ messages in thread
From: Hollis Blanchard @ 2002-03-28 16:20 UTC (permalink / raw)
  To: linuxppc-dev


On Thu, 2002-03-28 at 03:16, Ethan Benson wrote:
>
> On Wed, Mar 27, 2002 at 10:30:28AM -0800, Dan Bethe wrote:
> >
> > Hi all.  Is there a utility or procedure which can remove a bunch of the code
> > from extraneous architectures from my kernel source tree?  I only want to build
> > kernels for my beloved Powermac 8500 and so I can do without code specific to
> > ia32, S390, Alpha, MIPS, and friends.
> >
> > Even if you just know of a few directories I can remove and save a couple dozen
> > megs of space, that'd be good.
>
> you can probably safly rm -rf everything under arch/* except arch/ppc
> and include/asm-* except include/asm-ppc.  i haven't tried this but i
> would expect this not to break anything (and if it does thats probably
> a bug).

As I recall, LinuxPPC 2000 shipped kernel source like this (without
testing ;), and a few PPC headers include m68k headers.

-Hollis


** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2002-03-28 16:20 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-03-27 18:30 slim kernel source Dan Bethe
2002-03-28  7:27 ` Michel Lanners
2002-03-28  9:16 ` Ethan Benson
2002-03-28 16:20   ` Hollis Blanchard
2002-03-28  9:19 ` Geert Uytterhoeven

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).