fixed crosscompile badness; when --with-driver is not used, we should NOT use -I...
authorpieterg <pieterg@users.sourceforge.net>
Sat, 3 Oct 2009 18:50:47 +0000 (20:50 +0200)
committerFelix Domke <felix.domke@multimedia-labs.de>
Sun, 4 Oct 2009 19:24:52 +0000 (21:24 +0200)
packages/tuxbox/files/acinclude.m4

index ecb6a64..3c26669 100644 (file)
@@ -149,15 +149,17 @@ AC_ARG_WITH(driver,
        [  --with-driver=PATH      path for driver sources [[NONE]]],
        [DRIVER="$withval"],[DRIVER=""])
 
-if test -d "$DRIVER/include"; then
-       AC_DEFINE(HAVE_DBOX2_DRIVER,1,[Define to 1 if you have the dbox2 driver sources])
-#else
-#      AC_MSG_ERROR([can't find driver sources])
-fi
+if test "$DRIVER"; then
+       if test -d "$DRIVER/include"; then
+               AC_DEFINE(HAVE_DBOX2_DRIVER,1,[Define to 1 if you have the dbox2 driver sources])
+       #else
+       #       AC_MSG_ERROR([can't find driver sources])
+       fi
 
-AC_SUBST(DRIVER)
+       AC_SUBST(DRIVER)
 
-CPPFLAGS="$CPPFLAGS -I$DRIVER/include"
+       CPPFLAGS="$CPPFLAGS -I$DRIVER/include"
+fi
 ])
 
 AC_DEFUN([TUXBOX_APPS_DVB],[