home *** CD-ROM | disk | FTP | other *** search
/ Programmer 7500 / MAX_PROGRAMMERS.iso / CLIPPER / MISC / EMXLIB8F.ZIP / EMX / LIB / MT / MAKEFILE < prev    next >
Encoding:
Text File  |  1992-12-30  |  2.5 KB  |  103 lines

  1. #
  2. # /emx/lib/mt/makefile
  3. #
  4. GCC=gcc -O -Wall -mprobe
  5. EMXLIBC=..\..\dll\emxlibc.dll
  6. I=/emx/include/
  7. S=$(I)sys/
  8.  
  9. ASMCMD = $(GCC) -D__MT__ -DOMF -Zomf -c -x assembler-with-cpp
  10. CCCMD = $(GCC) -D__MT__ -D_EMXLIBC -Zomf -c
  11.  
  12. .SUFFIXES: .obj .s .c
  13.  
  14. .c.obj:
  15.     $(CCCMD) $<
  16.  
  17. .s.obj:
  18.     $(ASMCMD) $<
  19.  
  20. default: $(EMXLIBC) ..\libmt.a ..\libmt.lib
  21.  
  22. clean:
  23.     -del *.obj $(DELOPT)
  24.     -del emxlibc.res $(DELOPT)
  25.     -del io1.c $(DELOPT)
  26.     -del io2.s $(DELOPT)
  27.     -del math1.c $(DELOPT)
  28.     -del math2.s $(DELOPT)
  29.     -del malloc1.c $(DELOPT)
  30.     -del str1.c $(DELOPT)
  31.     -del str2.s $(DELOPT)
  32.     -del time1.c $(DELOPT)
  33.     -del hw1.c $(DELOPT)
  34.     -del gcc1.c $(DELOPT)
  35.     -del gcc2.s $(DELOPT)
  36.     -del ctype1.c $(DELOPT)
  37.     -del misc1.c $(DELOPT)
  38.     -del misc2.s $(DELOPT)
  39.     -del process1.c $(DELOPT)
  40.     -del nls1.c $(DELOPT)
  41.     -del emx2.s $(DELOPT)
  42.  
  43. MTOBJS1 = ..\dll0.obj beginthr.obj thread.obj errnofun.obj iodummy.obj
  44. MTOBJS2 = startup2.obj revision.obj
  45. MTOBJS3 = io1.obj io2.obj math1.obj math2.obj malloc1.obj str1.obj str2.obj
  46. MTOBJS4 = hw1.obj gcc1.obj gcc2.obj ctype1.obj time1.obj
  47. MTOBJS5 = misc1.obj misc2.obj process1.obj nls1.obj emx2.obj
  48.  
  49. INCLUDES = $(I)stdio.h $(I)stdlib.h $(S)emx.h
  50.  
  51. emxlibc.res: makefile
  52.     echo $(MTOBJS1)+  >emxlibc.res
  53.     echo $(MTOBJS2)+ >>emxlibc.res
  54.     echo $(MTOBJS3)+ >>emxlibc.res
  55.     echo $(MTOBJS4)+ >>emxlibc.res
  56.     echo $(MTOBJS5)  >>emxlibc.res
  57.  
  58. beginthr.obj: beginthr.c
  59. errnofun.obj: errnofun.s
  60. iodummy.obj: iodummy.s
  61. revision.obj: revision.c
  62. startup2.obj: startup2.c
  63. thread.obj: thread.s
  64.  
  65. ctype1.obj: ctype1.c $(INCLUDES)
  66. gcc1.obj: gcc1.c $(INCLUDES)
  67. gcc2.obj: gcc2.s
  68. hw1.obj: hw1.c $(INCLUDES)
  69. io2.obj: io2.s
  70. malloc1.obj: malloc1.c $(INCLUDES)
  71. math1.obj: math1.c $(INCLUDES)
  72. misc1.obj: misc1.c $(INCLUDES)
  73. misc2.obj: misc2.s
  74. nls1.obj: nls1.c $(INCLUDES)
  75. process1.obj: process1.c $(INCLUDES)
  76. str1.obj: str1.c $(INCLUDES)
  77. str2.obj: str2.s
  78. time1.obj: time1.c $(INCLUDES)
  79.  
  80. emx2.obj: emx2.s ../emx/syscalls.h
  81.     $(ASMCMD) -I../emx emx2.s
  82.  
  83. math2.obj: math2.s ../math/libm.h
  84.     $(ASMCMD) -I../math math2.s
  85.  
  86. io1.obj: io1.c $(INCLUDES) ../io/ea.h
  87.     $(CCCMD) -I ../io io1.c
  88.  
  89. $(EMXLIBC): $(MTOBJS1) $(MTOBJS2) $(MTOBJS3) $(MTOBJS4) $(MTOBJS5) \
  90.     emxlibc.def emxlibc.res
  91.     link386 /noi /noe /nod @emxlibc.res, emxlibc.dll, \
  92.         nul, ..\libemx1 ..\libemx2 ..\libos2, emxlibc;
  93.     copy emxlibc.dll $(EMXLIBC)
  94.     del emxlibc.dll
  95.  
  96. ..\libmt.a: ..\libmt.lib
  97.     emximp -o $@ ..\libmt.lib
  98.  
  99. ..\libmt.lib: emxlibc.def
  100.     emximp -o emxlibc.imp emxlibc.def
  101.     emximp -o $@ emxlibc.imp
  102.     -del emxlibc.imp
  103.