home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / shpwn200.zip / shapewin.200 / Makefile < prev    next >
Makefile  |  2001-12-05  |  1KB  |  80 lines

  1. #
  2. # Makefile for Shape Window Control & Sample Programs
  3. #
  4.  
  5. #
  6. # Directories to install
  7. #
  8.  
  9. prefix = @prefix@
  10. bindir = $(prefix)/bin
  11. dlldir = $(prefix)/dll
  12. libdir = $(prefix)/lib
  13. hdrdir = $(prefix)/include
  14.  
  15. #
  16. # Tools to build DLL and Import Library
  17. #
  18.  
  19. CC     = gcc
  20. CFLAGS = -O2 -Zomf -Zcrtdll -Zmt
  21.  
  22. .SUFFIXES: .obj .o
  23.  
  24. #
  25. # Build Shape Window Control
  26. #
  27.  
  28. all : library samples
  29.  
  30. library : shapewin.dll shapewin.a shapewin.lib
  31. samples : trbitmap.exe tranime.exe treyes.exe
  32.  
  33. SHDEFS = shapewin.def
  34. SHSRCS = shapewin.c
  35. SHOBJS = shapewin.obj
  36.  
  37. shapewin.obj : shapewin.c shapewin.h
  38.     $(CC) -c $(CFLAGS)  shapewin.c
  39.  
  40. shapewin.dll : $(SHOBJS) $(SHDEFS)
  41.     $(CC) -Zdll $(CFLAGS) -o $@ $(SHOBJS) shapewin.def
  42.  
  43. shapewin.lib : $(SHDEFS)
  44.     rm -f shapewin.lib
  45.     emximp -o shapewin.lib shapewin.def
  46.  
  47. shapewin.a : $(SHDEFS)
  48.     rm -f shapewin.a
  49.     emximp -o shapewin.a shapewin.def
  50.  
  51. #
  52. # Sample Programs
  53. #
  54.  
  55. samples : force
  56.     (cd samples && $(MAKE) samples && cd ..)
  57.  
  58. #
  59. # Install to the System
  60. #
  61.  
  62. install : library force
  63.     cp -i shapewin.h   $(hdrdir)
  64.     cp -i shapewin.dll $(dlldir)
  65.     cp -i shapewin.lib $(libdir)
  66.     cp -i shapewin.a   $(libdir)
  67.  
  68. #
  69. # Cleanup
  70. #
  71. clean : force
  72.     rm -f *.obj *.lib *.a *.dll core
  73.     (cd samples && $(MAKE) clean && cd ..)
  74.  
  75. #
  76. # force to do
  77. #
  78. force :
  79.  
  80.