Updated FSF address in all files. Fixes ticket:51
[debian/gnuradio] / config / grc_ezdop.m4
1 dnl Copyright 2001,2002,2003,2004,2005,2006 Free Software Foundation, Inc.
2 dnl 
3 dnl This file is part of GNU Radio
4 dnl 
5 dnl GNU Radio is free software; you can redistribute it and/or modify
6 dnl it under the terms of the GNU General Public License as published by
7 dnl the Free Software Foundation; either version 2, or (at your option)
8 dnl any later version.
9 dnl 
10 dnl GNU Radio is distributed in the hope that it will be useful,
11 dnl but WITHOUT ANY WARRANTY; without even the implied warranty of
12 dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13 dnl GNU General Public License for more details.
14 dnl 
15 dnl You should have received a copy of the GNU General Public License
16 dnl along with GNU Radio; see the file COPYING.  If not, write to
17 dnl the Free Software Foundation, Inc., 51 Franklin Street,
18 dnl Boston, MA 02110-1301, USA.
19
20 AC_DEFUN([GRC_EZDOP],[
21     GRC_ENABLE([ezdop])
22
23     AC_CONFIG_FILES([ \
24         ezdop/Makefile \
25         ezdop/ezdop.pc \
26         ezdop/src/Makefile \
27         ezdop/src/firmware/Makefile \
28         ezdop/src/host/Makefile \
29         ezdop/src/host/avrdude/Makefile \
30         ezdop/src/host/ezdop/Makefile \
31         ezdop/src/host/tests/Makefile \
32     ])
33
34     passed=yes
35
36     # Firmware build requires Atmel AVR microcontroller port of GCC
37     AC_PATH_PROG([AVRGCC], [avr-gcc -v], [no])
38     if test x$AVRGCC = xno; then
39         passed=no
40         AC_MSG_RESULT([ezdop requires avr-gcc, not found.])
41     fi
42     
43     # ...and binutils
44     AC_PATH_PROG([AVROBJCOPY], [avr-objcopy], [no])
45     if test x$AVROBJCOPY = xno; then
46         passed=no
47         AC_MSG_RESULT([ezdop requires avr binutils, not found.])
48     fi
49     
50     # ...and standard library (test not working yet)
51     #AC_CHECK_HEADERS([avr/io.h],[],
52     #   [passed=no;AC_MSG_RESULT([ezdop requires avr glibc, not found.])])
53
54     # Device access is via libftdi
55     AC_LANG_PUSH(C)
56     AC_CHECK_HEADERS([ftdi.h],[],
57         [passed=no;AC_MSG_RESULT([ezdop requires ftdi.h, not found.])])
58     save_LIBS="$LIBS"
59     AC_SEARCH_LIBS([ftdi_init], [ftdi],[FTDI_LIBS="$LIBS"],
60         [passed=no;AC_MSG_RESULT([ezdop requires libftdi, not found.])])
61     LIBS="$save_LIBS"
62     AC_LANG_POP
63
64     GRC_BUILD_CONDITIONAL([ezdop],[
65         EZDOP_INCLUDES='-I$(top_srcdir)/ezdop/src/host/ezdop/ -I$(top_srcdir)/ezdop/src/firmware/'
66         EZDOP_LIBS='-lezdop'
67         AC_SUBST(FTDI_LIBS)
68         AC_SUBST(EZDOP_INCLUDES)
69         AC_SUBST(EZDOP_LIBS)
70         AC_SUBST(AVRGCC)
71         AC_SUBST(AVROBJCOPY)
72     ])
73 ])