proto.make 2.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586
  1. # $Header$
  2. #PARAMS do not remove this line!
  3. SRC_DIR = $(SRC_HOME)/mach/mantra/int
  4. INTS=em2_t--- em2_---- em2_t-cp em2_t-c- em2_t--p \
  5. em4_t--- em4_---- em4_t-cp em4_t-c- em4_t--p
  6. P = $(SRC_DIR)/mloop
  7. FILES=$(SRC_DIR)/deffile $P0 $P1 $P2 $P3 $P4 $P5 $P6 $P7 $P8 $P9 $Pa $Pb $Pc
  8. CPP=$(UTIL_HOME)/lib.bin/cpp
  9. b=$(TARGET_HOME)/lib.bin/em
  10. CFLAGS=-I$(TARGET_HOME)/h -I$(TARGET_HOME)/config -O
  11. FLTRAP=
  12. all: $(INTS) em
  13. em: em.c
  14. $(CC) $(CFLAGS) -o em em.c
  15. tmp.s: $(FILES)
  16. cat $(FILES) > tmp.s
  17. em2_t---: tmp.s compile con_float.o
  18. ./compile -o em2_t--- -P $(FLTRAP) -Dopfreq=0 -Dlast=1 -Dcount=0 -Dtest=1 -Dflow=0 -Dprof=0 tmp.s con_float.o
  19. em2_----: tmp.s compile con_float.o
  20. ./compile -o em2_---- -P $(FLTRAP) -Dopfreq=0 -Dlast=0 -Dcount=0 -Dtest=0 -Dflow=0 -Dprof=0 tmp.s con_float.o
  21. em2_t-cp: tmp.s compile con_float.o
  22. ./compile -o em2_t-cp -P $(FLTRAP) -Dopfreq=0 -Dlast=1 -Dcount=1 -Dtest=1 -Dflow=0 -Dprof=1 tmp.s con_float.o
  23. em2_t-c-: tmp.s compile con_float.o
  24. ./compile -o em2_t-c- -P $(FLTRAP) -Dopfreq=0 -Dlast=1 -Dcount=1 -Dtest=1 -Dflow=0 -Dprof=0 tmp.s con_float.o
  25. em2_t--p: tmp.s compile con_float.o
  26. ./compile -o em2_t--p -P $(FLTRAP) -Dopfreq=0 -Dlast=1 -Dcount=0 -Dtest=1 -Dflow=0 -Dprof=1 tmp.s con_float.o
  27. em4_t---: tmp.s compile con_float.o
  28. ./compile -o em4_t--- -P $(FLTRAP) -Dlword -Dopfreq=0 -Dlast=1 -Dcount=0 -Dtest=1 -Dflow=0 -Dprof=0 tmp.s con_float.o
  29. em4_----: tmp.s compile con_float.o
  30. ./compile -o em4_---- -P $(FLTRAP) -Dlword -Dopfreq=0 -Dlast=0 -Dcount=0 -Dtest=0 -Dflow=0 -Dprof=0 tmp.s con_float.o
  31. em4_t-cp: tmp.s compile con_float.o
  32. ./compile -o em4_t-cp -P $(FLTRAP) -Dlword -Dopfreq=0 -Dlast=1 -Dcount=1 -Dtest=1 -Dflow=0 -Dprof=1 tmp.s con_float.o
  33. em4_t-c-:tmp.s compile con_float.o
  34. ./compile -o em4_t-c- -P $(FLTRAP) -Dlword -Dopfreq=0 -Dlast=1 -Dcount=1 -Dtest=1 -Dflow=0 -Dprof=0 tmp.s con_float.o
  35. em4_t--p: tmp.s compile con_float.o
  36. ./compile -o em4_t--p -P $(FLTRAP) -Dlword -Dopfreq=0 -Dlast=1 -Dcount=0 -Dtest=1 -Dflow=0 -Dprof=1 tmp.s con_float.o
  37. con_float.o: con_float.c
  38. case `ack_sys` in m68k2|pmds) \
  39. acc -I$(SRC_HOME)/mach -mm68k4 -c -L -O con_float.c;; \
  40. *) acc -c -I$(SRC_HOME)/mach -L -O con_float.c;; \
  41. esac
  42. compile: Makefile
  43. case `ack_sys` in sun*) MACH=`ack_sys`; AS=-Ras=$(UTIL_HOME)/lib.bin/m68k2/as;; pmds*) MACH=pmds4;; \
  44. m68_sysV_0) MACH=mantra;; \
  45. *) MACH=m68k4;; \
  46. esac ; echo $$MACH $$AS -r.c -.m -fp '$$*' > compile; chmod +x compile
  47. install: all
  48. -mkdir $b24 $b44
  49. ls em2_???? | sed 's:em2_\(.*\):cp & $b24/em_\1:' | sh
  50. ls em4_???? | sed 's:em4_\(.*\):cp & $b44/em_\1:' | sh
  51. cp em $(TARGET_HOME)/bin/em
  52. if [ $(DO_MACHINE_INDEP) = y ] ; \
  53. then mk_manpage $(SRC_DIR)/em.1 $(TARGET_HOME) ; \
  54. fi
  55. cmp: all
  56. -ls em2_???? | sed 's:em2_\(.*\):cmp & $b24/em_\1:' | sh
  57. -ls em4_???? | sed 's:em4_\(.*\):cmp & $b44/em_\1:' | sh
  58. -cmp em $(TARGET_HOME)/bin/em
  59. clean:
  60. -rm -f *.o *.old a.out em tmp.s $(INTS) compile
  61. opr:
  62. make pr | opr
  63. pr:
  64. @pr $(SRC_DIR)/proto.make $(FILES)