Makefile 2.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091
  1. # $Id: Makefile,v 1.1.2.1 2000/10/31 08:25:17 xiphmont Exp $
  2. ###############################################################################
  3. # #
  4. # These are vq codebook generation tools for use by team members. This #
  5. # makefile assumes gcc. #
  6. # #
  7. # One need not build these utils to make libvorbis #
  8. # #
  9. ###############################################################################
  10. FLAGS=-I. -I../include
  11. OPT=-O20 $(FLAGS)
  12. DEBUG=-g -Wall $(FLAGS)
  13. PROFILE=-g -pg -O20 $(FLAGS)
  14. CC=gcc
  15. LD=gcc
  16. LDFLAGS=$(FLAGS)
  17. LIBS=-lm
  18. HFILES = ../include/vorbis/codebook.h vqgen.h vqext.h bookutil.h
  19. OFILES = vqgen.o vqsplit.o bookutil.o ../lib/sharedbook.o
  20. ALLOFILES = $(OFILES) lspdata.o genericdata.o train.o build.o run.o\
  21. cascade.o partition.o metrics.o residuedata.o latticebuild.o\
  22. latticepare.o latticehint.o latticetune.o
  23. all:
  24. $(MAKE) target CFLAGS="$(OPT)"
  25. debug:
  26. $(MAKE) target CFLAGS="$(DEBUG)"
  27. profile:
  28. $(MAKE) target CFLAGS="$(PROFILE)"
  29. target: lspvqtrain genericvqtrain residuevqtrain vqbuild vqcascade vqmetrics latticebuild latticepare latticehint latticetune huffbuild residuesplit
  30. lspvqtrain: $(OFILES) lspdata.o train.o
  31. $(CC) $(CFLAGS) $(LDFLAGS) $^ -o $@ $(LIBS)
  32. residuevqtrain: $(OFILES) residuedata.o train.o
  33. $(CC) $(CFLAGS) $(LDFLAGS) $^ -o $@ $(LIBS)
  34. genericvqtrain: $(OFILES) genericdata.o train.o
  35. $(CC) $(CFLAGS) $(LDFLAGS) $^ -o $@ $(LIBS)
  36. vqbuild: $(OFILES) build.o
  37. $(CC) $(CFLAGS) $(LDFLAGS) $^ -o $@ $(LIBS)
  38. vqcascade: $(OFILES) run.o cascade.o
  39. $(CC) $(CFLAGS) $(LDFLAGS) $^ -o $@ $(LIBS)
  40. vqmetrics: $(OFILES) run.o metrics.o
  41. $(CC) $(CFLAGS) $(LDFLAGS) $^ -o $@ $(LIBS)
  42. latticebuild: $(OFILES) latticebuild.o
  43. $(CC) $(CFLAGS) $(LDFLAGS) $^ -o $@ $(LIBS)
  44. latticehint: $(OFILES) latticehint.o
  45. $(CC) $(CFLAGS) $(LDFLAGS) $^ -o $@ $(LIBS)
  46. latticepare: $(OFILES) latticepare.o
  47. $(CC) $(CFLAGS) $(LDFLAGS) $^ -o $@ $(LIBS)
  48. latticetune: $(OFILES) latticetune.o
  49. $(CC) $(CFLAGS) $(LDFLAGS) $^ -o $@ $(LIBS)
  50. huffbuild: $(OFILES) huffbuild.o
  51. $(CC) $(CFLAGS) $(LDFLAGS) $^ -o $@ $(LIBS)
  52. residuesplit: $(OFILES) residuesplit.o
  53. $(CC) $(CFLAGS) $(LDFLAGS) $^ -o $@ $(LIBS)
  54. $(ALLOFILES): $(HFILES)
  55. .c.o:
  56. $(CC) $(CFLAGS) -c $<
  57. $(OFILES): $(HFILES)
  58. clean:
  59. -rm -f *.o *.a test* *~ *.out *.m config.* \
  60. lspvqtrain genericvqtrain residuevqtrain\
  61. vqbuild vqmetrics latticebuild vqcascade latticepare\
  62. huffbuild residuesplit
  63. distclean: clean
  64. -rm -f Makefile