diff options
author | David Robillard <d@drobilla.net> | 2010-11-26 20:33:47 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2010-11-26 20:33:47 +0000 |
commit | 8db955c711c0928e241e5dc7b77bf335dd4bb6d6 (patch) | |
tree | df1a53b0c1d618b930fc59a20367703ea88c6316 /core.lv2/lv2config | |
parent | e0c4fb1bc1c66e5655a41ddcbfaafb07e32b93a2 (diff) | |
download | lv2-8db955c711c0928e241e5dc7b77bf335dd4bb6d6.tar.xz |
Remove scheme from LV2 #include directives.
Check the given header directory is named 'lv2' (to conform to #include standard).
Diffstat (limited to 'core.lv2/lv2config')
-rwxr-xr-x | core.lv2/lv2config | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/core.lv2/lv2config b/core.lv2/lv2config index 5f43716..10d77e3 100755 --- a/core.lv2/lv2config +++ b/core.lv2/lv2config @@ -104,6 +104,10 @@ def build_tree(search_path, outdir): """Build a directory tree under outdir containing symlinks to all LV2 extensions found in search_path, such that the symlink paths correspond to the extension URIs.""" + if os.path.basename(outdir) != 'lv2': + print >> sys.stderr, "lv2config: output dir must be named `lv2'" + sys.exit(1) + if os.access(outdir, os.F_OK) and not os.access(outdir, os.W_OK): print >> sys.stderr, "lv2config: cannot build `%s': Permission denied" % outdir sys.exit(1) @@ -120,9 +124,8 @@ def build_tree(search_path, outdir): # Query extension URI specs = rdf_find_type(manifest, lv2.Specification) for ext_uri in specs: - ext_scheme = ext_uri[0:ext_uri.find(':')] ext_path = os.path.normpath(ext_uri[ext_uri.find(':') + 1:].lstrip('/')) - ext_dir = os.path.join(outdir, ext_scheme, ext_path) + ext_dir = os.path.join(outdir, ext_path) # Make parent directories __mkdir_p(os.path.dirname(ext_dir)) |