makefile.solaris
上传用户:aoeyumen
上传日期:2007-01-06
资源大小:3329k
文件大小:2k
源码类别:

DVD

开发平台:

Unix_Linux

  1. #
  2. # By:Alex Theo de Jong
  3. # Description:
  4. # Makefile for MPEG 2 Audio player for SUN Solaris
  5. #
  6. # Operating System
  7. OS        = -DSOLARIS # -DSOLARIS_PTHREAD
  8. # Use Solaris Multi-Threading
  9. THREADLIB = -lthread # -L/opt/pthread/lib/libpthread.a 
  10. THREADINC = # -I/opt/pthread/include  # none
  11. # Directories
  12. PIDRDIR      = .
  13. INSTLIB      = ../../../Lib
  14. INSTINC      = ../../../Inc
  15. INSTBIN      = ../../../Bin/Solaris2.5
  16. # Tools
  17. CP           = cp
  18. RM           = rm -f
  19. CHMOD        = chmod 666
  20. AR           = ar
  21. CPP          = CC # Sparc C++ Compiler # g++ -V2.7.2 # -V2.6.3
  22. STRP         = strip
  23. # Compiler options
  24. DEBUG        = -g # -DDEBUG # -DTRACE # -ggdb  # -DTRACE
  25. WARNINGS     = -w # -Wall  
  26. OPTIMIZE     = -O # -O2 # -O6 #
  27. CPPFLAGS     = $(DEBUG) $(WARNINGS) $(OS) $(OPTIMIZE) 
  28.                -I$(PIDRDIR) -I$(INSTINC) $(THREADINC) 
  29. # Linker flags
  30. LDFLAGS      = -L$(INSTLIB)
  31. LDLIBS       = -lmpeg -lutil $(THREADLIB)
  32. # Things to compile
  33. PROGRAM      = mpeg2audio
  34. OBJECTS      = mpeg2audio.o astream.o header.o scalefactors.o subband_layer_1.o 
  35.                subband_layer_2.o synthesis_filter.o obuffer.o crc.o
  36. LIBRARY      = libmpeg.a
  37. # compile lines
  38. all: $(PROGRAM)
  39. install: $(PROGRAM) bin
  40. clean:
  41. $(RM) *.o *~ *.~?~ core $(PROGRAM)
  42. installclean: clean
  43. %.a: $(OBJECTS)
  44. $(AR) vrus $(INSTLIB)/$*.a $(OBJECTS)
  45. $(CP) *.hh $(INSTINC)
  46. $(CHMOD) $(INSTINC)/*.hh
  47. mpeg2audio: $(LIBRARY) main.o
  48. $(RM) $(PROGRAM)
  49. $(CPP) -o $(PROGRAM) main.o $(LDFLAGS) $(LDLIBS)
  50. bin: $(PROGRAM)
  51. $(CP) $(PROGRAM) $(INSTBIN)
  52. $(STRP) $(INSTBIN)/$(PROGRAM)
  53. .cc.o:
  54. $(RM) $@
  55. $(CPP) $(CPPFLAGS) -c $<
  56. # Dependencies
  57. crc.o: crc.hh
  58. header.o: astream.hh  header.hh crc.hh
  59. obuffer.o: obuffer.hh  header.hh crc.hh 
  60. scalefactors.o: scalefactors.hh 
  61. subband_layer_1.o: subband_layer_1.hh astream.hh 
  62. subband_layer_1.o: subband.hh header.hh crc.hh synthesis_filter.hh obuffer.hh
  63. subband_layer_1.o: scalefactors.hh
  64. subband_layer_2.o: subband_layer_2.hh astream.hh  subband.hh header.hh crc.hh
  65. subband_layer_2.o: synthesis_filter.hh  obuffer.hh scalefactors.hh
  66. synthesis_filter.o: synthesis_filter.hh obuffer.hh header.hh crc.hh
  67. astream.o: astream.hh
  68. mpeg2audio.o: mpeg2audio.hh