rtai-info
1 #!/bin/sh 2 # 3 # This file has been lifted 'as is' from linux/scripts/ver_linux. 4 # 5 6 PATH=/sbin:/usr/sbin:/bin:/usr/bin:/usr/local/sbin:$PATH 7 echo 'If some fields are empty or look unusual you may have an old version.' 8 echo 'Compare to the current minimal requirements in Documentation/Changes.' 9 echo ' ' 10 11 uname -a 12 echo ' ' 13 14 gcc --version 2>&1| head -n 1 | grep -v gcc | awk \ 15 'NR==1{print "Gnu C ", $1}' 16 17 gcc --version 2>&1| grep gcc | awk \ 18 'NR==1{print "Gnu C ", $3}' 19 20 make --version 2>&1 | awk -F, '{print $1}' | awk \ 21 '/GNU Make/{print "Gnu make ",$NF}' 22 23 ld -v 2>&1 | awk -F\) '{print $1}' | awk \ 24 '/BFD/{print "binutils ",$NF}' 25 26 fdformat --version | awk -F\- '{print "util-linux ", $NF}' 27 28 mount --version | awk -F\- '{print "mount ", $NF}' 29 30 depmod -V 2>&1 | awk 'NR==1 {print "module-init-tools ",$NF}' 31 32 tune2fs 2>&1 | grep "^tune2fs" | sed 's/,//' | awk \ 33 'NR==1 {print "e2fsprogs ", $2}' 34 35 fsck.jfs -V 2>&1 | grep version | sed 's/,//' | awk \ 36 'NR==1 {print "jfsutils ", $3}' 37 38 reiserfsck -V 2>&1 | grep reiserfsprogs | awk \ 39 'NR==1{print "reiserfsprogs ", $NF}' 40 41 xfs_db -V 2>&1 | grep version | awk \ 42 'NR==1{print "xfsprogs ", $3}' 43 44 cardmgr -V 2>&1| grep version | awk \ 45 'NR==1{print "pcmcia-cs ", $3}' 46 47 pppd --version 2>&1| grep version | awk \ 48 'NR==1{print "PPP ", $3}' 49 50 isdnctrl 2>&1 | grep version | awk \ 51 'NR==1{print "isdn4k-utils ", $NF}' 52 53 ls -l `ldd /bin/sh | awk '/libc/{print $3}'` | sed \ 54 -e 's/\.so$//' | awk -F'[.-]' '{print "Linux C Library " \ 55 $(NF-2)"."$(NF-1)"."$NF}' 56 57 ldd -v > /dev/null 2>&1 && ldd -v || ldd --version |head -1 | awk \ 58 'NR==1{print "Dynamic linker (ldd) ", $NF}' 59 60 ls -l /usr/lib/lib{g,stdc}++.so 2>/dev/null | awk -F. \ 61 '{print "Linux C++ Library " $4"."$5"."$6}' 62 63 ps --version 2>&1 | awk 'NR==1{print "Procps ", $NF}' 64 65 ifconfig --version 2>&1 | grep tools | awk \ 66 'NR==1{print "Net-tools ", $NF}' 67 68 # Kbd needs 'loadkeys -h', 69 loadkeys -h 2>&1 | awk \ 70 '(NR==1 && ($3 !~ /option/)) {print "Kbd ", $3}' 71 72 # while console-tools needs 'loadkeys -V'. 73 loadkeys -V 2>&1 | awk \ 74 '(NR==1 && ($2 ~ /console-tools/)) {print "Console-tools ", $3}' 75 76 expr --v 2>&1 | awk 'NR==1{print "Sh-utils ", $NF}' 77 78 if [ -e /proc/modules ]; then 79 X=`cat /proc/modules | sed -e "s/ .*$//"` 80 echo "Modules Loaded "$X 81 fi