aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/automake
diff options
context:
space:
mode:
authorMarti Bolivar <mbolivar@leaflabs.com>2011-02-15 22:29:45 -0500
committerMarti Bolivar <mbolivar@leaflabs.com>2011-02-16 01:17:21 -0500
commit2764748208816043a3149eae3a433d02325a1a36 (patch)
treecc5afb0af0c6f1d2282db08d3dad1dae9b4d33e6 /contrib/automake
parent1fb0e0d727089e23d4b30e1efba5410dc4b4da14 (diff)
parent620740bf1986311041a40bd2992d1b549f84b2ba (diff)
downloadlibrambutan-2764748208816043a3149eae3a433d02325a1a36.tar.gz
librambutan-2764748208816043a3149eae3a433d02325a1a36.zip
Merge branch 'nzmichaelh-master' into master.
This provides DMA, IWDG, PWR, and BKP support, and fixes several bugs. Conflicts: libmaple/adc.h libmaple/libmaple.h libmaple/ring_buffer.h
Diffstat (limited to 'contrib/automake')
-rw-r--r--contrib/automake/Makefile.am115
-rw-r--r--contrib/automake/configure.ac8
2 files changed, 123 insertions, 0 deletions
diff --git a/contrib/automake/Makefile.am b/contrib/automake/Makefile.am
new file mode 100644
index 0000000..50747db
--- /dev/null
+++ b/contrib/automake/Makefile.am
@@ -0,0 +1,115 @@
+# Top level Makefile for libmaple
+
+# The main library
+lib_LIBRARIES = \
+ libmaple.a \
+ libmapleusb.a \
+ libwirish.a
+
+noinst_PROGRAMS = \
+ main
+
+main_SOURCES = \
+ startup2.c \
+ main.cpp
+
+X = $(srcdir)/support/ld/maple_native
+
+main_LDFLAGS = \
+ --gc-sections \
+ -Map=main.map
+
+main_LDADD = libmaple.a
+
+# Main library
+libmaple_a_SOURCES = \
+ libmaple/adc.c \
+ libmaple/dac.c \
+ libmaple/exc.c \
+ libmaple/exti.c \
+ libmaple/flash.c \
+ libmaple/fsmc.c \
+ libmaple/gpio.c \
+ libmaple/nvic.c \
+ libmaple/rcc.c \
+ libmaple/spi.c \
+ libmaple/systick.c \
+ libmaple/timers.c \
+ libmaple/usart.c \
+ libmaple/util.c
+
+nobase_include_HEADERS = \
+ libmaple/adc.h \
+ libmaple/dac.h \
+ libmaple/exti.h \
+ libmaple/flash.h \
+ libmaple/fsmc.h \
+ libmaple/gpio.h \
+ libmaple/libmaple.h \
+ libmaple/libmaple_types.h \
+ libmaple/nvic.h \
+ libmaple/rcc.h \
+ libmaple/ring_buffer.h \
+ libmaple/spi.h \
+ libmaple/systick.h \
+ libmaple/timers.h \
+ libmaple/usart.h \
+ libmaple/util.h \
+ libmaple/usb/descriptors.h \
+ libmaple/usb/usb.h \
+ libmaple/usb/usb_callbacks.h \
+ libmaple/usb/usb_config.h \
+ libmaple/usb/usb_hardware.h \
+ libmaple/usb/usb_lib/usb_core.h \
+ libmaple/usb/usb_lib/usb_def.h \
+ libmaple/usb/usb_lib/usb_init.h \
+ libmaple/usb/usb_lib/usb_int.h \
+ libmaple/usb/usb_lib/usb_lib.h \
+ libmaple/usb/usb_lib/usb_mem.h \
+ libmaple/usb/usb_lib/usb_regs.h \
+ libmaple/usb/usb_lib/usb_type.h
+
+libmapleusb_a_SOURCES = \
+ libmaple/usb/descriptors.c \
+ libmaple/usb/usb.c \
+ libmaple/usb/usb_callbacks.c \
+ libmaple/usb/usb_hardware.c \
+ libmaple/usb/usb_lib/usb_core.c \
+ libmaple/usb/usb_lib/usb_init.c \
+ libmaple/usb/usb_lib/usb_int.c \
+ libmaple/usb/usb_lib/usb_mem.c \
+ libmaple/usb/usb_lib/usb_regs.c
+
+libwirish_a_SOURCES = \
+ wirish/HardwareTimer.cpp \
+ wirish/Print.cpp \
+ wirish/comm/HardwareSPI.cpp \
+ wirish/comm/HardwareSerial.cpp \
+ wirish/cxxabi-compat.cpp \
+ wirish/ext_interrupts.c \
+ wirish/pwm.c \
+ wirish/time.c \
+ wirish/usb_serial.cpp \
+ wirish/wirish.c \
+ wirish/wirish_analog.c \
+ wirish/wirish_digital.c \
+ wirish/wirish_math.cpp \
+ wirish/wirish_shift.c
+
+MCU := STM32F103RB
+BOARD ?= maple_native
+
+FLAGS = \
+ -Os -g -nostdlib -Wall \
+ -ffunction-sections -fdata-sections -Wl,--gc-sections \
+ -mcpu=cortex-m3 -mthumb -fshort-enums -mfloat-abi=soft \
+ -DBOARD_$(BOARD) -DMCU_$(MCU) -DVECT_TAB_BASE \
+ -I$(srcdir)/libmaple \
+ -I$(srcdir)/libmaple/usb \
+ -I$(srcdir)/libmaple/usb/usb_lib
+
+AM_CFLAGS = $(FLAGS) -std=gnu99
+
+AM_CXXFLAGS = $(FLAGS) \
+ -I$(srcdir)/wirish -I$(srcdir)/wirish/comm \
+ -fno-rtti -fno-exceptions
diff --git a/contrib/automake/configure.ac b/contrib/automake/configure.ac
new file mode 100644
index 0000000..4c52ce2
--- /dev/null
+++ b/contrib/automake/configure.ac
@@ -0,0 +1,8 @@
+AC_INIT(libmaple, 0.1)
+AM_INIT_AUTOMAKE(foreign subdir-objects color-tests)
+AC_CONFIG_HEADERS([config.h])
+AC_CONFIG_FILES(Makefile)
+AM_PROG_AS
+AC_PROG_CXX
+AM_PROG_LIBTOOL
+AC_OUTPUT