2 # -*- coding: utf-8 -*-
3 # Distutils installer for PyJack
6 #---------------------------------------------------#
8 if os
.path
.exists("/usr/local/include/jack/jack.h"):
9 path
= "/usr/local/include/jack/jack.h"
10 elif os
.path
.exists("/usr/include/jack/jack.h"):
11 path
= "/usr/include/jack/jack.h"
13 print "You don't seem to have the jack headers installed.\nPlease install them first"
16 test
= open(path
).read()
18 if ("jack_get_version_string" in test
):
19 os
.system("patch -f -s -p0 -r build/jack2.rej < ./patches/enable-jack2.diff > /dev/null")
21 os
.system("patch -R -f -s -p0 -r build/jack2.rej < ./patches/enable-jack2.diff > /dev/null")
22 #----------------------------------------------------#
25 from distutils
.core
import setup
, Extension
26 import numpy
.distutils
28 numpy_include_dirs
= numpy
.distutils
.misc_util
.get_numpy_include_dirs()
33 description
= "Python bindings for the Jack Audio Server",
34 author
= "Andrew W. Schmeder, falkTX",
35 author_email
= "andy@a2hd.com",
36 url
= "http://www.a2hd.com/software",
38 ext_modules
= [Extension("jack", ["pyjack.c"], libraries
=["jack", "dl"], include_dirs
=numpy_include_dirs
)],