You are not logged in.

#1 2005-05-05 04:42:08

dtw
Forum Fellow
From: UK
Registered: 2004-08-03
Posts: 4,439
Website

Help with a bit of splash script code

How can I fix this to work with devfs AND udev in Arch?  I use udev now and I have no /dev/tty1 at all.   I don't know enough about how the /dev fs works so any ideas?

mount --bind / ${spl_tmpdir}
if [[ ! -c "${spl_tmpdir}/dev/tty1" ]]; then
    umount ${spl_tmpdir}
    clear
    echo "The filesystem mounted on / doesn't contain the /dev/tty1 device"
    echo "which is required for the silent splash to function properly."
    exit 1
fi
umount ${spl_tmpdir}

Offline

#2 2005-05-05 05:06:23

Vinny
Member
From: the fifth floor
Registered: 2005-04-25
Posts: 29

Re: Help with a bit of splash script code

I think what you are looking for is /dev/vc/1 in udev.
If your script can look for a character device in /dev/ with major number 4, minor number 1,
then it should work with devfs, udev, and static /dev.
HTH  :-)

Offline

#3 2005-05-08 03:57:18

dtw
Forum Fellow
From: UK
Registered: 2004-08-03
Posts: 4,439
Website

Re: Help with a bit of splash script code

could you be more specific?

the snippet of script comes from gentoo code and I can't switch back to devfs just to iron out all eventualities you see smile

Offline

#4 2005-05-08 06:32:01

Vinny
Member
From: the fifth floor
Registered: 2005-04-25
Posts: 29

Re: Help with a bit of splash script code

OK first the obvious fix: change the if statement to

if [[ ! -c "${spl_tmpdir}/dev/tty1" && ! -c "${spl_tmpdir}/dev/vc/1" ]]; then

and then set a variable to whichever one was found, replacing
each occurance of "/dev/tty1" with that variable.
They're just 2 different names for the same 'device'.
When does this script run? Before udevd? that might complicate things...

Offline

#5 2005-05-08 10:03:25

dtw
Forum Fellow
From: UK
Registered: 2004-08-03
Posts: 4,439
Website

Re: Help with a bit of splash script code

it runs after udev - my basic problem i think you have answered tho - is the device called /dev/tty1 under devfs and /dev/vc/1 under udev?  If that is the case i can quite happily go from there!

Looks like you can also use some thing like

find /dev -ls -type c | grep

dunno what you would grep for as I am in windows and can't use my trial and error methodology - but this might be pretty bullet proof!

Offline

Board footer

Powered by FluxBB