comparison Makefile.inc @ 37:44d8e5dc1902

Split out Makefile to separate single-platform versions and an .inc file
author Chris Cannam
date Fri, 12 Sep 2014 14:54:55 +0100
parents
children 716f797e2025
comparison
equal deleted inserted replaced
36:4010960c659e 37:44d8e5dc1902
1
2 ## Makefile for Vamp plugin builds using command-line tools.
3 ##
4 ## This file defines all of the system-independent information about
5 ## your project: the list of source files, plugin library name, etc.
6 ## Edit this file to make sure it has all the right information.
7 ##
8 ## This file does not define the system-specific stuff such as which
9 ## compiler to use -- that goes into Makefile.osx, Makefile.mingw32,
10 ## Makefile.linux etc. Those files all include this file, so that
11 ## they all have a consistent set of project data.
12 ##
13 ## To build the plugin project, type
14 ##
15 ## $ gmake -f Makefile.osx
16 ##
17 ## or whatever the equivalent filename suffix is for your platform.
18 ##
19 ## This requires GNU make, which is what you get with OS/X, Linux, or
20 ## MinGW/Cygwin on Windows.
21 ##
22 ## (For Windows builds using MS Visual Studio, start instead with the
23 ## VampExamplePlugins project found in the build directory of the SDK.)
24
25
26 # Edit this to the base name of your plugin library
27 #
28 PLUGIN_LIBRARY_NAME := tempogram
29
30 # Edit this to list the .cpp or .c files in your plugin project
31 #
32 PLUGIN_SOURCES := TempogramPlugin.cpp FIRFilter.cpp WindowFunction.cpp plugins.cpp NoveltyCurveProcessor.cpp SpectrogramProcessor.cpp AutocorrelationProcessor.cpp
33
34 # Edit this to list the .h files in your plugin project
35 #
36 PLUGIN_HEADERS := TempogramPlugin.h FIRFilter.h WindowFunction.h NoveltyCurveProcessor.h SpectrogramProcessor.h AutocorrelationProcessor.h
37
38
39 ## Normally you should not edit anything below this line
40
41 SRC_DIR := .
42
43 CFLAGS := $(ARCHFLAGS) $(CFLAGS)
44 CXXFLAGS := $(CFLAGS) -I. -I$(VAMPSDK_DIR) $(CXXFLAGS)
45
46 LDFLAGS := $(ARCHFLAGS) $(LDFLAGS)
47 PLUGIN_LDFLAGS := $(LDFLAGS) $(PLUGIN_LDFLAGS)
48
49 # Defaults, overridden from the platform-specific Makefile
50 VAMPSDK_DIR ?= ../vamp-plugin-sdk
51 PLUGIN_EXT ?= .so
52 CXX ?= g++
53 CC ?= gcc
54
55 PLUGIN := $(PLUGIN_LIBRARY_NAME)$(PLUGIN_EXT)
56
57 PLUGIN_OBJECTS := $(PLUGIN_SOURCES:.cpp=.o)
58 PLUGIN_OBJECTS := $(PLUGIN_OBJECTS:.c=.o)
59
60 $(PLUGIN): $(PLUGIN_OBJECTS)
61 $(CXX) -o $@ $^ $(PLUGIN_LDFLAGS)
62
63 $(PLUGIN_OBJECTS): $(PLUGIN_HEADERS)
64
65 clean:
66 rm -f $(OBJECTS)
67
68 distclean: clean
69 rm -f $(PLUGIN)
70
71 depend:
72 makedepend -Y -fMakefile.inc $(SOURCES) $(HEADERS)
73