source: tests/python/localaubio.py @ 67d0a8b

feature/autosinkfeature/cnnfeature/cnn_orgfeature/constantqfeature/crepefeature/crepe_orgfeature/pitchshiftfeature/pydocstringsfeature/timestretchfix/ffmpeg5pitchshiftsamplertimestretchyinfft+
Last change on this file since 67d0a8b was b45b4ea, checked in by Paul Brossier <piem@piem.org>, 15 years ago

tests/python/localaubio.py: swith location

  • Property mode set to 100644
File size: 999 bytes
RevLine 
[974dddc]1
2# add ${src}/python and ${src}/python/aubio/.libs to python path
3# so the script is runnable from a compiled source tree.
4
5try:
6  from aubio.aubiowrapper import * 
7except ImportError:
8  try: 
9    import os
10    import sys
[a250b35]11    cur_dir = os.path.dirname(__file__)
[974dddc]12    sys.path.append(os.path.join(cur_dir,'..','..','python'))
[b45b4ea]13    # autotools places
[a9f1656]14    sys.path.append(os.path.join(cur_dir,'..','..','python','aubio'))
[974dddc]15    sys.path.append(os.path.join(cur_dir,'..','..','python','aubio','.libs'))
[b45b4ea]16    # waf places
[a9f1656]17    sys.path.append(os.path.join(cur_dir,'..','..','build', 'default', 'swig'))
[a250b35]18    sys.path.append(os.path.join(cur_dir,'..','..','build', 'default', 'python','aubio'))
[a9f1656]19    from aubiowrapper import * 
[974dddc]20  except ImportError:
21    raise
22else:
[92c70f6]23  raise ImportError, \
24    """
25    The aubio module could be imported BEFORE adding the source directory to
26    your path. Make sure you NO other version of the python aubio module is
27    installed on your system.
28    """
[a9f1656]29
30from template import * 
Note: See TracBrowser for help on using the repository browser.