summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNathaniel Graff <nathaniel.graff@sifive.com>2018-12-11 15:30:57 -0800
committerNathaniel Graff <nathaniel.graff@sifive.com>2018-12-11 15:37:28 -0800
commitc63b035b06cf236e5b4eae7844e3d5ded9c8c858 (patch)
treed63cf3fec52e70fb8d1f27b6c06be70a1b4eec68
parent926417e65cd58c5b365170570a17316e2a827264 (diff)
Remove tools from Makefile
-rw-r--r--Makefile87
1 files changed, 1 insertions, 86 deletions
diff --git a/Makefile b/Makefile
index 3b9c44f..e5e5216 100644
--- a/Makefile
+++ b/Makefile
@@ -19,9 +19,6 @@ GDB_PORT ?= 3333
# Variables the user probably shouldn't override.
builddir := work/build
-installdir := work/install
-toolchain_srcdir := riscv-gnu-toolchain
-openocd_srcdir := openocd
#############################################################
# BSP Loading
@@ -68,18 +65,6 @@ help:
@echo " SiFive Freedom E Software Development Kit "
@echo " Makefile targets:"
@echo ""
- @echo " tools [BOARD=$(BOARD)]:"
- @echo " Install compilation & debugging tools to target your desired board."
- @echo ""
- @echo " toolchain-clean:"
- @echo " Removes the installed toolchain."
- @echo ""
- @echo " openocd-clean:"
- @echo " Removes the locally built instance of OpenOCD."
- @echo ""
- @echo " uninstall:"
- @echo " Uninstall the compilation & debugging tools."
- @echo ""
@echo " software [PROGRAM=$(PROGRAM) BOARD=$(BOARD)]:"
@echo " Build a software program to load with the"
@echo " debugger."
@@ -103,12 +88,9 @@ help:
@echo " For more information, visit dev.sifive.com"
#############################################################
-# This section is for tool installation
+# This section is for tool configuration
#############################################################
-.PHONY: tools
-tools: riscv-gnu-toolchain openocd
-# Pointers to various important tools in the toolchain.
toolchain_builddir := $(builddir)/riscv-gnu-toolchain/riscv64-unknown-elf
toolchain_prefix := $(toolchain_builddir)/prefix
@@ -122,73 +104,6 @@ RISCV_AR := $(abspath $(RISCV_PATH)/bin/riscv64-unknown-elf-ar)
PATH := $(abspath $(RISCV_PATH)/bin):$(PATH)
-$(RISCV_GCC) $(RISCV_GXX) $(RISCV_OBJDUMP) $(RISCV_GDB) $(RISCV_AR): $(toolchain_builddir)/install.stamp
- touch -c $@
-
-# Builds riscv-gnu-toolchain, which contains GCC and all the supporting
-# software for C code.
-.PHONY: riscv-gnu-toolchain
-riscv-gnu-toolchain: $(RISCV_GCC) $(RISCV_GXX) $(RISCV_OBJDUMP) $(RISCV_GDB) $(RISCV_AR)
-
-$(builddir)/riscv-gnu-toolchain/%/install.stamp: $(builddir)/riscv-gnu-toolchain/%/build.stamp
- $(MAKE) -C $(dir $@) install
- date > $@
-
-$(builddir)/riscv-gnu-toolchain/%/build.stamp: $(builddir)/riscv-gnu-toolchain/%/configure.stamp
- $(MAKE) -C $(dir $@)
- date > $@
-
-$(builddir)/riscv-gnu-toolchain/%-elf/configure.stamp:
- $(eval $@_TUPLE := $(patsubst $(builddir)/riscv-gnu-toolchain/%-elf/configure.stamp,%,$@))
- rm -rf $(dir $@)
- mkdir -p $(dir $@)
- cd $(dir $@); $(abspath $(toolchain_srcdir)/configure) \
- --prefix=$(abspath $(dir $@)/prefix) \
- --disable-linux \
- --enable-multilib \
- --with-cmodel=medany \
- --with-libgcc-cmodel
- date > $@
-
-.PHONY: toolchain-clean
-toolchain-clean:
- rm -rf $(toolchain_builddir)
-
-# Builds and installs OpenOCD, which translates GDB into JTAG for debugging and
-# initializing the target.
-openocd_builddir := $(builddir)/openocd
-openocd_prefix := $(openocd_builddir)/prefix
-
-RISCV_OPENOCD_PATH ?= $(openocd_prefix)
-RISCV_OPENOCD ?= $(RISCV_OPENOCD_PATH)/bin/openocd
-
-.PHONY: openocd
-openocd: $(RISCV_OPENOCD)
-
-$(RISCV_OPENOCD): $(openocd_builddir)/install.stamp
- touch -c $@
-
-$(openocd_builddir)/install.stamp: $(openocd_builddir)/build.stamp
- $(MAKE) -C $(dir $@) install
- date > $@
-
-$(openocd_builddir)/build.stamp: $(openocd_builddir)/configure.stamp
- $(MAKE) -C $(dir $@)
- date > $@
-
-$(openocd_builddir)/configure.stamp:
- rm -rf $(dir $@)
- mkdir -p $(dir $@)
- cd $(abspath $(openocd_srcdir)); autoreconf -i
- cd $(dir $@); $(abspath $(openocd_srcdir)/configure) \
- --prefix=$(abspath $(dir $@)/prefix) \
- --disable-werror
- date > $@
-
-.PHONY: openocd-clean
-openocd-clean:
- rm -rf $(openocd_builddir)
-
#############################################################
# This Section is for Software Compilation
#############################################################