Skip to content

Commit

Permalink
Merge pull request #202 from GreenWaves-Technologies/3.9_dev
Browse files Browse the repository at this point in the history
Update for release 3.9.1
  • Loading branch information
Yaooooo authored Mar 15, 2021
2 parents 092a315 + c18bfce commit bbdec24
Show file tree
Hide file tree
Showing 999 changed files with 256,850 additions and 145,345 deletions.
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
__pycache__*
*.pyc
*.swp
*log*
*.log
install
build
*.wav
Expand Down
61 changes: 45 additions & 16 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,12 @@ TIMEOUT ?= 300

PULP_BRIDGE_PATH = $(GAP_SDK_HOME)/tools/pulp_tools/pulp-debug-bridge

checkout:
git submodule update --recursive --init

ifeq ($(TARGET_CHIP_FAMILY), GAP8)
sdk: all autotiler nntool openocd
all: pulp-os tools gvsoc flasher docs littlefs.build openocd_scripts
sdk: all autotiler nntool openocd.build
all: pulp-os tools gvsoc flasher docs littlefs.build openocd_tools.build

clean: littlefs.clean
$(RM) $(TARGET_INSTALL_DIR)
Expand All @@ -65,7 +68,7 @@ clean: littlefs.clean
$(RM) $(TARGET_INSTALL_DIR)
$(RM) $(BUILD_DIR)
endif
minimal_sdk: freertos pmsis-bsp.checkout pmsis-api.checkout gapy.all examples.checkout openocd_scripts
minimal_sdk: freertos pmsis-bsp.checkout pmsis-api.checkout gapy.all examples.checkout openocd_tools.build
freertos: freertos.all openmp.all gap_lib.all

# Rules for installing docs
Expand All @@ -86,7 +89,7 @@ install_others: | $(INSTALL_BIN_DIR)
$(CP) $(GAP_SDK_HOME)/tools/rules $(INSTALL_DIR)

install_pulp_tools: install_others plptest.build
$(MAKE) -C $(GAP_SDK_HOME)/tools/pulp_tools all
#$(MAKE) -C $(GAP_SDK_HOME)/tools/pulp_tools all

tools: install_others install_pulp_tools

Expand Down Expand Up @@ -117,26 +120,52 @@ gap_lib.checkout:

gap_lib.all: gap_lib.checkout


ifeq ($(TARGET_CHIP_FAMILY), GAP8)

openocd_tools.checkout:
git submodule update --init --recursive tools/gap8-openocd-tools

openocd_tools.all: openocd_tools.checkout
mkdir -p $(INSTALL_DIR)/share/openocd/scripts/tcl
cd tools/gap8-openocd-tools && cp -r tcl/* $(INSTALL_DIR)/share/openocd/scripts/tcl
cd tools/gap8-openocd-tools && mkdir -p $(INSTALL_DIR)/share/openocd/gap_bins && cp -r gap_bins/* $(INSTALL_DIR)/share/openocd/gap_bins
openocd_tools.build:
mkdir -p $(INSTALL_DIR)/gap8-openocd/share/openocd/scripts/tcl
cd tools/gap8-openocd-tools && cp -r tcl/* $(INSTALL_DIR)/gap8-openocd/share/openocd/scripts/tcl
cd tools/gap8-openocd-tools && mkdir -p $(INSTALL_DIR)/gap8-openocd/share/openocd/gap_bins && cp -r gap_bins/* $(INSTALL_DIR)/gap8-openocd/share/openocd/gap_bins

openocd_tools.all: openocd_tools.checkout openocd_tools.build


openocd.checkout:
git submodule update --init --recursive tools/gap8-openocd

openocd: openocd.checkout
openocd.build:
cd tools/gap8-openocd && ./bootstrap
cd tools/gap8-openocd && ./configure --prefix=$(INSTALL_DIR) --program-prefix=gap8-
cd tools/gap8-openocd && ./configure --prefix=$(INSTALL_DIR)/gap8-openocd --program-prefix=gap8-
cd tools/gap8-openocd && make -j install
mkdir -p $(INSTALL_DIR)/share/openocd/scripts/tcl
cd tools/gap8-openocd-tools && cp -r tcl/* $(INSTALL_DIR)/share/openocd/scripts/tcl
cd tools/gap8-openocd-tools && mkdir -p $(INSTALL_DIR)/share/openocd/gap_bins && cp -r gap_bins/* $(INSTALL_DIR)/share/openocd/gap_bins
mkdir -p $(INSTALL_DIR)/gap8-openocd/share/openocd/scripts/tcl
cd tools/gap8-openocd-tools && cp -r tcl/* $(INSTALL_DIR)/gap8-openocd/share/openocd/scripts/tcl
cd tools/gap8-openocd-tools && mkdir -p $(INSTALL_DIR)/gap8-openocd/share/openocd/gap_bins && cp -r gap_bins/* $(INSTALL_DIR)/gap8-openocd/share/openocd/gap_bins

openocd.all: openocd.checkout openocd.build

else

openocd.clean:
rm -rf $(INSTALL_DIR)/openocd tools/openocd

openocd.checkout:
if [ ! -e tools/openocd ]; then \
git clone https://github.com/riscv/riscv-openocd.git tools/openocd; \
cd tools/openocd; \
git checkout c56aa667c2ffee906a6d7a7084b70bece863fc73; \
fi

openocd.build:
cd tools/openocd && ./bootstrap && ./configure --enable-jtag_dpi --prefix=$(INSTALL_DIR)/openocd && make && make install

openocd.all: openocd.checkout openocd.build

endif

openocd_scripts: openocd_tools.all

profiler:
$(MAKE) -C tools/profiler all
Expand Down Expand Up @@ -200,7 +229,7 @@ gapy.all: gapy.checkout gap-configs.all


tests.checkout:
git submodule update --init tests/pmsis_tests tests/bsp_tests
git submodule update --init tests/pmsis_tests tests/bsp_tests tests/sfu_tests


pulpos.checkout:
Expand Down Expand Up @@ -236,7 +265,7 @@ freertos.all: freertos.checkout


gvsoc.checkout:
git submodule update --init gvsoc/gvsoc gvsoc/gvsoc_gap
git submodule update --init gvsoc/gvsoc gvsoc/gvsoc_gap gvsoc/gvsoc_gap_sfu

gvsoc.build:
make -C gvsoc/gvsoc build BUILD_DIR=$(BUILD_DIR)/gvsoc INSTALL_DIR=$(INSTALL_DIR) TARGET_INSTALL_DIR=$(GAP_SDK_HOME)/install
Expand Down
Loading

0 comments on commit bbdec24

Please sign in to comment.