Saturday, December 04, 2004

mkjail.sh

mkjail.sh. now i know why mkjail is included with crosstool.
to test the newly built libs. duh. i wonder how i could test
everything inside of vmware or xen?
i want to change mkjail to include builds of bash, ls and env.
here is my listing of what i want.

/bin
bash
cat
chmod
echo
df
kill
ls
mount
ping
ps
rm
sh

/sbin
ifconfig
init
route

/usr/bin
gdbserver
telnet

/lib
ld.so.1
ld-2.*.so
libc.so.6
libc-2*.so
libdl.so.2
libm.so.6
libm-2*.so
libncurses.so.5.*
libnss_dns.so.*
libnss_files*
libproc.so.2*
libpthread.so.*
libpthread-0.0.so
libresolve-2.2.3.so
librt.so.1
librt-2.2.3.s0
libstdc++-3-libc6.1*so
libutil.so.*
libutil.2*.

basically this what the embedded linux book said i should have.
maybe its less than that maybe more. and definitly different
versions of the what i have show above.

here is what header to mkjail.sh says:

# Create a tarball containing the shared libraries and executables from gcc/glibc

# (but not any shared libraries or executables that are otherwise crucial for a chroot jail).
# After this finishes, transfer jail.tar.gz and initjail.sh to the target, then
# run initjail.sh and tell it where you'd like the jail; it will unpack this tarball
# and complete the jail.
so transfer the tarball to the target. the original purpose of crosstool
was to create a cross compiler but im building on i386 for i386.
i will need to make a new script.

this still presupposes a couple of questions how do i take the new libraries
just build in mkjail and build bash, ls and so forth?

theory 1)
when ./demo-i686.sh finishes
the following is in /opt:
/opt/crosstool/i686-unknown-linux-gnu/gcc-3.3.2-glibc-2.3.2/i686-unknown-linux-gnu/bin

unpack bash and run the configure process to say gcc in this directory tree
and that libc is there as well would this work?

ok skip that ptxdist does that already skip doing mkjail.sh on crosstools
build and look what ptx builds. yes im lazy.

No comments: