a patch to script 'init' which in mkinitrd-1.4.6-i486-5 - slackware-current
Make the code work when RESUMEDEV is a symbolic link which has a relative path.
Code:
diff -Naur initrd-tree-orig/init initrd-tree-new/init |
Submit your patch to Alien Bob for consideration.
|
Quote:
I'll do it later. thanks. ;) |
I think it's AlienBOB
You can find his contact from his blog: http://alien.slackbook.org/blog/ |
Quote:
Or go straight to the top: volkerdi willy, on LQ we'd post the LQ username. hello.freeman, Pat Volkerding's email is posted in many Slackware files. |
edit: deleted the last one as I think you can simplify further. (no need for all the readlink stuff)
Code:
printf '%d:%d\n' $(stat -L -c '0x%t 0x%T' $RESUMEDEV) >/sys/power/resume |
I fail to see precisely how this changes anything at all. For example:
Code:
alan@darkstar:~$ cd /home/alan Code:
alan@darkstar:~$ if [ "$RESUMEDEV" != "" ]; then Code:
alan@darkstar:~$ if [ "$RESUMEDEV" != "" ]; then |
Perhaps this demonstrates what (s)he's getting at:
Code:
gazl@slack:/$ ls -ld /dev/wibble Code:
gazl@slack;/$ RESUMEDEV='/dev/wibble' I think the change the OP suggested does the same thing but relies on changing directory in order to get the appropriate result: Code:
gazl@slack:/$ cd /dev |
BTW, those changes are tested on a real initrd? With BusyBox tools?
We known that the BusyBox utilities sometimes works slighty different... ;) |
I've not tried running it in an actual real initrd because I don't use resume, but I have confirmed that the busybox versions of printf and stat commands work as expected.
I don't really care about this issue, I just posted because I saw the ls -l | grep "^l" | awk.... stuff and thought: there must be a better way than that! ;) |
All times are GMT -5. The time now is 06:16 AM. |