1# -------------------------------------------------------------------------------- 2# 3# Copyright (C) 2005-2021 Fons Adriaensen <fons@linuxaudio.org> 4# 5# This program is free software; you can redistribute it and/or modify 6# it under the terms of the GNU General Public License as published by 7# the Free Software Foundation; either version 2 of the License, or 8# (at your option) any later version. 9# 10# This program is distributed in the hope that it will be useful, 11# but WITHOUT ANY WARRANTY; without even the implied warranty of 12# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13# GNU General Public License for more details. 14# 15# You should have received a copy of the GNU General Public License 16# along with this program; if not, write to the Free Software 17# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 18# 19# -------------------------------------------------------------------------------- 20 21 22PREFIX ?= /usr/local 23BINDIR ?= $(PREFIX)/bin 24 25VERSION = 1.1.0 26CPPFLAGS += -MMD -MP -DVERSION=\"$(VERSION)\" 27CXXFLAGS += -O2 -Wall 28CXXFLAGS += ${FREEBSD_CXXFLAGS_SIMD} 29 30 31all: jconvolver fconvolver makemulti 32 33 34JCONVOLVER_O = jconvolver.o config.o jconfig.o audiofile.o dither.o sstring.o jclient.o 35jconvolver: LDLIBS += -lzita-convolver -lfftw3f -lsndfile -lclthreads -ljack -lpthread -lrt 36jconvolver: $(JCONVOLVER_O) 37 $(CXX) $(LDFLAGS) -o $@ $(JCONVOLVER_O) $(LDLIBS) 38$(JCONVOLVER_O): 39-include $(JCONVOLVER_O:%.o=%.d) 40 41 42 43FCONVOLVER_O = fconvolver.o config.o fconfig.o audiofile.o dither.o sstring.o 44fconvolver: LDLIBS += -lzita-convolver -lfftw3f -lsndfile -lpthread -lrt 45fconvolver: $(FCONVOLVER_O) 46 $(CXX) $(LDFLAGS) -o $@ $(FCONVOLVER_O) $(LDLIBS) 47$(FCONVOLVER_O): 48-include $(FCONVOLVER_O:%.o=%.d) 49 50 51 52MAKEMULTI_O = makemulti.o audiofile.o dither.o 53makemulti : LDLIBS += -lsndfile -lrt 54makemulti: $(MAKEMULTI_O) 55 $(CXX) $(LDFLAGS) -o $@ $(MAKEMULTI_O) $(LDLIBS) 56 57 58install: all 59 install -d $(DESTDIR)$(BINDIR) 60 install -m 755 jconvolver $(DESTDIR)$(BINDIR) 61 install -m 755 fconvolver $(DESTDIR)$(BINDIR) 62 install -m 755 makemulti $(DESTDIR)$(BINDIR) 63 64 65uninstall: 66 rm -f $(DESTDIR)$(BINDIR)/jconvolver 67 rm -f $(DESTDIR)$(BINDIR)/fconvolver 68 rm -f $(DESTDIR)$(BINDIR)/makemulti 69 70 71clean: 72 /bin/rm -f *~ *.o *.a *.d *.so jconvolver fconvolver makemulti 73 74