scc

simple c99 compiler
git clone git://git.simple-cc.org/scc
Log | Files | Refs | README | LICENSE

commit 965f99f62dacaa76319aa06eed1540fe5c97f4d7
parent 7439ac7e6cb71fc5a3733d17f407e5446a631bc4
Author: Roberto E. Vargas Caballero <k0ga@shike2.com>
Date:   Wed, 16 Jan 2019 12:15:40 +0000

Move cc1 cc2 as and ld to cmd

It makes more sense to have them in the cmd directory where
all the other tools are located.

Diffstat:
Msrc/Makefile | 7+++----
Dsrc/as/Makefile | 32--------------------------------
Dsrc/cc1/Makefile | 38--------------------------------------
Dsrc/cc2/Makefile | 40----------------------------------------
Msrc/cmd/Makefile | 2+-
Asrc/cmd/as/Makefile | 32++++++++++++++++++++++++++++++++
Rsrc/as/as.h -> src/cmd/as/as.h | 0
Rsrc/as/deps.mk -> src/cmd/as/deps.mk | 0
Rsrc/as/expr.c -> src/cmd/as/expr.c | 0
Rsrc/as/ins.c -> src/cmd/as/ins.c | 0
Rsrc/as/main.c -> src/cmd/as/main.c | 0
Rsrc/as/mktbl -> src/cmd/as/mktbl | 0
Rsrc/as/mktbl.awk -> src/cmd/as/mktbl.awk | 0
Rsrc/as/parser.c -> src/cmd/as/parser.c | 0
Rsrc/as/symbol.c -> src/cmd/as/symbol.c | 0
Rsrc/as/target/amd64.mk -> src/cmd/as/target/amd64.mk | 0
Rsrc/as/target/i286.mk -> src/cmd/as/target/i286.mk | 0
Rsrc/as/target/i386.mk -> src/cmd/as/target/i386.mk | 0
Rsrc/as/target/x80/.gitignore -> src/cmd/as/target/x80/.gitignore | 0
Rsrc/as/target/x80/ins.c -> src/cmd/as/target/x80/ins.c | 0
Rsrc/as/target/x80/proc.h -> src/cmd/as/target/x80/proc.h | 0
Rsrc/as/target/x80/rules.dat -> src/cmd/as/target/x80/rules.dat | 0
Rsrc/as/target/x80/x80.dat -> src/cmd/as/target/x80/x80.dat | 0
Rsrc/as/target/x80/z80.c -> src/cmd/as/target/x80/z80.c | 0
Rsrc/as/target/x86/.gitignore -> src/cmd/as/target/x86/.gitignore | 0
Rsrc/as/target/x86/amd64.c -> src/cmd/as/target/x86/amd64.c | 0
Rsrc/as/target/x86/i286.c -> src/cmd/as/target/x86/i286.c | 0
Rsrc/as/target/x86/i386.c -> src/cmd/as/target/x86/i386.c | 0
Rsrc/as/target/x86/ins.c -> src/cmd/as/target/x86/ins.c | 0
Rsrc/as/target/x86/nasm.dat -> src/cmd/as/target/x86/nasm.dat | 0
Rsrc/as/target/x86/proc.h -> src/cmd/as/target/x86/proc.h | 0
Rsrc/as/target/x86/rules.dat -> src/cmd/as/target/x86/rules.dat | 0
Rsrc/as/target/x86/x86.dat -> src/cmd/as/target/x86/x86.dat | 0
Rsrc/as/target/z80.mk -> src/cmd/as/target/z80.mk | 0
Asrc/cmd/cc1/Makefile | 38++++++++++++++++++++++++++++++++++++++
Rsrc/cc1/TODO -> src/cmd/cc1/TODO | 0
Rsrc/cc1/builtin.c -> src/cmd/cc1/builtin.c | 0
Rsrc/cc1/cc1.h -> src/cmd/cc1/cc1.h | 0
Rsrc/cc1/code.c -> src/cmd/cc1/code.c | 0
Rsrc/cc1/cpp.c -> src/cmd/cc1/cpp.c | 0
Rsrc/cc1/decl.c -> src/cmd/cc1/decl.c | 0
Rsrc/cc1/deps.mk -> src/cmd/cc1/deps.mk | 0
Rsrc/cc1/error.c -> src/cmd/cc1/error.c | 0
Rsrc/cc1/expr.c -> src/cmd/cc1/expr.c | 0
Rsrc/cc1/fold.c -> src/cmd/cc1/fold.c | 0
Rsrc/cc1/init.c -> src/cmd/cc1/init.c | 0
Rsrc/cc1/ir.md -> src/cmd/cc1/ir.md | 0
Rsrc/cc1/lex.c -> src/cmd/cc1/lex.c | 0
Rsrc/cc1/main.c -> src/cmd/cc1/main.c | 0
Rsrc/cc1/stmt.c -> src/cmd/cc1/stmt.c | 0
Rsrc/cc1/symbol.c -> src/cmd/cc1/symbol.c | 0
Rsrc/cc1/target/amd64-sysv/arch.c -> src/cmd/cc1/target/amd64-sysv/arch.c | 0
Rsrc/cc1/target/amd64-sysv/arch.mk -> src/cmd/cc1/target/amd64-sysv/arch.mk | 0
Rsrc/cc1/target/arm64-sysv/arch.c -> src/cmd/cc1/target/arm64-sysv/arch.c | 0
Rsrc/cc1/target/arm64-sysv/arch.mk -> src/cmd/cc1/target/arm64-sysv/arch.mk | 0
Rsrc/cc1/target/i386-sysv/arch.c -> src/cmd/cc1/target/i386-sysv/arch.c | 0
Rsrc/cc1/target/i386-sysv/arch.mk -> src/cmd/cc1/target/i386-sysv/arch.mk | 0
Rsrc/cc1/target/z80-scc/arch.c -> src/cmd/cc1/target/z80-scc/arch.c | 0
Rsrc/cc1/target/z80-scc/arch.mk -> src/cmd/cc1/target/z80-scc/arch.mk | 0
Rsrc/cc1/types.c -> src/cmd/cc1/types.c | 0
Rsrc/cc2/.gitignore -> src/cmd/cc2/.gitignore | 0
Asrc/cmd/cc2/Makefile | 40++++++++++++++++++++++++++++++++++++++++
Rsrc/cc2/cc2.h -> src/cmd/cc2/cc2.h | 0
Rsrc/cc2/code.c -> src/cmd/cc2/code.c | 0
Rsrc/cc2/deps.mk -> src/cmd/cc2/deps.mk | 0
Rsrc/cc2/generror.awk -> src/cmd/cc2/generror.awk | 0
Rsrc/cc2/main.c -> src/cmd/cc2/main.c | 0
Rsrc/cc2/node.c -> src/cmd/cc2/node.c | 0
Rsrc/cc2/optm.c -> src/cmd/cc2/optm.c | 0
Rsrc/cc2/parser.c -> src/cmd/cc2/parser.c | 0
Rsrc/cc2/peep.c -> src/cmd/cc2/peep.c | 0
Rsrc/cc2/symbol.c -> src/cmd/cc2/symbol.c | 0
Rsrc/cc2/target/amd64-sysv/arch.h -> src/cmd/cc2/target/amd64-sysv/arch.h | 0
Rsrc/cc2/target/amd64-sysv/cgen.c -> src/cmd/cc2/target/amd64-sysv/cgen.c | 0
Rsrc/cc2/target/amd64-sysv/code.c -> src/cmd/cc2/target/amd64-sysv/code.c | 0
Rsrc/cc2/target/amd64-sysv/optm.c -> src/cmd/cc2/target/amd64-sysv/optm.c | 0
Rsrc/cc2/target/amd64-sysv/target.mk -> src/cmd/cc2/target/amd64-sysv/target.mk | 0
Rsrc/cc2/target/amd64-sysv/types.c -> src/cmd/cc2/target/amd64-sysv/types.c | 0
Rsrc/cc2/target/arm64-sysv/types.c -> src/cmd/cc2/target/arm64-sysv/types.c | 0
Rsrc/cc2/target/i386-sysv/arch.h -> src/cmd/cc2/target/i386-sysv/arch.h | 0
Rsrc/cc2/target/i386-sysv/cgen.c -> src/cmd/cc2/target/i386-sysv/cgen.c | 0
Rsrc/cc2/target/i386-sysv/code.c -> src/cmd/cc2/target/i386-sysv/code.c | 0
Rsrc/cc2/target/i386-sysv/optm.c -> src/cmd/cc2/target/i386-sysv/optm.c | 0
Rsrc/cc2/target/i386-sysv/target.mk -> src/cmd/cc2/target/i386-sysv/target.mk | 0
Rsrc/cc2/target/i386-sysv/types.c -> src/cmd/cc2/target/i386-sysv/types.c | 0
Rsrc/cc2/target/qbe/arch.h -> src/cmd/cc2/target/qbe/arch.h | 0
Rsrc/cc2/target/qbe/cgen.c -> src/cmd/cc2/target/qbe/cgen.c | 0
Rsrc/cc2/target/qbe/code.c -> src/cmd/cc2/target/qbe/code.c | 0
Rsrc/cc2/target/qbe/optm.c -> src/cmd/cc2/target/qbe/optm.c | 0
Rsrc/cc2/target/qbe_amd64-sysv/target.mk -> src/cmd/cc2/target/qbe_amd64-sysv/target.mk | 0
Rsrc/cc2/target/qbe_arm64-sysv/target.mk -> src/cmd/cc2/target/qbe_arm64-sysv/target.mk | 0
Rsrc/cc2/target/z80-scc/arch.h -> src/cmd/cc2/target/z80-scc/arch.h | 0
Rsrc/cc2/target/z80-scc/cgen.c -> src/cmd/cc2/target/z80-scc/cgen.c | 0
Rsrc/cc2/target/z80-scc/code.c -> src/cmd/cc2/target/z80-scc/code.c | 0
Rsrc/cc2/target/z80-scc/optm.c -> src/cmd/cc2/target/z80-scc/optm.c | 0
Rsrc/cc2/target/z80-scc/target.mk -> src/cmd/cc2/target/z80-scc/target.mk | 0
Rsrc/cc2/target/z80-scc/types.c -> src/cmd/cc2/target/z80-scc/types.c | 0
Asrc/cmd/ld/Makefile | 20++++++++++++++++++++
Rsrc/ld/deps.mk -> src/cmd/ld/deps.mk | 0
Rsrc/ld/ld.h -> src/cmd/ld/ld.h | 0
Rsrc/ld/main.c -> src/cmd/ld/main.c | 0
Rsrc/ld/obj.c -> src/cmd/ld/obj.c | 0
Dsrc/ld/Makefile | 20--------------------
103 files changed, 134 insertions(+), 135 deletions(-)

