annotate skeleton/Makefile.skeleton @ 301:7178510d747a

* Add include required for gcc 4.4
author cannam
date Mon, 28 Sep 2009 09:39:09 +0000
parents bb67b6145812
children b923a3d9c3d5
rev   line source
cannam@299 1
cannam@299 2 ## Skeleton Makefile for Vamp plugin builds using command-line tools.
cannam@299 3 ##
cannam@299 4 ## Rename this to Makefile, and edit as appropriate.
cannam@299 5 ## This Makefile WILL NOT WORK until you have edited it as described
cannam@299 6 ## below -- the Makefile as supplied does nothing useful at all!
cannam@299 7 ##
cannam@299 8 ## Various sets of options are provided, commented out -- just uncomment
cannam@299 9 ## (remove the '#' characters for) the set that most closely resembles
cannam@299 10 ## your own situation, and adjust to taste. Then run "make".
cannam@299 11 ##
cannam@299 12 ## (For Windows builds using MS Visual Studio, start instead with the
cannam@299 13 ## VampExamplePlugins project found in the build directory of the SDK.)
cannam@299 14
cannam@299 15
cannam@299 16 # Edit this to the base name of your plugin library
cannam@299 17 #
cannam@299 18 PLUGIN_LIBRARY_NAME = myplugins
cannam@299 19
cannam@299 20 # Edit this to list one .o file for each .cpp file in your plugin project
cannam@299 21 #
cannam@300 22 PLUGIN_CODE_OBJECTS = MyPlugin.o plugins.o
cannam@299 23
cannam@299 24 # Edit this to the location of the Vamp plugin SDK, relative to your
cannam@299 25 # project directory
cannam@299 26 #
cannam@299 27 VAMP_SDK_DIR = ../vamp-plugin-sdk
cannam@299 28
cannam@299 29
cannam@299 30 ## Uncomment these for an OS/X native build using command-line tools:
cannam@299 31
cannam@299 32 # CXXFLAGS = -I$(VAMP_SDK_DIR) -Wall -fPIC
cannam@299 33 # PLUGIN_EXT = .dylib
cannam@299 34 # PLUGIN = $(PLUGIN_LIBRARY_NAME)$(PLUGIN_EXT)
cannam@299 35 # LDFLAGS = -dynamiclib -install_name $(PLUGIN) $(VAMP_SDK_DIR)/libvamp-sdk.a -exported_symbols_list vamp-plugin.list
cannam@299 36
cannam@299 37
cannam@299 38 ## Uncomment these for an OS/X universal binary using command-line tools:
cannam@299 39
cannam@299 40 # CXXFLAGS = -isysroot /Developer/SDKs/MacOSX10.4u.sdk -arch i386 -arch ppc -I$(VAMP_SDK_DIR) -Wall -fPIC
cannam@299 41 # PLUGIN_EXT = .dylib
cannam@299 42 # PLUGIN = $(PLUGIN_LIBRARY_NAME)$(PLUGIN_EXT)
cannam@299 43 # LDFLAGS = -dynamiclib -install_name $(PLUGIN) $(VAMP_SDK_DIR)/libvamp-sdk.a -exported_symbols_list vamp-plugin.list
cannam@299 44
cannam@299 45
cannam@299 46 ## Uncomment these for Linux using the standard tools:
cannam@299 47
cannam@299 48 # CXXFLAGS = -I$(VAMP_SDK_DIR) -Wall -fPIC
cannam@299 49 # PLUGIN_EXT = .so
cannam@299 50 # PLUGIN = $(PLUGIN_LIBRARY_NAME)$(PLUGIN_EXT)
cannam@299 51 # LDFLAGS = -shared -Wl,-soname=$(PLUGIN) $(VAMP_SDK_DIR)/libvamp-sdk.a -Wl,--version-script=vamp-plugin.map
cannam@299 52
cannam@299 53
cannam@299 54 ## Uncomment these for a cross-compile from Linux to Windows using MinGW:
cannam@299 55
cannam@299 56 # CXX = i586-mingw32msvc-g++
cannam@299 57 # CXXFLAGS = -I$(VAMP_SDK_DIR) -Wall
cannam@299 58 # PLUGIN_EXT = .dll
cannam@299 59 # PLUGIN = $(PLUGIN_LIBRARY_NAME)$(PLUGIN_EXT)
cannam@299 60 # LDFLAGS = --static-libgcc -Wl,-soname=$(PLUGIN) -shared $(VAMP_SDK_DIR)/libvamp-sdk.a
cannam@299 61
cannam@299 62
cannam@299 63 ## Uncomment these for OpenSolaris using SunStudio compiler and GNU make:
cannam@299 64
cannam@299 65 # CXX = CC
cannam@299 66 # CXXFLAGS = -G -I$(VAMP_SDK_DIR) +w -KPIC
cannam@299 67 # PLUGIN_EXT = .so
cannam@299 68 # PLUGIN = $(PLUGIN_LIBRARY_NAME)$(PLUGIN_EXT)
cannam@299 69 # LDFLAGS = -G -h$(PLUGIN) $(VAMP_SDK_DIR)/libvamp-sdk.a -Qoption ld -Mvamp-plugin.map
cannam@299 70
cannam@299 71
cannam@299 72
cannam@299 73 ## All of the above
cannam@299 74
cannam@299 75 $(PLUGIN): $(PLUGIN_CODE_OBJECTS)
cannam@299 76 $(CXX) -o $@ $^ $(LDFLAGS)
cannam@299 77
cannam@299 78 clean:
cannam@299 79 rm -f *.o
cannam@299 80