 -echo -n "Veth pair device: " && is_enabled CONFIG_VETH
 -echo -n "Macvlan: " && is_enabled CONFIG_MACVLAN
 -echo -n "Vlan: " && is_enabled CONFIG_VLAN_8021Q
+-KVER_MAJOR=$($GREP '^# Linux' $CONFIG | \
+-    sed -r 's/.* ([0-9])\.[0-9]{1,2}\.[0-9]{1,3}.*/\1/')
+-if [[ $KVER_MAJOR == 2 ]]; then
 -KVER_MINOR=$($GREP '^# Linux' $CONFIG | \
--    sed -r 's/.*2.6.([0-9]{2}).*/\1/')
--echo -n "File capabilities: " &&
--    [[ ${KVER_MINOR} < 33 ]] && is_enabled CONFIG_SECURITY_FILE_CAPABILITIES ||
--    [[ ${KVER_MINOR} > 32 ]] &&  $SETCOLOR_SUCCESS && echo -e "enabled" &&
--    $SETCOLOR_NORMAL
--
+-    sed -r 's/.* 2.6.([0-9]{2}).*/\1/')
 +is_enabled "Veth pair device: " CONFIG_VETH
 +is_enabled "Macvlan: " CONFIG_MACVLAN
 +is_enabled "Vlan: " CONFIG_VLAN_8021Q

+SETCOLOR_WARNING () { printf '\033[1;33m'; }
+SETCOLOR_NORMAL  () { printf '\033[0;39m'; }
 
-is_set() {
-    $GREP -q "$1=[y|m]" $CONFIG
+is_set () {
+    $GREP -q "$1=[y|m]" "$CONFIG"
     return $?
 }
 
-is_enabled() {
-    mandatory=$2
+is_enabled () {
+    prefix=$1
+    option=$2
+    mandatory=$3

Description: Avoid using bashisms in lxc commands.

diff -Naurp lxc.orig/src/lxc/lxc-checkconfig.in lxc/src/lxc/lxc-checkconfig.in
--- lxc.orig/src/lxc/lxc-checkconfig.in	2012-03-02 13:20:15.859239022 +0100
+++ lxc/src/lxc/lxc-checkconfig.in	2012-03-09 12:50:18.485367724 +0100
@@ -1,37 +1,40 @@
-#!/bin/bash
+#!/bin/sh
 
