Code: Select all
[ ! -e /pup_new/etc/DISTRO_SPECS ] && \
cp /DISTRO_SPECS /pup_new/etc/DISTRO_SPECS
After fixing this I got to errors about not being able to open the following shared libraries:
Code: Select all
libpcre.so.3 #A dependency of grep
libsystemd.so.0 #A dependency of free
There are a few ways, that one could fix this which include:
1. symlink these two libs into the default search path
2. move these two files into the default search path
3. move the entire folders where these libs are included into the default search path and replace the orginal folder with a symlink to the new location.
4. call the busybox version of these functions instead in rc.systinit.
5. call ldconfig so that the location of these libs gets put into cash. Requires configuring ld.
Dpup stretch uses approach #3, I chose approach #5. Here is my ld.so.conf
Code: Select all
/usr/local/lib
/lib
/usr/lib
/root/my-applications/lib
/usr/local/lib
/lib/i386-linux-gnu
/usr/lib/i386-linux-gnu
/usr/lib/i386-gnu
Anyway, assuming one installs this into their root fs, then at the end of the basesfs config file (prior to trimming the packages), we can do the following:
Code: Select all
%reinstall libc-bin #contians ldconfig
%chroot ldconfig
Some other random notes. I added some debugging and lagacy code back into initrd to support the case that the kernal does not have devtmps. Wdlkmpx, says that this is need only for kernals woof-CE compiled kernals prior to 3.2 (i.e. warry/racy and earlier).
Here is the lagacy and debugging code that I added:
in build-iso.sh->install_initrd()
Code: Select all
tar -xzf "$WOOFCE/woof-arch/woof-code_boot_initrd-tree0_DEVDIR.tar.gz" \
-C "$initrdtmp"
mv "$initrdtmp"/dev "$initrdtmp"/dev2
mkdir "$initrdtmp"/dev
#cp "$WOOFCE/woof-arch/woof-code_rootfs-skeleton_DEVDIR.tar.gz" "$initrdtmp/dev1.tar.gz"
cp "$WOOFCE/woof-arch/woof-code_rootfs-skeleton_DEVDIR.tar.gz" "$initrdtmp/dev2.tar.gz"
Code: Select all
exec 1>/dev2/console 2>&1 #s243a
**We use /dev2 because if we are dumping startup debugging info to /dev/console then we can't move or delete this folder because it will be busy. The solution is to add the console device file to /dev2.
Code: Select all
if [ "`mount | cut -f 1 -d ' ' | grep devtmpfs`" = "" ] ; then
rm /pup_new${TMPFS}/dev
mkdir /pup_new${TMPFS}/dev
( cd /pup_new${TMPFS}/dev ; tar -zxf /dev2.tar.gz ; ) #no devtmpfs
fi
Code: Select all
if [ ! "`mount | cut -f 1 -d ' ' | grep devtmpfs`" = "" ] ; then
umount /dev
fi
Code: Select all
[ ! -e /etc/DISTRO_SPECS ] && cp /initrd/DISTRO_SPECS /etc/DISTRO_SPECS
Code: Select all
#Coped removed code from: s243a: https://github.com/puppylinux-woof-CE/woof-CE/commit/54ef39153265bc8e032179f188c172d15b5f02f0
# if devtmpfs fails, we're probably dealing with old stuff...
#
if [ ! -e /dev/tty ] ; then
if [ "`mount | cut -f 1 -d ' ' | grep devtmpfs`" = "" ] ; then
tar -zxf /dev2.tar.gz #no devtmpfs
( cd / ; tar -zxf /initrd/dev2.tar.gz ; ) #no devtmpfs
echo "Failed to mount devtmpfs" > /dev/console
fi
fi
Note that there is some redundancy here between /etc/rc.d/rc.sysinit and /initrd0/init but this might make it so that one of these files can be replaced and have the system still boot up successfully.
On another note I put the /etc/fstab files into the following two packages:
/puppycore_users/etc/fstab
/tinycore9_base_gz_users/etc/fstab
The reason being is that at least on dpup stretch I see some user specific settings in fstab:
Code: Select all
none /dev/pts devpts gid=2,mode=620 0 0
Note that in the official woof-CE fstab is blank, so I copied the file from dpup stretch here. On dpup stretch here is what we have for group 2:
Code: Select all
tty:x:2:
Code: Select all
tty2::respawn:getty 38400 tty2
It boots with all of the above changes except the /etc/rc.sysinit change. I will update github later tonight with the fix.