メモリ内容を表示するとき、半角カナは表示しないよう仕様変更
[YACASL2.git] / src / Makefile
index ab66853..1da58bf 100644 (file)
@@ -4,6 +4,7 @@ RMF ?= rm -f
 WHICH ?= which
 CTAGS ?= ctags
 ETAGS ?= etags
+SED ?= sed
 
 INCLUDE := ../include
 
@@ -12,9 +13,12 @@ CASL2SRC := struct.c hash.c
 ASSRC := assemble.c token.c label.c
 EXECSRC := exec.c dump.c
 
-.PHONY: all clean
+.PHONY: all version clean
 
-all: ../casl2 ../comet2 ../dumpword ctags etags
+all: version ../casl2 ../comet2 ../dumpword ctags etags
+
+version:
+       $(MAKE) -C .. version
 
 ../casl2: casl2.o $(subst .c,.o,$(COMMONSRC) $(CASL2SRC) $(ASSRC) $(EXECSRC))
        $(CC) $(CFLAGS) -o $@ $^
@@ -32,15 +36,15 @@ all: ../casl2 ../comet2 ../dumpword ctags etags
        $(CC) -c $(CFLAGS) $<
 
 %.d: %.c
-       @$(CC) -MM -I $(INCLUDE) $< | sed 's/\($*\.o\):/\1 $@:/g' >$@
+       @$(CC) -MM -I $(INCLUDE) $< | $(SED) 's/\($*\.o\):/\1 $@:/g' >$@
 
 -include $(subst .c,.d,casl2.c comet2.c dumpword.c $(COMMONSRC) $(CASL2SRC) $(ASSRC) $(EXECSRC))
 
 ctags: $(INCLUDE)/*.h *.c
-       @($(WHICH) $(CTAGS) && $(CTAGS) $^) >/dev/null
+       @$(WHICH) $(CTAGS) >/dev/null && $(CTAGS) $^
 
 etags: $(INCLUDE)/*.h *.c
-       @($(WHICH) $(ETAGS) && $(ETAGS) $^) >/dev/null
+       @$(WHICH) $(ETAGS) >/dev/null && $(ETAGS) $^
 
 clean: clean_cmd clean_build clean_tags