Trimming uclibc in l4

Masti Ramya Jayaram rmasti at inf.ethz.ch
Thu Sep 18 10:31:26 CEST 2014


Hi,

I completely understand that I should update but given time constraints, I am using an older version on a board that it works. I will update it eventually.

I managed to backport the library which was 2 revisions ahead. In this version only the bootstrap module uses the minimal lib. I removed some more files from the minimal library (which my modified version does not need) and inspected the build folder.

The actual library reduces in size expected. However, I see that the bootstrap.elf executable increases in size. Furthermore, when I use the make elfimage command (e.g., make elfimage E=l4linux), changing the list of files in the uclibc library does not seem to have any effect on the final executable's size (i.e., bootstrap_l4linux.elf).

I can confirm that bootstrap builds against the minimal library because not having it there simply cause the build to fail. However, I do not understand why modifying the list of files in the library does not change anything.

Thanks in advance,
ramya
________________________________________
From: l4-hackers [l4-hackers-bounces at os.inf.tu-dresden.de] on behalf of Björn Döbel [doebel at os.inf.tu-dresden.de]
Sent: 16 September 2014 19:15
To: l4-hackers at os.inf.tu-dresden.de
Subject: Re: Trimming uclibc  in l4

Hi,

as Marcus already pointed out, newer versions of L4Re actually contain a
package called uclibc_minimal that serves exactly this purpose. Even if
you are using an older snapshot, chances are that backporting this
package (and adapting l4/mk) might be easier than stripping things down
yourself.

Bjoern

Am 16.09.2014 um 19:02 schrieb Masti Ramya Jayaram:
> Update: turns out it is not very simple to compile just bootstrap against a smaller library because the l4/mk/modes.inc file defaults to the uclibc library for compiling the files which is used for all packages. Any ideas how I can change this only for some packages?
>
> Thanks.
> Ramya
> ________________________________________
> From: l4-hackers [l4-hackers-bounces at os.inf.tu-dresden.de] on behalf of Masti  Ramya Jayaram [rmasti at inf.ethz.ch]
> Sent: 16 September 2014 17:53
> To: l4-hackers at os.inf.tu-dresden.de
> Subject: Trimming uclibc  in l4
>
> Dear all,
>
> I would like to extract the minimal subset of uclibc required by bootstrap, sigma and their dependencies only. My idea is to have these modules use the smaller libc while retain the usual uclibc build for the other packages.
>
> I intend to go about this by copying uclibc (say into uclibc_min) and then modifying the contrib_files_all.lst and contrib_files_x86.lst. Is this the correct way to do this?
>
> Also, I extracted all the package dependencies of bootstrap and sigma from the control files (below)
>
> bootstrap: drivers_uart drivers_of libc l4util cxx_io
> drivers-frst:libc
> l4util: crtn libc
> crtn: l4sys
> l4sys: ldscripts
> l4util: crtn libc
> cxx: l4sys l4util
> ulibc: l4sys
> sigma0: crtn l4sys l4util libsigma0 cxx_io
> libsigma0:  l4sys
>
>
> Is this the correct way to do this as well?
>
> Thanks,
> Ramya
>
>
>
> _______________________________________________
> l4-hackers mailing list
> l4-hackers at os.inf.tu-dresden.de
> http://os.inf.tu-dresden.de/mailman/listinfo/l4-hackers
>
> _______________________________________________
> l4-hackers mailing list
> l4-hackers at os.inf.tu-dresden.de
> http://os.inf.tu-dresden.de/mailman/listinfo/l4-hackers
>

_______________________________________________
l4-hackers mailing list
l4-hackers at os.inf.tu-dresden.de
http://os.inf.tu-dresden.de/mailman/listinfo/l4-hackers




More information about the l4-hackers mailing list