home *** CD-ROM | disk | FTP | other *** search
/ Dream 57 / Amiga_Dream_57.iso / Amiga / Programmation / c / QuakeC / qtools0.2-src.lha / src / Makefile-rules.in next >
Encoding:
Makefile  |  1998-07-13  |  2.1 KB  |  70 lines

  1. # MakeFile for QuakeTools
  2.  
  3. CC=@CC@
  4. LD=@LD@
  5. AS=@AS@
  6. AR=@AR@
  7. RAN=@RANLIB@
  8.  
  9. WARN = -Wall -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations
  10. OPTI = -fpeephole -fno-float-store -ffunction-cse -ffast-math -fstrength-reduce \
  11.        -frerun-cse-after-loop -frerun-loop-opt -fschedule-insns -fschedule-insns2 \
  12.        -fmove-all-movables -freg-struct-return -freduce-all-givs -fforce-addr
  13. DEFS = @DEFS@ -DPARENTDIR="../" -DCURRENTDIR="./"
  14. INCL = -I. -L. -I@top_srcdir@/src/include -I@top_srcdir@/lib -I@includedir@
  15.  
  16. # highly optimized flags
  17. CFLAGS =@CFLAGS@ -O3 $(WARN) $(OPTI) $(DEFS) $(INCL) $(EXTRAOPTS) -fomit-frame-pointer
  18. LDFLAGS=@LDFLAGS@ -O3 $(WARN) $(OPTI) $(DEFS) $(INCL) $(EXTRAOPTS) -fomit-frame-pointer -s
  19. ASFLAGS=
  20.  
  21. #profileflags
  22. CPFLAGS =@CFLAGS@ $(WARN) $(DEFS) $(INCL) -DNOASM -DDEBUG_C        # -pg -DPROFILE 
  23. LDPFLAGS=@LDFLAGS@ $(WARN) $(DEFS) $(INCL) -DNOASM -DDEBUG_C        # -pg -DPROFILE
  24. ASPFLAGS=
  25. #gcovflags
  26. CVFLAGS =$(CFLAGS) -DPROFILE -ftest-coverage -fprofile-arcs
  27. LDVFLAGS=$(LDFLAGS) -DPROFILE -ftest-coverage -fprofile-arcs
  28. ASVFLAGS=$(ASFLAGS)
  29. CBFLAGS =$(CFLAGS) -DPROFILE -fbranch-probabilities
  30. LDBFLAGS=$(LDFLAGS) -DPROFILE -fbranch-probabilities
  31. ASBFLAGS=$(ASFLAGS)
  32.  
  33. # common rules
  34. .PHONY:  default profile coverage branch all utils install ansi test \
  35.     clean cleanprofile cleancoverage cleanall distclean backup restore
  36.  
  37. .SUFFIXES:
  38. .SUFFIXES: .c .o .4 .6 _p.o .b .v .S
  39.  
  40. # try assembler first
  41. %.o %.4 %.6: %.S
  42.     $(CC) $(ASFLAGS) -c $< -o $@
  43. # if no assembler try direct from C
  44. %_p.o: %.S
  45.     $(CC) $(ASPFLAGS) -c $< -o $@
  46. # if no assembler try direct from C
  47. %.v: %.S
  48.     $(CC) $(ASVFLAGS) -c $< -o $@
  49. # if no assembler try direct from C
  50. %.b: %.S
  51.     $(CC) $(ASBFLAGS) -c $< -o $@
  52. # if no assembler try direct from C
  53. %.o %.4 %.6: %.c
  54.     $(CC) $(CFLAGS) -c $< -o $@
  55. # if no assembler try direct from C
  56. %_p.o: %.c
  57.     $(CC) $(CPFLAGS) -c $< -o $@
  58. # if no assembler try direct from C
  59. %.v: %.c
  60.     $(CC) $(CVFLAGS) -c $< -o $@
  61. # if no assembler try direct from C
  62. %.b: %.c
  63.     $(CC) $(CBFLAGS) -c $< -o $@
  64. # if no assembler try direct from C
  65. %_p.oroto: %.c
  66.     @GPROTO@ -f"extern %R %N%P;\n" -sN -o$@ $<
  67. # this is only for manual use
  68. %.S: %.c
  69.     $(CC) $(CFLAGS) -fverbose-asm -S $< -o $@
  70.