[vlc-commits] [Git][videolan/vlc][master] 4 commits: contrib: fxc2: fix call under wine
Steve Lhomme (@robUx4)
gitlab at videolan.org
Wed Jul 17 09:15:51 UTC 2024
Steve Lhomme pushed to branch master at VideoLAN / VLC
Commits:
8107458e by Steve Lhomme at 2024-07-17T08:36:41+00:00
contrib: fxc2: fix call under wine
Otherwise we get this error:
File "/builds/robUx4/vlc/contrib/i686-w64-mingw32/bin/fxc", line 27, in toSystemPath
sub = subprocess.Popen([pathCmd, '-m', absPath], shell=False, stderr=subprocess.DEVNULL, stdout=subprocess.PIPE)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/subprocess.py", line 1024, in __init__
self._execute_child(args, executable, preexec_fn, close_fds,
File "/usr/lib/python3.11/subprocess.py", line 1901, in _execute_child
raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: 'wine winepath'
- - - - -
235613e2 by Steve Lhomme at 2024-07-17T08:36:41+00:00
package/win32: remove stray qtvlcdeps reference
- - - - -
41008cf8 by Steve Lhomme at 2024-07-17T08:36:41+00:00
contrib: fxc2: report the error when getting a path failed
- - - - -
ec5ddbeb by Steve Lhomme at 2024-07-17T08:36:41+00:00
contrib: fxc2: use -w with winepath
It doesn't understand the unix friendly "-m".
Hopefully it goes through correctly through subprocess.Popen().
- - - - -
2 changed files:
- contrib/src/fxc2/fxc
- extras/package/win32/build.sh
Changes:
=====================================
contrib/src/fxc2/fxc
=====================================
@@ -16,21 +16,23 @@ def toSystemPath(path: str):
return absPath
if platform.system() == 'Linux':
- pathCmd = None
if shutil.which('cygpath'):
- pathCmd = 'cygpath'
+ pathCmd = ['cygpath', '-m']
elif shutil.which('wslpath'):
- pathCmd = 'wslpath'
+ pathCmd = ['wslpath', '-m']
else:
- pathCmd = 'wine winepath'
+ pathCmd = ['winepath', '-w']
# convert to hybrid mode to avoid forward slashes in shell
- sub = subprocess.Popen([pathCmd, '-m', absPath], shell=False, stderr=subprocess.DEVNULL, stdout=subprocess.PIPE)
+ sub = subprocess.Popen(pathCmd + [absPath], shell=False, stderr=subprocess.PIPE, stdout=subprocess.PIPE)
+ p, err = sub.communicate()
errcode = sub.wait()
if errcode != 0:
- log_error('failed to find Windows path using {} for "{}"'.format(pathCmd, absPath))
+ log_error('failed to find Windows path using {} for "{}" : {}'.format(pathCmd, absPath, err))
exit(1)
- p, err = sub.communicate()
- return p.decode('utf-8').strip()
+ mixedPath = p.decode('utf-8').strip()
+ if pathCmd[1] == '-w':
+ mixedPath = mixedPath.replace('\\', '/')
+ return mixedPath
def main():
this_path = os.path.dirname(os.path.abspath(sys.argv[0]))
=====================================
extras/package/win32/build.sh
=====================================
@@ -345,7 +345,7 @@ if [ "$RELEASE" != "yes" ]; then
CONTRIBFLAGS="$CONTRIBFLAGS --disable-optim"
fi
if [ ! -z "$DISABLEGUI" ]; then
- CONTRIBFLAGS="$CONTRIBFLAGS --disable-qt --disable-qtsvg --disable-qtdeclarative --disable-qt5compat --disable-qtshadertools --disable-qtwayland --disable-qtvlcdeps"
+ CONTRIBFLAGS="$CONTRIBFLAGS --disable-qt --disable-qtsvg --disable-qtdeclarative --disable-qt5compat --disable-qtshadertools --disable-qtwayland"
fi
if [ ! -z "$WINSTORE" ]; then
# we don't use a special toolchain to trigger the detection in contribs so force it manually
View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/e49b7192a01931c8cca64c0e5568e9eaf2c0e7e3...ec5ddbeb66ab9c6b9200bdae0762a1e787fdf411
--
View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/e49b7192a01931c8cca64c0e5568e9eaf2c0e7e3...ec5ddbeb66ab9c6b9200bdae0762a1e787fdf411
You're receiving this email because of your account on code.videolan.org.
VideoLAN code repository instance
More information about the vlc-commits
mailing list