Issue # 171

This commit is contained in:
jspectacular
2018-11-07 01:17:39 +00:00
parent abf58069ad
commit 2addc972a6
3 changed files with 44 additions and 2 deletions

View File

@@ -79,7 +79,7 @@ LLIBS += -Wl,--end-group
OBJCOPY = $(TOOLCHAIN)/bin/arm-none-eabi-objcopy
all: oc_connect1
all: get_cfg oc_connect1
oc_connect1: $(OUT)/OpenCellular.bin
$(OUT)/%/compiler.opt $(OUT)/%/linker.cmd : %.cfg
@@ -95,6 +95,9 @@ $(OUT)/OpenCellular.out: $(OUT)/$(CONFIG)/linker.cmd $(MAIN_OBJS)
$(OUT)/OpenCellular.bin: $(OUT)/OpenCellular.out
$(OBJCOPY) -S -O binary $< $@
get_cfg:
cd ../utilities/build; ./envDetect.sh $(CC) $(TIRTOS_DIR)
clean:
-rm -rf *.o *.out *.d *.rov.xs $(OUT) $(MAIN_OBJS) $(COVERAGE_OBJS)

View File

@@ -15,7 +15,10 @@ default:
@mkdir -p $(output_dir)
make all
all: ocmw_uart ocmw_usb ocmw_eth occli ocmw_eth_stub ocware_stub
all: get_cfg ocmw_uart ocmw_usb ocmw_eth occli ocmw_eth_stub ocware_stub
get_cfg:
cd ../utilities/build; ./envDetect.sh
.PHONY: occli

View File

@@ -0,0 +1,36 @@
#!/bin/sh -e
BUILDHOST=$(uname -a)
GCCVER=$(gcc --version)
GITHASH=$(git rev-parse HEAD)
if [ $# = 2 ]; then
BUILDTYPE="\tEC Build"
BUILDFNAME="build_ec_cfg.txt"
if [ -e "$1" ]; then
ARMVER=$($1 --version)
else
ARMVER="arm-none-eabi-gcc: Not found"
fi
if [ -d "$2" ]; then
TIRTOSVER="TI RTOS: $2"
else
TIRTOSVER="TI RTOS: Not found"
fi
else
BUILDTYPE="\tHost Build"
BUILDFNAME="build_host_cfg.txt"
ARMVER=""
TIRTOSVER=""
fi
{
echo "$BUILDTYPE"
echo
echo "GIT Hash: $GITHASH"
echo
echo "Build Host: $BUILDHOST"
echo
echo "$GCCVER"
echo
echo "$ARMVER"
echo
echo "$TIRTOSVER"
} > $BUILDFNAME