summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorScott D Phillips <scott.d.phillips@intel.com>2017-05-01 13:17:12 -0700
committerNirbheek Chauhan <nirbheek@centricular.com>2017-05-05 15:43:24 +0530
commitf8f507ed49f0e0c2d53ed815204562c0d26b6a38 (patch)
tree7cfcea6bd5b2e4d0b89ddbda802c5797acb2f480
parentf4df39a322f700ed0d7c2a456f69f805cfeedb16 (diff)
uninstalled: fixes for windows usage
Fix a couple small breakages with windows usage, (1) Add sys.executable to a subprocess invocation and (2) escape a path fragment that gets used in a regex. https://bugzilla.gnome.org/show_bug.cgi?id=782026
-rwxr-xr-xgst-uninstalled.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/gst-uninstalled.py b/gst-uninstalled.py
index d5f82b7..b357838 100755
--- a/gst-uninstalled.py
+++ b/gst-uninstalled.py
@@ -45,7 +45,7 @@ def get_subprocess_env(options):
sharedlib_reg = re.compile(r'\.so|\.dylib|\.dll')
typelib_reg = re.compile(r'.*\.typelib$')
- pluginpath_reg = re.compile(r'lib.*' + os.path.normpath('/gstreamer-1.0/'))
+ pluginpath_reg = re.compile(r'lib.*' + re.escape(os.path.normpath('/gstreamer-1.0/')))
if os.name is 'nt':
lib_path_envvar = 'PATH'
@@ -85,7 +85,7 @@ def get_subprocess_env(options):
presets = set()
encoding_targets = set()
pkg_dirs = set()
- if '--installed' in subprocess.check_output([mesonintrospect, '-h']).decode():
+ if '--installed' in subprocess.check_output([sys.executable, mesonintrospect, '-h']).decode():
installed_s = subprocess.check_output([sys.executable, mesonintrospect,
options.builddir, '--installed'])
for path, installpath in json.loads(installed_s.decode()).items():