scc

simple C compiler
git clone git://git.2f30.org/scc
Log | Files | Refs | README | LICENSE

Makefile (492B)


      1 .POSIX:
      2 
      3 LIBDIR  = ../lib/scc
      4 include ../config.mk
      5 include $(LIBDIR)/libdep.mk
      6 
      7 OBJ = main.o symbol.o ins.o parser.o expr.o myro.o
      8 HDR = ../inc/scc.h as.h
      9 MOREFLAGS = -I../inc/$(STD) $(AS_CFLAGS)
     10 
     11 all:
     12 
     13 $(OBJ): $(HDR)
     14 
     15 as: $(OBJ)
     16 	$(CC) $(SCC_LDFLAGS) $(OBJ) -lscc -o $@
     17 
     18 myro.o: ../inc/myro.h
     19 
     20 $(LIBDIR)/libscc.a: $(LIB-OBJ)
     21 	cd $(LIBDIR) && $(MAKE)
     22 
     23 dep:
     24 	./gendep.sh $(TARGETS)
     25 
     26 clean:
     27 	rm -f *.o
     28 	rm -f target/*/*.o
     29 	rm -f target/*/instbl.c
     30 	rm -f as-*
     31 
     32 distclean: clean
     33 	rm -f makefile
     34