From 3148ee1df5d8ee50e2b693f258431535ce6ba7f0 Mon Sep 17 00:00:00 2001 From: Andrew Waterman Date: Sun, 2 Jun 2013 19:01:57 -0700 Subject: [PATCH] use coreutils `seq' instead of hacky `range' --- Makefile.in | 10 ---------- riscv/riscv.mk.in | 2 +- 2 files changed, 1 insertion(+), 11 deletions(-) diff --git a/Makefile.in b/Makefile.in index 97543ef..787bdd6 100644 --- a/Makefile.in +++ b/Makefile.in @@ -119,16 +119,6 @@ INSTALL_LIB := $(INSTALL) -m 644 INSTALL_EXE := $(INSTALL) -m 555 STOW := @stow@ -#------------------------------------------------------------------------- -# Range helper function. $(call range,3,6) generates the string 3 4 5 -#------------------------------------------------------------------------- - -range = $(shell _i=$(1); \ - while [ $$_i -le $(2) ]; do \ - echo -n "$$_i "; \ - _i=`expr $$_i + 1`; \ - done) - #------------------------------------------------------------------------- # Include subproject makefile fragments #------------------------------------------------------------------------- diff --git a/riscv/riscv.mk.in b/riscv/riscv.mk.in index ae9e8eb..c4448ff 100644 --- a/riscv/riscv.mk.in +++ b/riscv/riscv.mk.in @@ -35,7 +35,7 @@ riscv_gen_hdrs = \ dispatch.h \ NDISPATCH = 9 -DISPATCH_SRCS = $(addsuffix .cc,$(addprefix dispatch,$(call range,0,$(NDISPATCH)))) +DISPATCH_SRCS = $(addsuffix .cc,$(addprefix dispatch,$(shell seq 0 $(NDISPATCH)))) $(DISPATCH_SRCS): %.cc: dispatch $(wildcard insns/*.h) opcodes.h $< $(subst dispatch,,$(subst .cc,,$@)) $(NDISPATCH) 1024 < $(src_dir)/riscv/opcodes.h > $@ -- 2.30.2