RE: Reducing glibc with mklibs.sh

2 messages, 2 authors, 2001-10-30 · open the first message on its own page

RE: Reducing glibc with mklibs.sh

From: Jean-Denis Boyer <hidden>
Date: 2001-10-29 22:36:30

It looks like mklibs.sh does not find the map file for libm.

In your script:
cp *.map ../lib/
might be bad, because the makefile of glibc produces libm.map,
while mklibs.sh looks for libm_pic.map (the name differs).

Either you rename the file when copying it, or you modify mklibs.sh.

--------------------------------------------
 Jean-Denis Boyer, B.Eng., Technical Leader
 Mediatrix Telecom Inc.
 4229 Garlock Street
 Sherbrooke (Québec)
 J1L 2C8  CANADA
 (819)829-8749 x241
--------------------------------------------

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

RE: Reducing glibc with mklibs.sh

From: Michael Habermann <hidden>
Date: 2001-10-30 02:00:44

At 05:36 PM 10/29/2001 -0500, Jean-Denis Boyer wrote:
In your script:
quoted
cp *.map ../lib/
might be bad, because the makefile of glibc produces libm.map,
while mklibs.sh looks for libm_pic.map (the name differs).
Sorry for having posted this buggy script. Here's the correct one:
---
CC=powerpc-linux-gcc \
AR=powerpc-linux-ar \
RANLIB=powerpc-linux-ranlib \
CFLAGS="-Os -DNDEBUG" \
./configure \
--enable-kernel=2.4.4 \
--disable-profile \
--host=powerpc-linux \
--enable-add-ons=linuxthreads \
--with-headers=/usr/local/powerpc-linux/include \
--prefix=

make
make install_root=/usr/local/powerpc-linux install

#Prepare the lib directory for reducing the standard library size with
#mklibs.shcp
#copy pic files to ../lib/
cp `find -name "*_pic.a"` ../lib/

#rename *.map file to ../lib/*_pic.map
for i  in *.map; do
     cp $i ../lib/${i%%.map}_pic.map
done

#libc requires special handling
mkdir ../lib/libc_pic
cp elf/interp.os ../lib/libc_pic/interp.o
cp elf/soinit.os ../lib/libc_pic/soinit.o
cp elf/sofini.os ../lib/libc_pic/sofini.o

#libm doesn't work
rm -f ../lib/libc.map
rm -f ../lib/libc_pic.a
---


** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help