2 # avrdude - A Downloader/Uploader for AVR device programmers
3 # Copyright (C) 2003-2004 Theodore A. Roth <troth@openavr.org>
4 # Copyright (C) 2005 Johnathan Corgan <jcorgan@aeinet.com>
6 # This program is free software; you can redistribute it and/or modify
7 # it under the terms of the GNU General Public License as published by
8 # the Free Software Foundation; either version 2 of the License, or
9 # (at your option) any later version.
11 # This program is distributed in the hope that it will be useful,
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 # GNU General Public License for more details.
16 # You should have received a copy of the GNU General Public License
17 # along with this program; if not, write to the Free Software
18 # Foundation, Inc., 51 Franklin Street, Boston, MA 02110-1301 USA
25 [--enable-ftdi-support],
26 [support serial programming via FTDI bit-bang mode (default is no)]),
27 [case "${enableval}" in
28 yes) ftdi_support=yes ;;
29 no) ftdi_support=no ;;
30 *) AC_MSG_ERROR(bad value ${enableval} for ftdi-support option) ;;
33 AM_CONDITIONAL(FTDI_SUPPORT, [test "$ftdi_support" = "yes"])
35 if test "$ftdi_support" = "yes"; then
36 AC_REQUIRE([AC_CANONICAL_HOST])
39 AC_CHECK_HEADERS([ftdi.h],
41 [ AC_MSG_ERROR([FTDI support requires libftdi. ftdi.h not found, stop.]) ]
45 AC_SEARCH_LIBS(ftdi_init, [ftdi],
47 [ AC_MSG_ERROR([FTDI support requires libftdi. ftdi_init not found, stop.]) ]
54 AC_DEFINE(FTDI_SUPPORT,[1],[Set to 1 to compile in support for FTDI bit-bang mode programming.])