home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / krcls012.zip / KrClass / demo / demo.mak < prev    next >
Makefile  |  1997-02-24  |  2KB  |  62 lines

  1. # demo.mak
  2. # (c) 1997 Wolfgang Kronberg
  3. #
  4. # This will build the demo programs for Kroni's Classes
  5. #
  6. # possible options:
  7. #
  8. #  debug: stores debugging information in the code
  9. #  static: do not use VAC++ DLLs for the code
  10. #
  11.  
  12. programs = demo.exe hello.exe ini.exe dialog.exe dialog2.exe dialog3.exe
  13.  
  14. krlibrary = ..\lib\$(library).lib
  15. krinclude = ..\include
  16.  
  17. library=$(lib1part)$(lib2part)
  18.  
  19. !IFDEF debug
  20. c1flags = /Ti+ /Gh
  21. # debug = on, profileinfo = on
  22. lib2part = d
  23. !ELSE
  24. c1flags = /Ti- /O /Oc
  25. # debug = off, optimize = on, optimize for size also = on
  26. lib2part =
  27. !ENDIF
  28.  
  29. !IFDEF static
  30. c2flags = /Gd-
  31. # link statically
  32. lib1part = skrclas
  33. !ELSE
  34. c2flags = /Gd+
  35. # link with VAC++ DLLs
  36. lib1part = krclas
  37. !ENDIF
  38.  
  39. cflags=/I$(krinclude) $(c1flags) $(c2flags) /Q /Gm /G5 /C /W2
  40. # quiet, multithread, optimize for Pentium, compile only, warning level = 2
  41.  
  42. linkflags=/Q /B" /exepack:2 /pmtype:pm /packd /nologo"
  43. # quiet, pass options to linker: high compression, PM program, pack data, quiet
  44.  
  45. .obj.exe:
  46.   icc.exe $(linkflags) $< $(krlibrary)
  47. # inference rule for .obj -> .exe: just link the input file with the library
  48.  
  49. .cpp.obj:
  50.   $(CC) $(cflags) $<
  51. # inference rule for .cpp -> .obj: just compile the input file
  52.  
  53. all: $(programs)
  54. # 'nmake all' makes all programs
  55.  
  56. $(programs) : $$(@R).obj $(krlibrary)
  57. # each .exe file depends on its .obj file and the library
  58.  
  59. $(programs:.exe=.obj) : $$(@R).cpp $(krinclude)\*.hpp
  60. # each .obj file depends on its .cpp file and the library's header files
  61.  
  62.