scc

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

Makefile (600B)


      1 .POSIX:
      2 
      3 PROJECTDIR = ../../../../..
      4 
      5 include $(PROJECTDIR)/scripts/rules.mk
      6 include ../../../rules.mk
      7 
      8 GENOBJS =\
      9 	_access.$O\
     10 	__sigaction.$O\
     11 	_close.$O\
     12 	_execve.$O\
     13 	_exit.$O\
     14 	_fork.$O\
     15 	_getpid.$O\
     16 	_getrusage.$O\
     17 	_gettimeofday.$O\
     18 	_kill.$O\
     19 	_lseek.$O\
     20 	_open.$O\
     21 	_read.$O\
     22 	_rename.$O\
     23 	_sigreturn.$O\
     24 	_sys_brk.$O\
     25 	_unlink.$O\
     26 	_write.$O\
     27 	_wait4.$O\
     28 
     29 OBJS =\
     30 	$(GENOBJS)\
     31 	_cerrno.$O\
     32 	_sys_errlist.$O\
     33 
     34 all: $(OBJS) $(CRT)
     35 
     36 $(CRT): ../crt-posix.s
     37 
     38 $(GENOBJS): syscall.lst
     39 	./gensys.sh $(@:.$O=)
     40 	$(AS) $(PROJ_ASFLAGS) -o $@ $(@:.$O=.s)
     41 
     42 clean:
     43 	rm -f $(GENOBJS:.$O=.s) _sys_errlist.c