From: Roy Marples Date: Mon, 3 Mar 2014 15:48:07 +0000 (+0000) Subject: Fudge deriving os from Debian style X-Git-Tag: v6.3.2~42 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=cb8d2c35cc5f0c6907a419ec497165d9a60f238d;p=thirdparty%2Fdhcpcd.git Fudge deriving os from Debian style --- diff --git a/configure b/configure index 5cf08689..52ce5b0d 100755 --- a/configure +++ b/configure @@ -196,20 +196,21 @@ if [ -z "$TARGET" ]; then fi if [ -z "$OS" ]; then - # Derive OS from cpu-vendor-os-kernel + # Derive OS from cpu-vendor-[kernel-]os CPU=${TARGET%%-*} REST=${TARGET#*-} if [ "$CPU" != "$REST" ]; then VENDOR=${REST%%-*} REST=${REST#*-} if [ "$VENDOR" != "$REST" ]; then - OS=${REST%%-*} + KERNEL=${REST%%-*} REST=${REST#*-} - if [ "$OS" != "$REST" ]; then + if [ "$KERNEL" != "$REST" ]; then # 4 tupple - KERNEL=${REST%%-*} + OS=${REST%%-*} else # 3 tupple + OS=$KERNEL KERNEL= fi else @@ -218,6 +219,13 @@ if [ -z "$OS" ]; then VENDOR= fi fi + + # Work with cpu-kernel-os, ie Debian + if [ "$VENDOR" = linux ]; then + KERNEL=$OS + OS=linux + VENDOR= + fi fi echo "Configuring dhcpcd for ... $OS"