Merge branch 'master' of github.com:paparazzi/paparazzi

This commit is contained in:
Christophe De Wagter
2011-11-22 14:05:31 +01:00
2 changed files with 9 additions and 5 deletions
+5 -4
View File
@@ -44,10 +44,6 @@ TOOLCHAIN_DIR=$(shell dirname $(TOOLCHAIN))
GCC_BIN_DIR=$(TOOLCHAIN_DIR)/bin GCC_BIN_DIR=$(TOOLCHAIN_DIR)/bin
GCC_LIB_DIR=$(TOOLCHAIN_DIR)/arm-none-eabi/lib GCC_LIB_DIR=$(TOOLCHAIN_DIR)/arm-none-eabi/lib
# Detect if we are using the new libopencm3 or the old libopenstm32
LIBOPENCM3_LIB=$(shell if [ -e "$(GCC_LIB_DIR)/libopencm3_stm32f1.a" ]; then echo "opencm3_stm32f1"; else echo "opencm3_stm32"; fi)
LIBOPENCM3_DEFS=$(shell if [ -e "$(GCC_LIB_DIR)/libopencm3_stm32f1.a" ]; then echo "-DSTM32F1"; fi)
# Define programs and commands. # Define programs and commands.
GCC_BIN_PREFIX=$(GCC_BIN_DIR)/arm-none-eabi GCC_BIN_PREFIX=$(GCC_BIN_DIR)/arm-none-eabi
CC = $(GCC_BIN_PREFIX)-gcc CC = $(GCC_BIN_PREFIX)-gcc
@@ -66,9 +62,14 @@ CP = $(shell which arm-none-eabi-objcopy)
DMP = $(shell which arm-none-eabi-objdump) DMP = $(shell which arm-none-eabi-objdump)
NM = $(shell which arm-none-eabi-nm) NM = $(shell which arm-none-eabi-nm)
SIZE = $(shell which arm-none-eabi-size) SIZE = $(shell which arm-none-eabi-size)
RM = rm
GCC_LIB_DIR=$(shell dirname `which arm-none-eabi-gcc`)/../arm-none-eabi/lib GCC_LIB_DIR=$(shell dirname `which arm-none-eabi-gcc`)/../arm-none-eabi/lib
endif endif
# Detect if we are using the new libopencm3 or the old libopenstm32
LIBOPENCM3_LIB=$(shell if [ -e "$(GCC_LIB_DIR)/libopencm3_stm32f1.a" ]; then echo "opencm3_stm32f1"; else echo "opencm3_stm32"; fi)
LIBOPENCM3_DEFS=$(shell if [ -e "$(GCC_LIB_DIR)/libopencm3_stm32f1.a" ]; then echo "-DSTM32F1"; fi)
#first try to find OpenOCD in the path #first try to find OpenOCD in the path
OOCD = $(shell which openocd) OOCD = $(shell which openocd)
#if OpenOCD could not be found in the path, try the toolchain dir #if OpenOCD could not be found in the path, try the toolchain dir
+4 -1
View File
@@ -232,7 +232,10 @@ let parse_firmware = fun makefile_ac firmware ->
(* print makefile for this target *) (* print makefile for this target *)
fprintf makefile_ac "\n###########\n# -target: '%s'\n" (Xml.attrib target "name"); fprintf makefile_ac "\n###########\n# -target: '%s'\n" (Xml.attrib target "name");
fprintf makefile_ac "ifeq ($(TARGET), %s)\n" (Xml.attrib target "name"); fprintf makefile_ac "ifeq ($(TARGET), %s)\n" (Xml.attrib target "name");
try fprintf makefile_ac "BOARD_PROCESSOR = %s\n" (Xml.attrib target "processor") with _ -> (); begin (* Check for "processor" attribute *)
try fprintf makefile_ac "BOARD_PROCESSOR = %s\n" (Xml.attrib target "processor")
with _ -> ()
end;
List.iter (print_firmware_configure makefile_ac) config; List.iter (print_firmware_configure makefile_ac) config;
List.iter (print_firmware_configure makefile_ac) t_config; List.iter (print_firmware_configure makefile_ac) t_config;
List.iter (print_firmware_define makefile_ac) defines; List.iter (print_firmware_define makefile_ac) defines;