4 # Script to generate Makefile.am,
5 # execute in device/lib/pic16/libio/ with no arguments.
7 # Written by Raphael Neider <tecodev AT users sourceforge net>
9 # Released under the terms of the GPL v2.
13 ## Makefile.am -- Process this file with automake to produce Makefile.in
14 ## This file was automatically generated using $0.
20 for f
in "../../../non-free/lib/pic16/libdev/pic1"*.c
; do
23 P
=$
(echo "$p" |
tr abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ
);
24 echo "Generating for device >>${p}<<" >&2;
27 lib_LIBRARIES += libio${p}.a
29 libio${p}_a_SOURCES = dummy.c
31 sed -e 's/\s*\(#.*\)\{0,1\}$//' adc.ignore |
grep -x "$p" > /dev
/null
2>&1 && { echo "No adc." >&2 ; } ||
cat <<HERE
32 libio${p}_a_SOURCES += adc/adcbusy.c adc/adcclose.c adc/adcconv.c
33 libio${p}_a_SOURCES += adc/adcopen.c adc/adcread.c adc/adcsetch.c
35 sed -e 's/\s*\(#.*\)\{0,1\}$//' i2c.ignore |
grep -x "$p" > /dev
/null
2>&1 && { echo "No i2c." >&2 ; } ||
cat <<HERE
36 libio${p}_a_SOURCES += i2c/i2cack.c i2c/i2cclose.c i2c/i2cdrdy.c
37 libio${p}_a_SOURCES += i2c/i2cidle.c i2c/i2cnack.c i2c/i2copen.c
38 libio${p}_a_SOURCES += i2c/i2creadc.c i2c/i2creads.c i2c/i2crestart.c
39 libio${p}_a_SOURCES += i2c/i2cstart.c i2c/i2cstop.c i2c/i2cwritec.c
40 libio${p}_a_SOURCES += i2c/i2cwrites.c
42 sed -e 's/\s*\(#.*\)\{0,1\}$//' usart.ignore |
grep -x "$p" > /dev
/null
2>&1 && { echo "No usart." >&2 ; } ||
cat <<HERE
43 libio${p}_a_SOURCES += usart/ubaud.c usart/ubusy.c usart/uclose.c
44 libio${p}_a_SOURCES += usart/udrdy.c usart/ugetc.c usart/ugets.c
45 libio${p}_a_SOURCES += usart/uopen.c usart/uputc.c usart/uputs.c
46 libio${p}_a_SOURCES += usart/usartd.c
49 libio${p}_a_CFLAGS = -p${p} \$(AM_CFLAGS)
55 include \$(top_srcdir)/Makefile.common