# HG changeset patch # User Chris Cannam # Date 1549970834 0 # Node ID 471142e74a1a34ffe891fb5327828215da1a30d9 # Parent efff8e5d90a3c29af9177c2e89030a9e717abc84# Parent c4e00c81a0c7d04aff5c919fb862af4b4934709b Merge diff -r efff8e5d90a3 -r 471142e74a1a .hgignore --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/.hgignore Tue Feb 12 11:27:14 2019 +0000 @@ -0,0 +1,8 @@ +syntax: glob +*~ +*.pyc +*.so +*.orig + + + diff -r efff8e5d90a3 -r 471142e74a1a .hgtags --- a/.hgtags Tue Feb 12 11:27:02 2019 +0000 +++ b/.hgtags Tue Feb 12 11:27:14 2019 +0000 @@ -1,1 +1,4 @@ 62dcaa5fe6f8cc7ba199dad6dde95f6e5ef1063e vampy-2.0 +3b6b3f0cffcbd0c3626ca0dbf025f5551ca5e681 vampy-2.1 +3b6b3f0cffcbd0c3626ca0dbf025f5551ca5e681 vampy-2.1 +76badb3a0bb3f8090bb8ba75e1473dae4bcee548 vampy-2.1 diff -r efff8e5d90a3 -r 471142e74a1a Dockerfile.in --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Dockerfile.in Tue Feb 12 11:27:14 2019 +0000 @@ -0,0 +1,20 @@ +FROM ubuntu:16.04 +MAINTAINER Chris Cannam +RUN apt-get update && \ + apt-get install -y \ + build-essential \ + libsndfile-dev \ + git \ + mercurial \ + curl wget \ + python libpython2.7-dev python-numpy +RUN apt-cache search python +RUN apt-get clean && rm -rf /var/lib/apt/lists/* +RUN hg clone -r[[REVISION]] https://code.soundsoftware.ac.uk/hg/vampy +RUN hg clone https://code.soundsoftware.ac.uk/hg/vamp-plugin-sdk +WORKDIR vamp-plugin-sdk +RUN ./configure +RUN make -j3 +WORKDIR ../vampy +RUN make -f Makefile.linux + diff -r efff8e5d90a3 -r 471142e74a1a Makefile.linux --- a/Makefile.linux Tue Feb 12 11:27:02 2019 +0000 +++ b/Makefile.linux Tue Feb 12 11:27:14 2019 +0000 @@ -3,9 +3,10 @@ -D_DEBUG -O2 -Wall -Werror -fno-strict-aliasing -fPIC \ -I/usr/include/python2.7 \ -I/usr/lib/python2.7/dist-packages/numpy/core/include \ - -I/usr/lib/python2.7/site-packages/numpy/core/include + -I/usr/lib/python2.7/site-packages/numpy/core/include \ + -I../vamp-plugin-sdk -LDFLAGS += -shared -Wl,-Bstatic -lvamp-sdk -Wl,-Bdynamic -lpython2.7 -lpthread -Wl,--version-script=vamp-plugin.map +LDFLAGS += -shared -Wl,-Bstatic -L../vamp-plugin-sdk -lvamp-sdk -Wl,-Bdynamic -lpython2.7 -lpthread -Wl,--version-script=vamp-plugin.map default: vampy.so all: vampy.so vampymod.so diff -r efff8e5d90a3 -r 471142e74a1a README --- a/README Tue Feb 12 11:27:02 2019 +0000 +++ b/README Tue Feb 12 11:27:14 2019 +0000 @@ -10,9 +10,9 @@ with a C/C++ Application Programming Interface (API). Typical applications of Vamp plugins include visualisation, using - a host such as Sonic Visualiser (http://www.sonicvisualiser.org/), + a host such as Sonic Visualiser (https://www.sonicvisualiser.org/), or batch feature extraction from audio, using Sonic Annotator - (http://www.omras2.org/SonicAnnotator). + (https://vamp-plugins.org/sonic-annotator). Vamp plugins are typically written in C++. Although currently available plugin hosts are valuable tools in audio research, @@ -78,8 +78,8 @@ Note that Vampy does not support Python 3 at all at this point. Note also that on a Mac in normal circumstances Vampy - expects to use the system installation of Python, so plugin - modules you write should be tested using this. + expects to use the system installation of Python, so plugins + that you write should be tested using the system Python. * Vampy supports Numpy 1.1 or greater. diff -r efff8e5d90a3 -r 471142e74a1a VamPy.sln --- a/VamPy.sln Tue Feb 12 11:27:02 2019 +0000 +++ b/VamPy.sln Tue Feb 12 11:27:14 2019 +0000 @@ -8,13 +8,19 @@ Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Win32 = Debug|Win32 + Debug|x64 = Debug|x64 Release|Win32 = Release|Win32 + Release|x64 = Release|x64 EndGlobalSection GlobalSection(ProjectConfigurationPlatforms) = postSolution {0412DCE9-EE58-4A99-9154-14935B0BCFAA}.Debug|Win32.ActiveCfg = Debug|Win32 {0412DCE9-EE58-4A99-9154-14935B0BCFAA}.Debug|Win32.Build.0 = Debug|Win32 + {0412DCE9-EE58-4A99-9154-14935B0BCFAA}.Debug|x64.ActiveCfg = Debug|x64 + {0412DCE9-EE58-4A99-9154-14935B0BCFAA}.Debug|x64.Build.0 = Debug|x64 {0412DCE9-EE58-4A99-9154-14935B0BCFAA}.Release|Win32.ActiveCfg = Release|Win32 {0412DCE9-EE58-4A99-9154-14935B0BCFAA}.Release|Win32.Build.0 = Release|Win32 + {0412DCE9-EE58-4A99-9154-14935B0BCFAA}.Release|x64.ActiveCfg = Release|x64 + {0412DCE9-EE58-4A99-9154-14935B0BCFAA}.Release|x64.Build.0 = Release|x64 EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE diff -r efff8e5d90a3 -r 471142e74a1a VamPy.vcxproj --- a/VamPy.vcxproj Tue Feb 12 11:27:02 2019 +0000 +++ b/VamPy.vcxproj Tue Feb 12 11:27:14 2019 +0000 @@ -5,10 +5,18 @@ Debug Win32 + + Debug + x64 + Release Win32 + + Release + x64 + {0412DCE9-EE58-4A99-9154-14935B0BCFAA} @@ -19,19 +27,33 @@ DynamicLibrary v120 + + DynamicLibrary + v120 + DynamicLibrary v120 + + DynamicLibrary + v120 + + + + + + + <_ProjectFileVersion>12.0.30501.0 @@ -41,11 +63,17 @@ Debug\ true + + true + Release\ Release\ true + + true + Disabled @@ -67,18 +95,38 @@ MachineX86 + + + Disabled + ..\vamp-plugin-sdk;C:\Python27\include;%(AdditionalIncludeDirectories) + WIN32;_DEBUG;_WINDOWS;_USRDLL;VAMPY_EXPORTS;%(PreprocessorDefinitions) + EnableFastChecks + MultiThreadedDebugDLL + + + Level3 + ProgramDatabase + + + /EXPORT:vampGetPluginDescriptor %(AdditionalOptions) + VampPluginSDK.lib;python27.lib;%(AdditionalDependencies) + ..\vamp-plugin-sdk\build\Debug;C:\Python27\libs;%(AdditionalLibraryDirectories) + true + Windows + + ..\vamp-plugin-sdk;C:\Python27\include;C:\Python27\Lib\site-packages\numpy\core\include;%(AdditionalIncludeDirectories) WIN32;NDEBUG;_WINDOWS;_USRDLL;VAMPY_EXPORTS;HAVE_NUMPY;%(PreprocessorDefinitions) - MultiThreadedDLL + MultiThreaded Level3 ProgramDatabase /EXPORT:vampGetPluginDescriptor %(AdditionalOptions) - VampPluginSDK.lib;python27.lib;%(AdditionalDependencies) + python27.lib;%(AdditionalDependencies) ..\vamp-plugin-sdk\build\Release;C:\Python27\libs;%(AdditionalLibraryDirectories) true Windows @@ -87,6 +135,26 @@ MachineX86 + + + ..\vamp-plugin-sdk;C:\Python27-64\include;C:\Python27-64\Lib\site-packages\numpy\core\include;C:\Python27-64\Lib\site-packages\numpy-1.16.1-py2.7-win-amd64.egg\numpy\core\include;%(AdditionalIncludeDirectories) + WIN32;NDEBUG;_WINDOWS;_USRDLL;VAMPY_EXPORTS;HAVE_NUMPY;%(PreprocessorDefinitions) + MultiThreaded + + + Level3 + ProgramDatabase + + + /EXPORT:vampGetPluginDescriptor %(AdditionalOptions) + python27.lib;%(AdditionalDependencies) + C:\Python27-64\libs;%(AdditionalLibraryDirectories) + true + Windows + true + true + + @@ -101,6 +169,9 @@ + + + diff -r efff8e5d90a3 -r 471142e74a1a dockerbuild.sh --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/dockerbuild.sh Tue Feb 12 11:27:14 2019 +0000 @@ -0,0 +1,32 @@ +#!/bin/bash +# +# Docker required! + +set -eu + +current=$(hg id | awk '{ print $1; }') + +case "$current" in + *+) echo "WARNING: Current working copy has been modified - build will check out the last commit, which must perforce be different";; + *);; +esac + +current=${current%%+} + +rm -f vampy.so + +cat Dockerfile.in | perl -p -e 's/\[\[REVISION\]\]/'"$current"'/' > Dockerfile + +dockertag="cannam/vampy-$current" + +sudo docker build -t "$dockertag" -f Dockerfile . + +container=$(sudo docker create "$dockertag") +sudo docker cp "$container":vampy/vampy.so . +sudo docker rm "$container" + +ldd vampy.so +VAMP_PATH=".:./Example VamPy plugins" ../vamp-plugin-sdk/host/vamp-simple-host -l + +echo "Done!" +