You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

156 lines
4.6KB

  1. # MinGW specific Makefile for libsamplerate.
  2. PROGRAMS = sndfile-resample.exe
  3. TARGETS = libsamplerate.dll $(PROGRAMS) varispeed-play.exe samplerate.pc
  4. AR = ar
  5. CC = gcc
  6. CFLAGS = -fPIC -g -O3 -march=nocona -std=gnu99 -W -Wstrict-prototypes -Wmissing-prototypes -Wall -Waggregate-return -Wcast-align -Wcast-qual -Wnested-externs -Wshadow -Wpointer-arith -pipe -Isrc
  7. COMPILER_IS_GCC =
  8. CPP = gcc -E
  9. CPPFLAGS =
  10. CXX = g++
  11. DLLTOOL = dlltool
  12. DLLWRAP = dllwrap
  13. FFTW3_CFLAGS =
  14. FFTW3_LIBS =
  15. INSTALL = /usr/bin/install -c
  16. INSTALL_DATA = ${INSTALL} -m 644
  17. install_sh = ${SHELL} /f/git/Rack/plugins/Fundamental/dep/libsamplerate-0.1.9/Cfg/install-sh
  18. LDFLAGS =
  19. LN_S = cp -pR
  20. PEXPORTS =
  21. PACKAGE = libsamplerate
  22. PACKAGE_BUGREPORT = erikd@mega-nerd.com
  23. PACKAGE_NAME = libsamplerate
  24. PACKAGE_STRING = libsamplerate 0.1.9
  25. PACKAGE_TARNAME = libsamplerate
  26. PACKAGE_VERSION = 0.1.9
  27. RANLIB = ranlib
  28. SNDFILE_CFLAGS = -std=c99
  29. SNDFILE_LIBS =
  30. STRIP = strip
  31. #====================================================================
  32. # Target directories.
  33. bindir = ${exec_prefix}/bin
  34. exec_prefix = ${prefix}
  35. htmldocdir = /f/git/Rack/plugins/Fundamental/dep/share/doc/libsamplerate0-dev/html
  36. includedir = ${prefix}/include
  37. libdir = ${exec_prefix}/lib
  38. pkgconfigdir = ${exec_prefix}/lib/pkgconfig
  39. prefix = /f/git/Rack/plugins/Fundamental/dep
  40. #====================================================================
  41. # Targets
  42. all : $(TARGETS)
  43. clean :
  44. rm -f $(TARGETS) *.del *.lib src/*.o tests/*.o tests/*.exe
  45. install : $(TARGETS)
  46. $(install_sh) -c libsamplerate.dll $(libdir)
  47. $(install_sh) -c samplerate.pc $(pkgconfigdir)
  48. @for prog in $(PROGRAMS); do \
  49. echo "installing ... $$prog" ; \
  50. $(install_sh) -c "$$prog" $(bindir) ; \
  51. done;
  52. $(install_sh) -c src/samplerate.h $(includedir)
  53. uninstall :
  54. rm -f $(libdir)/libsamplerate.dll
  55. rm -f $(pkgconfigdir)/samplerate.pc
  56. @for prog in $(PROGRAMS); do \
  57. echo "removing ... $(bindir)/$$prog" ; \
  58. rm -f $(bindir)/"$$prog" ; \
  59. done;
  60. rm -f $(includedir)/samplerate.h
  61. #====================================================================
  62. LINK_OBJS = \
  63. src/src_linear.o \
  64. src/src_sinc.o \
  65. src/src_zoh.o \
  66. src/samplerate.o
  67. libsamplerate.dll libsamplerate.lib : $(LINK_OBJS)
  68. $(DLLWRAP) --def Win32/libsamplerate.def $(LINK_OBJS) --output-lib libsamplerate.lib -o libsamplerate.dll
  69. $(STRIP) libsamplerate.dll
  70. sndfile-resample.exe : examples/sndfile-resample.c libsamplerate.lib
  71. $(CC) $(CFLAGS) $(SNDFILE_CFLAGS) $+ $(SNDFILE_LIBS) -o $@
  72. varispeed-play.exe : examples/varispeed-play.c examples/audio_out.o libsamplerate.lib
  73. $(CC) $(CFLAGS) $(SNDFILE_CFLAGS) $+ $(SNDFILE_LIBS) -lwinmm -o $@
  74. examples/audio_out.o : examples/audio_out.c
  75. $(CC) $(CFLAGS) $(SNDFILE_CFLAGS) -c $+ -o $@
  76. samplerate.pc : samplerate.pc.in config.status
  77. @./config.status $@
  78. config.status :
  79. ./configure
  80. #====================================================================
  81. # Testing programs.
  82. TEST_PROGS = \
  83. tests/misc_test.exe \
  84. tests/termination_test.exe \
  85. tests/simple_test.exe \
  86. tests/callback_test.exe \
  87. tests/reset_test.exe \
  88. tests/multi_channel_test.exe \
  89. tests/float_short_test.exe \
  90. tests/snr_bw_test.exe
  91. check : $(TEST_PROGS)
  92. tests/misc_test.exe
  93. tests/termination_test.exe
  94. tests/simple_test.exe
  95. tests/callback_test.exe
  96. tests/reset_test.exe
  97. tests/multi_channel_test.exe
  98. tests/float_short_test.exe
  99. tests/snr_bw_test.exe
  100. @echo ----------------------------------------------------------------------
  101. @echo libsamplerate passed all tests
  102. @echo ----------------------------------------------------------------------
  103. #====================================================================
  104. # Test programs.
  105. tests/misc_test.exe : tests/misc_test.c tests/util.c libsamplerate.lib
  106. $(CC) $(CFLAGS) $+ -o $@
  107. tests/termination_test.exe : tests/termination_test.c tests/util.c libsamplerate.lib
  108. $(CC) $(CFLAGS) $+ -o $@
  109. tests/simple_test.exe : tests/simple_test.c tests/util.c libsamplerate.lib
  110. $(CC) $(CFLAGS) $+ -o $@
  111. tests/callback_test.exe : tests/callback_test.c tests/util.c libsamplerate.lib
  112. $(CC) $(CFLAGS) $+ -o $@
  113. tests/reset_test.exe : tests/reset_test.c tests/util.c libsamplerate.lib
  114. $(CC) $(CFLAGS) $+ -o $@
  115. tests/float_short_test.exe : tests/float_short_test.c tests/util.c libsamplerate.lib
  116. $(CC) $(CFLAGS) $+ -o $@
  117. tests/multi_channel_test.exe : tests/multi_channel_test.c tests/util.c tests/calc_snr.c libsamplerate.lib
  118. $(CC) $(CFLAGS) $(FFTW3_CFLAGS) $+ $(FFTW3_LIBS) -o $@
  119. tests/snr_bw_test.exe : tests/snr_bw_test.c tests/util.c tests/calc_snr.c libsamplerate.lib
  120. $(CC) $(CFLAGS) $(FFTW3_CFLAGS) $+ $(FFTW3_LIBS) -o $@
  121. # End of Makefile
  122. #====================================================================