diff --git a/.gitignore b/.gitignore index 29a46e64583fc273efe3209bbba3d6e3b5d202a9..a9fc19c63acb43f60a677bcfe7a671a1c5264fff 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,7 @@ # .gitignore file +xcompiler/* + # OS generated files # ###################### *.bak diff --git a/Makefile b/Makefile index 7880e39cccdd1f3b5d73bd6c57090783dec90ab3..938ce2d7fd8b7fc0a4b27d943541d8e38be4223e 100644 --- a/Makefile +++ b/Makefile @@ -17,6 +17,11 @@ SUBMOD_DIRS=spec-sw wr-nic fmc-dio wrpc-sw coht-vic MAKE_DIRS = spec-sw wr-nic fmc-dio wrpc-sw coht-vic #tools +LM32_XCOMPILER_URL="https://www.ohwr.org/project/wrpc-sw/uploads/2776ce0ba43503d1486ae205b48fb450" +LM32_XCOMPILER_NAME="lm32_host_64bit.tar.xz" +XCOMPILER_DIR="xcompiler" +LM32_XCOMPILER_NAME_DIR="lm32-gcc-4.5.3" + #RUNME := $(shell test -d $(FMC_DRV) || git submodule update --init) ## Call the sub folder Makefiles @@ -40,14 +45,9 @@ patch: update: ./scripts/wr-ssk-get -f git submodule update - cd spec-sw - git submodule update - cd wr-nic - git submodule update - cd fmc-dio - git submodule update - cd wrpc-sw - git submodule update - cd coht-vic - git submodule update - + @rm -rf $(XCOMPILER_DIR) + mkdir -p $(XCOMPILER_DIR) + cd $(XCOMPILER_DIR) && wget $(LM32_XCOMPILER_URL)/$(LM32_XCOMPILER_NAME) \ + && tar xvf $(LM32_XCOMPILER_NAME) + cd wrpc-sw && make spec_defconfig && \ + CROSS_COMPILE="$(shell pwd)/$(XCOMPILER_DIR)/$(LM32_XCOMPILER_NAME_DIR)/bin/lm32-elf-" make