]> git.webhop.me Git - lcd4linux.git/commitdiff
only use picoLCD if libusb is available
authormichael <michael@3ae390bd-cb1e-0410-b409-cd5a39f66f1f>
Mon, 5 Feb 2007 06:26:10 +0000 (06:26 +0000)
committermichael <michael@3ae390bd-cb1e-0410-b409-cd5a39f66f1f>
Mon, 5 Feb 2007 06:26:10 +0000 (06:26 +0000)
git-svn-id: https://ssl.bulix.org/svn/lcd4linux/trunk@763 3ae390bd-cb1e-0410-b409-cd5a39f66f1f

configure
drivers.m4

index 8771f90ee4cd37fe09b861b6a25e0b4d5c4a2675..457531bd6b24cb905a37ee83cca2111a10f35b58 100755 (executable)
--- a/configure
+++ b/configure
@@ -7643,16 +7643,20 @@ _ACEOF
 fi
 
 if test "$picoLCD" = "yes"; then
-   TEXT="yes"
-   GPIO="yes"
-   SERIAL="yes"
-   #I2C="yes"
-   DRIVERS="$DRIVERS drv_picoLCD.o"
+   if test "$has_usb" = "true"; then
+      TEXT="yes"
+      GPIO="yes"
+      SERIAL="yes"
+      DRIVERS="$DRIVERS drv_picoLCD.o"
 
 cat >>confdefs.h <<\_ACEOF
 #define WITH_picoLCD 1
 _ACEOF
 
+   else
+      { echo "$as_me:$LINENO: WARNING: usb.h not found: picoLCD driver disabled" >&5
+echo "$as_me: WARNING: usb.h not found: picoLCD driver disabled" >&2;}
+   fi
 fi
 
 if test "$PNG" = "yes"; then
index 32a624e4c4814b7dca17c85bac5dfb1e51920615..756e2b70544320c900c6174516a143a918268385 100644 (file)
@@ -392,12 +392,15 @@ if test "$NULL" = "yes"; then
 fi
 
 if test "$picoLCD" = "yes"; then
-   TEXT="yes"
-   GPIO="yes"
-   SERIAL="yes"
-   #I2C="yes"
-   DRIVERS="$DRIVERS drv_picoLCD.o"
-   AC_DEFINE(WITH_picoLCD,1,[picoLCD driver])
+   if test "$has_usb" = "true"; then
+      TEXT="yes"
+      GPIO="yes"
+      SERIAL="yes"
+      DRIVERS="$DRIVERS drv_picoLCD.o"
+      AC_DEFINE(WITH_picoLCD,1,[picoLCD driver])
+   else
+      AC_MSG_WARN(usb.h not found: picoLCD driver disabled)
+   fi
 fi
 
 if test "$PNG" = "yes"; then