X-Git-Url: http://git.pjr.cc/?p=wyse_ntpd.git;a=blobdiff_plain;f=src%2Fbuildroot-2013.05%2Fcustom%2Ffilesystem%2Fetc%2Finit.d%2FS01custom_pre_startup;h=55ed60d85e4001383d0ecb5f702683dee6477d62;hp=106d07a40eef6174b6e9c246cb5492ac767f9aef;hb=70a4439b4c575394cf5a91c38715cd75013cbeed;hpb=eeccf6a8f5f4f6285e41e59846b1b5e730fb6630 diff --git a/src/buildroot-2013.05/custom/filesystem/etc/init.d/S01custom_pre_startup b/src/buildroot-2013.05/custom/filesystem/etc/init.d/S01custom_pre_startup index 106d07a..55ed60d 100755 --- a/src/buildroot-2013.05/custom/filesystem/etc/init.d/S01custom_pre_startup +++ b/src/buildroot-2013.05/custom/filesystem/etc/init.d/S01custom_pre_startup @@ -1,7 +1,7 @@ #!/bin/sh # deal with our mounts -echo "Mounting normal file systems" +echo "Mounting info file systems" echo ".... proc" mkdir /proc > /dev/null 2>&1 mount -t proc proc /proc @@ -15,14 +15,6 @@ echo ".... tmpfs" mount /tmp > /dev/null 2>&1 -# create out gps0 -echo "Creating serial devices" -echo ".... gps0" -ln -s /dev/ttyS0 /dev/gps0 -echo ".... gpspps0" -mknod -m 0664 /dev/pps0 c 252 0 -ln -s /dev/pps0 /dev/gpspps0 - # mount the config file system mkdir /fs > /dev/null 2>&1 echo "Mounting /fs" @@ -105,3 +97,32 @@ EOF fi fi + +# create out gps0 +echo "Creating serial devices" +echo ".... gps0" +ln -s /dev/ttyS0 /dev/gps0 + + +# addatch the pps device +ldattach pps /dev/ttyS0 +# find the minor/major numbers of the device and create +if [ -f /sys/class/pps/pps*/dev ] +then + PPSMAJOR=`cat /sys/class/pps/pps*/dev|cut -f1 -d:` + PPSMINOR=`cat /sys/class/pps/pps*/dev|cut -f2 -d:` + echo ".... pps0" + mknod -m 0664 /dev/pps0 c $PPSMAJOR $PPSMINOR + echo ".... gpspps0" + ln -s /dev/pps0 /dev/gpspps0 +else + echo "Cant find pps device?" +fi + +if [ "x$SYSLOG_HOST" != "x" ] +then + syslogd -R $SYSLOG_HOST +fi + +# lastly, work around for thttpd problems +echo 'logfile=/dev/null' >> /var/www/thttpd_config