diff options
author | Volker-Weissmann <39418860+Volker-Weissmann@users.noreply.github.com> | 2021-01-25 23:06:31 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-01-26 00:06:31 +0200 |
commit | 9e3bb9eea395f01013c6b606ff23438729c2fb81 (patch) | |
tree | b62955c89eb807dfd2fe39b45637493057de4947 /mesonbuild/mesonlib/universal.py | |
parent | bb6385111a60793c6adc88df229a819ffb132fab (diff) | |
download | meson-9e3bb9eea395f01013c6b606ff23438729c2fb81.zip meson-9e3bb9eea395f01013c6b606ff23438729c2fb81.tar.gz meson-9e3bb9eea395f01013c6b606ff23438729c2fb81.tar.bz2 |
Warn about .C and .H files (#8249)
Diffstat (limited to 'mesonbuild/mesonlib/universal.py')
-rw-r--r-- | mesonbuild/mesonlib/universal.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/mesonbuild/mesonlib/universal.py b/mesonbuild/mesonlib/universal.py index c16f165..dfcec8e 100644 --- a/mesonbuild/mesonlib/universal.py +++ b/mesonbuild/mesonlib/universal.py @@ -348,8 +348,15 @@ class FileMode: perms |= stat.S_ISVTX return perms +dot_C_dot_H_warning = """You are using .C or .H files in your project. This is deprecated. + Currently, Meson treats this as C code, but this + might change in the future, breaking your build. + You code also might be already broken on gcc and clang. + See https://github.com/mesonbuild/meson/pull/8239 for the discussions.""" class File: def __init__(self, is_built: bool, subdir: str, fname: str): + if fname.endswith(".C") or fname.endswith(".H"): + mlog.warning(dot_C_dot_H_warning, once=True) self.is_built = is_built self.subdir = subdir self.fname = fname |