home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 October / usenetsourcesnewsgroupsinfomagicoctober1994disk2.iso / misc / volume28 / backprop / part03 / makefile < prev    next >
Makefile  |  1992-02-23  |  2KB  |  61 lines

  1. #
  2. # This makefile can be used to make all 4 programs but note that
  3. # it is designed to make compiling the integer version bp easy
  4. # by keeping its object files around.  The other 3 programs erase
  5. # their object files.
  6. #
  7. # Below, where I say 32-bit floating point or 64-bit floating point,
  8. # note that the program uses some floating point instructions even the
  9. # integer versions, bp and sbp.  In standard UNIX C all floating point
  10. # arithmetic is done as double so using double values actually is faster
  11. # than using float values (because all the covnersions take time).
  12. # To use float rather than double define FLOAT like so:  -DFLOAT
  13. #
  14. # To get the compiler to use 32-bit DOS settings include: -DDOS32
  15. # To get the compiler to use 16-bit DOS settings include: -DDOS16
  16. #
  17. # Below are the settings I've been using for Zortech 3.0.
  18. # The -f flag in the ZORTECH CFLAGS forces hardware floating point
  19. # instructions to be generated.  The -o is for optimize, -m is used
  20. # to give the memory model.  NOTE that in the following makefile I don't
  21. # use the Zortech optimization flag -o in the CFLAGS, instead it is used
  22. # in the definitions for bp.obj, misc.obj and int.obj because for
  23. # some reason the compiler bombs when it optimizes io.obj.  As its
  24. # set up, sbp, srbp and rbp will not be optimized.
  25. #
  26. # use the following line for DOS/ZORTECH (486)
  27. #CFLAGS= -mx -4 -f -DFLOAT -DDOS32
  28. # use the following line for DOS/ZORTECH (386)
  29. #CFLAGS= -mx -3 -DFLOAT -DDOS32
  30. # use the following line for DOS/ZORTECH (286)
  31. #CFLAGS= -mz -2 -f -DFLOAT -DDOS16
  32. # use the following line for DOS/ZORTECH (8088) large memory model
  33. CFLAGS= -ml -f -DFLOAT -DDOS16
  34.  
  35. bp: bp.obj io.obj misc.obj int.obj makefile ibp.h
  36.     ztc $(CFLAGS) bp.obj io.obj misc.obj int.obj -obp.exe
  37.  
  38. sbp:
  39.     ztc -DINTEGER -DSYMMETRIC int.c bp.c io.c misc.c $(CFLAGS) -osbp.exe
  40.     erase *.obj
  41.  
  42. rbp:
  43.     ztc real.c bp.c io.c misc.c $(CFLAGS) -orbp.exe
  44.     erase *.obj
  45.  
  46. srbp:
  47.     ztc -DSYMMETRIC real.c bp.c io.c misc.c $(CFLAGS) -osrbp.exe
  48.     erase *.obj
  49.  
  50. bp.obj: bp.c ibp.h makefile
  51.     ztc -DINTEGER $(CFLAGS) bp.c -c -o
  52.  
  53. io.obj: io.c ibp.h makefile
  54.     ztc -DINTEGER $(CFLAGS) io.c -c
  55.  
  56. misc.obj: misc.c ibp.h makefile
  57.     ztc -DINTEGER $(CFLAGS) misc.c -c -o
  58.  
  59. int.obj: int.c ibp.h makefile
  60.     ztc -DINTEGER -DSMART $(CFLAGS) int.c -c -o
  61.