diff options
author | Jussi Pakkanen <jpakkane@gmail.com> | 2017-01-23 20:42:47 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-01-23 20:42:47 +0200 |
commit | 469a758c322bc161d9d0bab00cf213acf7b33df5 (patch) | |
tree | c1ad4863733b5b2e1b944f533740d6fde9a407fa /mesonbuild | |
parent | 23f3cec9d029b5d44fa7f6a109ab9cda948b12ba (diff) | |
parent | d9c31d4a243f167b75dde4122260ead27aa0d69a (diff) | |
download | meson-469a758c322bc161d9d0bab00cf213acf7b33df5.zip meson-469a758c322bc161d9d0bab00cf213acf7b33df5.tar.gz meson-469a758c322bc161d9d0bab00cf213acf7b33df5.tar.bz2 |
Merge pull request #1320 from centricular/fix-llvmir-and-assembly
Fix llvmir and assembly
Diffstat (limited to 'mesonbuild')
-rw-r--r-- | mesonbuild/backend/ninjabackend.py | 4 | ||||
-rw-r--r-- | mesonbuild/compilers.py | 7 |
2 files changed, 6 insertions, 5 deletions
diff --git a/mesonbuild/backend/ninjabackend.py b/mesonbuild/backend/ninjabackend.py index 8de9b5a..e1a478c 100644 --- a/mesonbuild/backend/ninjabackend.py +++ b/mesonbuild/backend/ninjabackend.py @@ -1758,9 +1758,9 @@ rule FORTRAN_DEP_HACK Compiles C/C++, ObjC/ObjC++, Fortran, and D sources """ if isinstance(src, str) and src.endswith('.h'): - raise AssertionError('BUG: sources should not contain headers') + raise AssertionError('BUG: sources should not contain headers {!r}'.format(src)) if isinstance(src, RawFilename) and src.fname.endswith('.h'): - raise AssertionError('BUG: sources should not contain headers') + raise AssertionError('BUG: sources should not contain headers {!r}'.format(src.fname)) extra_orderdeps = [] compiler = get_compiler_for_source(target.compilers.values(), src) commands = [] diff --git a/mesonbuild/compilers.py b/mesonbuild/compilers.py index 22ee003..4178f0b 100644 --- a/mesonbuild/compilers.py +++ b/mesonbuild/compilers.py @@ -53,9 +53,10 @@ clike_langs = ('objcpp', 'objc', 'd', 'cpp', 'c', 'fortran',) clike_suffixes = () for l in clike_langs: clike_suffixes += lang_suffixes[l] -clike_suffixes += ('h',) +clike_suffixes += ('h', 'll', 's') + +# All these are only for C-like languages; see `clike_langs` above. -# These are used in backend/backends.py:generated_target() def is_header(fname): if hasattr(fname, 'fname'): fname = fname.fname @@ -65,7 +66,7 @@ def is_header(fname): def is_source(fname): if hasattr(fname, 'fname'): fname = fname.fname - suffix = fname.split('.')[-1] + suffix = fname.split('.')[-1].lower() return suffix in clike_suffixes def is_assembly(fname): |