/
githubmirror
/
swtpm
Обзор
Документация
Войти
/
githubmirror
/
swtpm
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
v0.5.2
tests/test_cuse
25 строк
618 B
Stefan Berger
tests: Skip CUSE tests if not compiled with CUSE interface
11 июн 2018, 17:35
11 июн 2018, 17:35
03e5abe
Код
Авторство
О чём код?
# For the license, see the LICENSE file in the root directory. if ! [[ "$(uname -s)" =~ Linux ]]; then echo "Need Linux to run test with CUSE interface." exit 77 fi if [ "$(id -u)" -ne 0 ]; then echo "Need to be root to run test with CUSE interface." exit 77 fi if [ -z "$(grep -E '#[[:blank:]]*define[[:blank:]]+WITH_CUSE[[:blank:]]+1[[:blank:]]*$' \ ${PWD}/../config.h)" ]; then echo "Skipping test: swtpm was not compiled with CUSE interface" exit 77 fi if [ ! -c /dev/cuse ]; then modprobe cuse if [ $? -ne 0 ]; then echo "Skipping test using CUSE module: module not availabe" exit 77 fi fi