aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild/msetup.py
diff options
context:
space:
mode:
authorMichael Brockus <55331536+michaelbadcrumble@users.noreply.github.com>2020-03-03 11:45:43 -0800
committerGitHub <noreply@github.com>2020-03-03 21:45:43 +0200
commit98ddd52ceddb29e1c4164de47bfb2448ee1ebffe (patch)
treefdee8651ee8a1f8048fbe3d3c18bd9dad6488cc9 /mesonbuild/msetup.py
parent21e543fea8ffd1a968f67e23a8a85f6c5e5dde54 (diff)
downloadmeson-98ddd52ceddb29e1c4164de47bfb2448ee1ebffe.zip
meson-98ddd52ceddb29e1c4164de47bfb2448ee1ebffe.tar.gz
meson-98ddd52ceddb29e1c4164de47bfb2448ee1ebffe.tar.bz2
Cherry-picking - (rm python2 % add python3 .format) (#6725)
Diffstat (limited to 'mesonbuild/msetup.py')
-rw-r--r--mesonbuild/msetup.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/mesonbuild/msetup.py b/mesonbuild/msetup.py
index a2b5164..39cacea 100644
--- a/mesonbuild/msetup.py
+++ b/mesonbuild/msetup.py
@@ -118,18 +118,18 @@ class MesonApp:
if not os.path.exists(ndir2):
os.makedirs(ndir2)
if not stat.S_ISDIR(os.stat(ndir1).st_mode):
- raise MesonException('%s is not a directory' % dir1)
+ raise MesonException('{} is not a directory'.format(dir1))
if not stat.S_ISDIR(os.stat(ndir2).st_mode):
- raise MesonException('%s is not a directory' % dir2)
+ raise MesonException('{} is not a directory'.format(dir2))
if os.path.samefile(dir1, dir2):
raise MesonException('Source and build directories must not be the same. Create a pristine build directory.')
if self.has_build_file(ndir1):
if self.has_build_file(ndir2):
- raise MesonException('Both directories contain a build file %s.' % environment.build_filename)
+ raise MesonException('Both directories contain a build file {}.'.format(environment.build_filename))
return ndir1, ndir2
if self.has_build_file(ndir2):
return ndir2, ndir1
- raise MesonException('Neither directory contains a build file %s.' % environment.build_filename)
+ raise MesonException('Neither directory contains a build file {}.'.format(environment.build_filename))
def validate_dirs(self, dir1: str, dir2: str, reconfigure: bool, wipe: bool) -> T.Tuple[str, str]:
(src_dir, build_dir) = self.validate_core_dirs(dir1, dir2)