diff options
Diffstat (limited to 'mesonbuild/compilers/c.py')
-rw-r--r-- | mesonbuild/compilers/c.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/mesonbuild/compilers/c.py b/mesonbuild/compilers/c.py index ca50c52..312760e 100644 --- a/mesonbuild/compilers/c.py +++ b/mesonbuild/compilers/c.py @@ -16,6 +16,7 @@ import re import glob import os.path import subprocess +from pathlib import Path from .. import mlog from .. import coredata @@ -885,13 +886,13 @@ class CCompiler(Compiler): @classmethod def _get_trials_from_pattern(cls, pattern, directory, libname): - f = os.path.join(directory, pattern.format(libname)) + f = Path(directory) / pattern.format(libname) # Globbing for OpenBSD if '*' in pattern: # NOTE: globbing matches directories and broken symlinks # so we have to do an isfile test on it later - return cls._sort_shlibs_openbsd(glob.glob(f)) - return [f] + return cls._sort_shlibs_openbsd(glob.glob(str(f))) + return [f.as_posix()] @staticmethod def _get_file_from_list(files): |