mirror of
https://github.com/smxi/inxi.git
synced 2024-11-16 16:21:39 +00:00
bsd fixes
This commit is contained in:
parent
47a5a34cb5
commit
2b4ae02f10
37
inxi
37
inxi
|
@ -1612,10 +1612,15 @@ debug_data_collector()
|
||||||
echo 'Collecting system info: sensors, lsusb, lspci, lspci -v data, plus /proc data'
|
echo 'Collecting system info: sensors, lsusb, lspci, lspci -v data, plus /proc data'
|
||||||
echo 'also checking for dmidecode data: note, you must be root to have dmidecode work.'
|
echo 'also checking for dmidecode data: note, you must be root to have dmidecode work.'
|
||||||
echo "Data going into: $SCRIPT_DATA_DIR/$debug_data_dir"
|
echo "Data going into: $SCRIPT_DATA_DIR/$debug_data_dir"
|
||||||
# bsd tools
|
# bsd tools http://cb.vu/unixtoolbox.xhtml
|
||||||
|
pciconf -l -cv &> $debug_data_dir/bsd-pciconf-cvl.txt
|
||||||
pciconf -vl &> $debug_data_dir/bsd-pciconf-vl.txt
|
pciconf -vl &> $debug_data_dir/bsd-pciconf-vl.txt
|
||||||
|
pciconf -l &> $debug_data_dir/bsd-pciconf-l.txt
|
||||||
sysctl -a &> $debug_data_dir/bsd-sysctl-a.txt
|
sysctl -a &> $debug_data_dir/bsd-sysctl-a.txt
|
||||||
|
usbdevs -v &> $debug_data_dir/bsd-usbdevs-v.txt
|
||||||
|
kldstat &> $debug_data_dir/bsd-kldstat.txt
|
||||||
|
# diskinfo -v <disk>
|
||||||
|
# fdisk <disk>
|
||||||
dmidecode &> $debug_data_dir/dmidecode.txt
|
dmidecode &> $debug_data_dir/dmidecode.txt
|
||||||
|
|
||||||
lscpu &> $debug_data_dir/lscpu.txt
|
lscpu &> $debug_data_dir/lscpu.txt
|
||||||
|
@ -5953,11 +5958,29 @@ get_kernel_compiler_version()
|
||||||
if [[ -n $compiler_version ]];then
|
if [[ -n $compiler_version ]];then
|
||||||
compiler_type='gcc'
|
compiler_type='gcc'
|
||||||
fi
|
fi
|
||||||
elif [[ $BSD_TYPE == 'darwin-bsd' ]];then
|
else
|
||||||
if type -p gcc &>/dev/null;then
|
if [[ $BSD_TYPE == 'darwin-bsd' ]];then
|
||||||
compiler_version=$( get_program_version 'gcc' 'Apple[[:space:]]LLVM' '4' )
|
if type -p gcc &>/dev/null;then
|
||||||
if [[ -n $compiler_version ]];then
|
compiler_version=$( get_program_version 'gcc' 'Apple[[:space:]]LLVM' '4' )
|
||||||
compiler_type='LLVM'
|
if [[ -n $compiler_version ]];then
|
||||||
|
compiler_type='LLVM'
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
else
|
||||||
|
if [[ -f /etc/src.conf ]];then
|
||||||
|
compiler_type=$( grep '^CC' /etc/src.conf | cut -d '=' -f 2 )
|
||||||
|
elif [[ -f /etc/make.conf ]];then
|
||||||
|
compiler_type=$( grep '^CC' /etc/make.conf | cut -d '=' -f 2 )
|
||||||
|
fi
|
||||||
|
if [[ -n $compiler_type ]];then
|
||||||
|
if type -p $compiler_type &>/dev/null;then
|
||||||
|
if [[ $compiler_type == 'gcc' ]];then
|
||||||
|
compiler_version=$( get_program_version 'gcc' '^gcc' '3' )
|
||||||
|
elif [[ $compiler_type == 'clang' ]];then
|
||||||
|
# FreeBSD clang version 3.0 (tags/RELEASE_30/final 145349) 20111210
|
||||||
|
compiler_version=$( get_program_version 'clang' 'clang' '4' )
|
||||||
|
fi
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in a new issue