Fix STM32F4_CC3100 Mongoose example compilation

PUBLISHED_FROM=7a67a67d2f0007e241e4ccb57bc24a43ba20bfde
This commit is contained in:
Alexander Alashkin 2017-01-30 13:58:16 +02:00 committed by Cesanta Bot
parent 507e8bfac9
commit 807e4ea6ec
2 changed files with 24 additions and 26 deletions

View File

@ -1,5 +1,5 @@
SDK ?= $(shell cat sdk.version)
SRC_DIR ?= $(realpath ../../..)
SRC_DIR ?= $(realpath ../..)
.PHONY: all clean
@ -8,6 +8,5 @@ MAKEFLAGS += w
all clean:
docker run --rm -i -v $(SRC_DIR):/src $(SDK) \
/bin/bash -c "\
make -C /src/mongoose mongoose.c mongoose.h && \
make -C /src/mongoose/examples/STM32F4_CC3100 -f Makefile.build $@ -$(MAKEFLAGS) \
make -C /src/examples/STM32F4_CC3100 -f Makefile.build $@ -$(MAKEFLAGS) \
"

View File

@ -13,7 +13,7 @@ STM32F4_SRCS = stm32f4xx_hal_spi.c stm32f4xx_hal_gpio.c stm32f4xx_hal_cortex.c\
SRCS = main.c mongoose.c startup_utils.c ${CC3100_DRV_SRCS} ${CC3100_PLATFORM_SRCS} ${STM32F4_SRCS}
REPO_ROOT=./../../../
REPO_ROOT=./../../
CC3100_SDKROOT=/opt/CC3100SDK_1.2.0/cc3100-sdk
STM32CUBEF4_ROOT=/opt/STM32CubeF4
STM32CUBEF4_DRV_PATH=${STM32CUBEF4_ROOT}/Drivers
@ -38,14 +38,13 @@ VPATH = ${CC3100_SDKROOT}/simplelink/source\
${CC3100_SDKROOT}/platform/stm32discovery\
${STM32CUBEF4_ROOT}/Drivers/STM32F4xx_HAL_Driver/Src\
${STM32CUBEF4_ROOT}/Drivers/BSP/STM32F4-Discovery\
${REPO_ROOT}/mongoose
${REPO_ROOT}
# CC3100 SDK and STM32 SDK include headers w/out path, just like
# #include "simplelink.h". As result, we have to add all required directories
# into IPATH
IPATH = . \
${CC3100_SDKROOT}/simplelink/include\
IPATH = . ${CC3100_SDKROOT}/simplelink/include\
${CC3100_SDKROOT}/platform/stm32discovery\
${STM32CUBEF4_DRV_PATH}/BSP/STM32F4-Discovery\
${STM32CUBEF4_DRV_PATH}/STM32F4xx_HAL_Driver/Inc\