diff --git a/src/Makefile b/src/Makefile @@ -3,13 +3,12 @@ PROJECTDIR = .. include $(PROJECTDIR)/scripts/rules.mk -TOOLS = cc1 cc2 ld as cmd LIBS = libscc libc libcrt libmach -DIRS = $(TOOLS) $(LIBS) +DIRS = cmd $(LIBS) -all: $(TOOLS) +all: cmd -$(TOOLS): $(LIBS) +cmd: $(LIBS) $(DIRS): FORCE +@cd $@ && $(MAKE) diff --git a/src/as/Makefile b/src/as/Makefile @@ -1,32 +0,0 @@ -.POSIX: - -PROJECTDIR = ../.. -include $(PROJECTDIR)/scripts/rules.mk - -MORECFLAGS = -I$(INCDIR)/$(STD) - -OBJS = main.o \ - symbol.o \ - ins.o \ - parser.o \ - expr.o \ - -TARGET = $(LIBEXEC)/as-amd64 \ - $(LIBEXEC)/as-i386 \ - $(LIBEXEC)/as-i286 \ - $(LIBEXEC)/as-z80 \ - -all: $(TARGET) - -$(TARGET): $(LIBDIR)/libscc.a - -dep: inc-dep - -clean: - rm -f target/*/*.o target/*/*tbl.c - -include target/amd64.mk -include target/i386.mk -include target/i286.mk -include target/z80.mk -include deps.mk diff --git a/src/cc1/Makefile b/src/cc1/Makefile @@ -1,38 +0,0 @@ -.POSIX: - -PROJECTDIR = ../.. -include $(PROJECTDIR)/scripts/rules.mk - -OBJS = types.o \ - decl.o \ - lex.o \ - error.o \ - symbol.o \ - main.o \ - expr.o \ - code.o \ - stmt.o \ - cpp.o \ - fold.o \ - init.o \ - builtin.o \ - -TARGET = $(LIBEXEC)/cc1-amd64-sysv \ - $(LIBEXEC)/cc1-arm64-sysv \ - $(LIBEXEC)/cc1-i386-sysv \ - $(LIBEXEC)/cc1-z80-scc \ - -all: $(TARGET) - -$(TARGET): $(LIBDIR)/libscc.a - -dep: inc-dep - -clean: - rm -f target/*/*.o - -include target/amd64-sysv/arch.mk -include target/arm64-sysv/arch.mk -include target/i386-sysv/arch.mk -include target/z80-scc/arch.mk -include deps.mk diff --git a/src/cc2/Makefile b/src/cc2/Makefile @@ -1,40 +0,0 @@ -.POSIX: - -PROJECTDIR = ../.. -include $(PROJECTDIR)/scripts/rules.mk - -MORECFLAGS = -I$(INCDIR)/$(STD) - -OBJS = main.o \ - parser.o \ - peep.o \ - symbol.o \ - node.o \ - code.o \ - optm.o \ - -TARGET = $(LIBEXEC)/cc2-amd64-sysv \ - $(LIBEXEC)/cc2-i386-sysv \ - $(LIBEXEC)/cc2-qbe_amd64-sysv \ - $(LIBEXEC)/cc2-z80-scc \ - -all: $(TARGET) - -$(TARGET): error.h - -error.h: cc2.h - rm -f $@;\ - trap 'r=$?;rm -f $$$$.h;exit $r' EXIT INT QUIT ;\ - awk -f generror.awk cc2.h > $$$$.h && mv $$$$.h $@ - -dep: inc-dep - -clean: - rm -f target/*/*.o error.h - -include target/amd64-sysv/target.mk -include target/i386-sysv/target.mk -include target/qbe_amd64-sysv/target.mk -include target/qbe_arm64-sysv/target.mk -include target/z80-scc/target.mk -include deps.mk diff --git a/src/cmd/Makefile b/src/cmd/Makefile @@ -14,7 +14,7 @@ TARGET = $(BINDIR)/nm \ LIBS = -lmach -all: $(TARGET) +all: $(TARGET) as ld cc1 cc2 $(TARGET): $(LIBDIR)/libmach.a diff --git a/src/cmd/as/Makefile b/src/cmd/as/Makefile @@ -0,0 +1,32 @@ +.POSIX: + +PROJECTDIR = ../../.. +include $(PROJECTDIR)/scripts/rules.mk + +MORECFLAGS = -I$(INCDIR)/$(STD) + +OBJS = main.o \ + symbol.o \ + ins.o \ + parser.o \ + expr.o \ + +TARGET = $(LIBEXEC)/as-amd64 \ + $(LIBEXEC)/as-i386 \ + $(LIBEXEC)/as-i286 \ + $(LIBEXEC)/as-z80 \ + +all: $(TARGET) + +$(TARGET): $(LIBDIR)/libscc.a + +dep: inc-dep + +clean: + rm -f target/*/*.o target/*/*tbl.c + +include target/amd64.mk +include target/i386.mk +include target/i286.mk +include target/z80.mk +include deps.mk diff --git a/src/as/as.h b/src/cmd/as/as.h diff --git a/src/as/deps.mk b/src/cmd/as/deps.mk diff --git a/src/as/expr.c b/src/cmd/as/expr.c diff --git a/src/as/ins.c b/src/cmd/as/ins.c diff --git a/src/as/main.c b/src/cmd/as/main.c diff --git a/src/as/mktbl b/src/cmd/as/mktbl diff --git a/src/as/mktbl.awk b/src/cmd/as/mktbl.awk diff --git a/src/as/parser.c b/src/cmd/as/parser.c diff --git a/src/as/symbol.c b/src/cmd/as/symbol.c diff --git a/src/as/target/amd64.mk b/src/cmd/as/target/amd64.mk diff --git a/src/as/target/i286.mk b/src/cmd/as/target/i286.mk diff --git a/src/as/target/i386.mk b/src/cmd/as/target/i386.mk diff --git a/src/as/target/x80/.gitignore b/src/cmd/as/target/x80/.gitignore diff --git a/src/as/target/x80/ins.c b/src/cmd/as/target/x80/ins.c diff --git a/src/as/target/x80/proc.h b/src/cmd/as/target/x80/proc.h diff --git a/src/as/target/x80/rules.dat b/src/cmd/as/target/x80/rules.dat diff --git a/src/as/target/x80/x80.dat b/src/cmd/as/target/x80/x80.dat diff --git a/src/as/target/x80/z80.c b/src/cmd/as/target/x80/z80.c diff --git a/src/as/target/x86/.gitignore b/src/cmd/as/target/x86/.gitignore diff --git a/src/as/target/x86/amd64.c b/src/cmd/as/target/x86/amd64.c diff --git a/src/as/target/x86/i286.c b/src/cmd/as/target/x86/i286.c diff --git a/src/as/target/x86/i386.c b/src/cmd/as/target/x86/i386.c diff --git a/src/as/target/x86/ins.c b/src/cmd/as/target/x86/ins.c diff --git a/src/as/target/x86/nasm.dat b/src/cmd/as/target/x86/nasm.dat diff --git a/src/as/target/x86/proc.h b/src/cmd/as/target/x86/proc.h diff --git a/src/as/target/x86/rules.dat b/src/cmd/as/target/x86/rules.dat diff --git a/src/as/target/x86/x86.dat b/src/cmd/as/target/x86/x86.dat diff --git a/src/as/target/z80.mk b/src/cmd/as/target/z80.mk diff --git a/src/cmd/cc1/Makefile b/src/cmd/cc1/Makefile @@ -0,0 +1,38 @@ +.POSIX: + +PROJECTDIR = ../../.. +include $(PROJECTDIR)/scripts/rules.mk + +OBJS = types.o \ + decl.o \ + lex.o \ + error.o \ + symbol.o \ + main.o \ + expr.o \ + code.o \ + stmt.o \ + cpp.o \ + fold.o \ + init.o \ + builtin.o \ + +TARGET = $(LIBEXEC)/cc1-amd64-sysv \ + $(LIBEXEC)/cc1-arm64-sysv \ + $(LIBEXEC)/cc1-i386-sysv \ + $(LIBEXEC)/cc1-z80-scc \ + +all: $(TARGET) + +$(TARGET): $(LIBDIR)/libscc.a + +dep: inc-dep + +clean: + rm -f target/*/*.o + +include target/amd64-sysv/arch.mk +include target/arm64-sysv/arch.mk +include target/i386-sysv/arch.mk +include target/z80-scc/arch.mk +include deps.mk diff --git a/src/cc1/TODO b/src/cmd/cc1/TODO diff --git a/src/cc1/builtin.c b/src/cmd/cc1/builtin.c diff --git a/src/cc1/cc1.h b/src/cmd/cc1/cc1.h diff --git a/src/cc1/code.c b/src/cmd/cc1/code.c diff --git a/src/cc1/cpp.c b/src/cmd/cc1/cpp.c diff --git a/src/cc1/decl.c b/src/cmd/cc1/decl.c diff --git a/src/cc1/deps.mk b/src/cmd/cc1/deps.mk diff --git a/src/cc1/error.c b/src/cmd/cc1/error.c diff --git a/src/cc1/expr.c b/src/cmd/cc1/expr.c diff --git a/src/cc1/fold.c b/src/cmd/cc1/fold.c diff --git a/src/cc1/init.c b/src/cmd/cc1/init.c diff --git a/src/cc1/ir.md b/src/cmd/cc1/ir.md diff --git a/src/cc1/lex.c b/src/cmd/cc1/lex.c diff --git a/src/cc1/main.c b/src/cmd/cc1/main.c diff --git a/src/cc1/stmt.c b/src/cmd/cc1/stmt.c diff --git a/src/cc1/symbol.c b/src/cmd/cc1/symbol.c diff --git a/src/cc1/target/amd64-sysv/arch.c b/src/cmd/cc1/target/amd64-sysv/arch.c diff --git a/src/cc1/target/amd64-sysv/arch.mk b/src/cmd/cc1/target/amd64-sysv/arch.mk diff --git a/src/cc1/target/arm64-sysv/arch.c b/src/cmd/cc1/target/arm64-sysv/arch.c diff --git a/src/cc1/target/arm64-sysv/arch.mk b/src/cmd/cc1/target/arm64-sysv/arch.mk diff --git a/src/cc1/target/i386-sysv/arch.c b/src/cmd/cc1/target/i386-sysv/arch.c diff --git a/src/cc1/target/i386-sysv/arch.mk b/src/cmd/cc1/target/i386-sysv/arch.mk diff --git a/src/cc1/target/z80-scc/arch.c b/src/cmd/cc1/target/z80-scc/arch.c diff --git a/src/cc1/target/z80-scc/arch.mk b/src/cmd/cc1/target/z80-scc/arch.mk diff --git a/src/cc1/types.c b/src/cmd/cc1/types.c diff --git a/src/cc2/.gitignore b/src/cmd/cc2/.gitignore diff --git a/src/cmd/cc2/Makefile b/src/cmd/cc2/Makefile @@ -0,0 +1,40 @@ +.POSIX: + +PROJECTDIR = ../../.. +include $(PROJECTDIR)/scripts/rules.mk + +MORECFLAGS = -I$(INCDIR)/$(STD) + +OBJS = main.o \ + parser.o \ + peep.o \ + symbol.o \ + node.o \ + code.o \ + optm.o \ + +TARGET = $(LIBEXEC)/cc2-amd64-sysv \ + $(LIBEXEC)/cc2-i386-sysv \ + $(LIBEXEC)/cc2-qbe_amd64-sysv \ + $(LIBEXEC)/cc2-z80-scc \ + +all: $(TARGET) + +$(TARGET): error.h + +error.h: cc2.h + rm -f $@;\ + trap 'r=$?;rm -f $$$$.h;exit $r' EXIT INT QUIT ;\ + awk -f generror.awk cc2.h > $$$$.h && mv $$$$.h $@ + +dep: inc-dep + +clean: + rm -f target/*/*.o error.h + +include target/amd64-sysv/target.mk +include target/i386-sysv/target.mk +include target/qbe_amd64-sysv/target.mk +include target/qbe_arm64-sysv/target.mk +include target/z80-scc/target.mk +include deps.mk diff --git a/src/cc2/cc2.h b/src/cmd/cc2/cc2.h diff --git a/src/cc2/code.c b/src/cmd/cc2/code.c diff --git a/src/cc2/deps.mk b/src/cmd/cc2/deps.mk diff --git a/src/cc2/generror.awk b/src/cmd/cc2/generror.awk diff --git a/src/cc2/main.c b/src/cmd/cc2/main.c diff --git a/src/cc2/node.c b/src/cmd/cc2/node.c diff --git a/src/cc2/optm.c b/src/cmd/cc2/optm.c diff --git a/src/cc2/parser.c b/src/cmd/cc2/parser.c diff --git a/src/cc2/peep.c b/src/cmd/cc2/peep.c diff --git a/src/cc2/symbol.c b/src/cmd/cc2/symbol.c diff --git a/src/cc2/target/amd64-sysv/arch.h b/src/cmd/cc2/target/amd64-sysv/arch.h diff --git a/src/cc2/target/amd64-sysv/cgen.c b/src/cmd/cc2/target/amd64-sysv/cgen.c diff --git a/src/cc2/target/amd64-sysv/code.c b/src/cmd/cc2/target/amd64-sysv/code.c diff --git a/src/cc2/target/amd64-sysv/optm.c b/src/cmd/cc2/target/amd64-sysv/optm.c diff --git a/src/cc2/target/amd64-sysv/target.mk b/src/cmd/cc2/target/amd64-sysv/target.mk diff --git a/src/cc2/target/amd64-sysv/types.c b/src/cmd/cc2/target/amd64-sysv/types.c diff --git a/src/cc2/target/arm64-sysv/types.c b/src/cmd/cc2/target/arm64-sysv/types.c diff --git a/src/cc2/target/i386-sysv/arch.h b/src/cmd/cc2/target/i386-sysv/arch.h diff --git a/src/cc2/target/i386-sysv/cgen.c b/src/cmd/cc2/target/i386-sysv/cgen.c diff --git a/src/cc2/target/i386-sysv/code.c b/src/cmd/cc2/target/i386-sysv/code.c diff --git a/src/cc2/target/i386-sysv/optm.c b/src/cmd/cc2/target/i386-sysv/optm.c diff --git a/src/cc2/target/i386-sysv/target.mk b/src/cmd/cc2/target/i386-sysv/target.mk diff --git a/src/cc2/target/i386-sysv/types.c b/src/cmd/cc2/target/i386-sysv/types.c diff --git a/src/cc2/target/qbe/arch.h b/src/cmd/cc2/target/qbe/arch.h diff --git a/src/cc2/target/qbe/cgen.c b/src/cmd/cc2/target/qbe/cgen.c diff --git a/src/cc2/target/qbe/code.c b/src/cmd/cc2/target/qbe/code.c diff --git a/src/cc2/target/qbe/optm.c b/src/cmd/cc2/target/qbe/optm.c diff --git a/src/cc2/target/qbe_amd64-sysv/target.mk b/src/cmd/cc2/target/qbe_amd64-sysv/target.mk diff --git a/src/cc2/target/qbe_arm64-sysv/target.mk b/src/cmd/cc2/target/qbe_arm64-sysv/target.mk diff --git a/src/cc2/target/z80-scc/arch.h b/src/cmd/cc2/target/z80-scc/arch.h diff --git a/src/cc2/target/z80-scc/cgen.c b/src/cmd/cc2/target/z80-scc/cgen.c diff --git a/src/cc2/target/z80-scc/code.c b/src/cmd/cc2/target/z80-scc/code.c diff --git a/src/cc2/target/z80-scc/optm.c b/src/cmd/cc2/target/z80-scc/optm.c diff --git a/src/cc2/target/z80-scc/target.mk b/src/cmd/cc2/target/z80-scc/target.mk diff --git a/src/cc2/target/z80-scc/types.c b/src/cmd/cc2/target/z80-scc/types.c diff --git a/src/cmd/ld/Makefile b/src/cmd/ld/Makefile @@ -0,0 +1,20 @@ +.POSIX: + +PROJECTDIR = ../../.. +include $(PROJECTDIR)/scripts/rules.mk + +OBJS = main.o \ + obj.o \ + +TARGET = $(BINDIR)/ld + +all: $(TARGET) + +$(TARGET): $(LIBDIR)/libscc.a + +$(TARGET): $(OBJS) + $(CC) $(SCC_LDFLAGS) $(OBJS) -lscc -o $@ + +dep: inc-dep + +include deps.mk diff --git a/src/ld/deps.mk b/src/cmd/ld/deps.mk diff --git a/src/ld/ld.h b/src/cmd/ld/ld.h diff --git a/src/ld/main.c b/src/cmd/ld/main.c diff --git a/src/ld/obj.c b/src/cmd/ld/obj.c diff --git a/src/ld/Makefile b/src/ld/Makefile @@ -1,20 +0,0 @@ -.POSIX: - -PROJECTDIR = ../.. -include $(PROJECTDIR)/scripts/rules.mk - -OBJS = main.o \ - obj.o \ - -TARGET = $(BINDIR)/ld - -all: $(TARGET) - -$(TARGET): $(LIBDIR)/libscc.a - -$(TARGET): $(OBJS) - $(CC) $(SCC_LDFLAGS) $(OBJS) -lscc -o $@ - -dep: inc-dep - -include deps.mk