Paolo Bonzini
3efed376c3
linkers: remove is_shared_module argument to get_soname_args
...
The argument is now unused, drop it.
3 years ago
Pamplemousse
762c073500
Clang: Apply `-O0`
...
Fix #8986
3 years ago
Andrea Pappacoda
81d9acab87
Fix unsupported linker error message
...
An `f` was dropped in bd6f46e723
3 years ago
Eli Schwartz
bd6f46e723
condense lines
3 years ago
Eli Schwartz
b4b488f33c
simplify mesonlib imports for the sake of line lengths
3 years ago
Eli Schwartz
dd31891c1f
more f-strings too complex to be caught by pyupgrade
3 years ago
miebka
3021f256ea
C2000: linker uses now binary setting defined within the cross-file
4 years ago
Daniel Mensinger
3e396b3782
fix: Always explicitly set encoding for text files ( fixes #8263 )
4 years ago
Ian Harvey
84b371c645
Update detect.py
...
Adjust Intel Fortran compiler detection to handle changes in ifort logo with the introduction of the oneapi toolkit. See #8338 .
4 years ago
Daniel Mensinger
b95d6e319f
typing: Annotate compilers.detect
4 years ago
Daniel Mensinger
3f889606c7
Split compiler detection from Environment
...
This moves all the compiler detection logic into the new
compilers.detect module. This dramatically reduces the size
and complexity of Environment.
4 years ago
Justin Handville
e8e03cdc72
Fixed style issue as per comments on PR 8911.
4 years ago
Justin Handville
9f248c778d
Fix for Issue 8910 (Meson filters CMake asm files)
4 years ago
Daniel Mensinger
66b32a4591
holders: Introduce HoldableObject
4 years ago
Daniel Mensinger
202e345dfb
interpreter: Refactor interpreter.compiler to use ObjectHolder
4 years ago
Daniel Mensinger
9c40b33cf6
compilers: Fix missing functions in Compiler base class
4 years ago
Eli Schwartz
998076a192
upgrade percent formatted strings pyupgrade did not catch
4 years ago
Eli Schwartz
3eb1da1fa2
condense lines
4 years ago
Eli Schwartz
2c71b63e77
more f-strings everywhere
...
pyupgrade didn't catch many .format() methods which were too complex
(e.g. multiline or applied to templates rather than string literals)
4 years ago
Dylan Baker
0bc18f26a2
cython: Add an option for selecting python 3 vs python 2 output
4 years ago
Dylan Baker
4d1cbd1b8a
compilers: Add cython file suffixes
4 years ago
Dylan Baker
edf1a21722
compilers: Expose Cython compiler
4 years ago
Dylan Baker
e9681b463d
hack: compilers/cython: hardcode python 3 not 2
4 years ago
Dylan Baker
79e50caa7f
compilers: Add a cython Compiler
4 years ago
Daniel Mensinger
240434b167
typing: Fully annotate dependencies.cuda
4 years ago
Dylan Baker
113a159514
use an immutable list for an lru_cached functions
...
When mutable items are stored in an lru cache, changing the returned
items changes the cached items as well. Therefore we want to ensure that
we're not mutating them. Using the ImmutableListProtocol allows mypy to
find mutations and reject them. This doesn't solve the problem of
mutable values inside the values, so you could have to do things like:
```python
ImmutableListProtocol[ImmutableListProtocol[str]]
```
or equally hacky. It can also be used for input types and acts a bit
like C's const:
```python
def foo(arg: ImmutableListProtocol[str]) -> T.List[str]:
arg[1] = 'foo' # works while running, but mypy errors
```
4 years ago
Dylan Baker
156d6160d1
compilers: Add `get_debug_args` to base Compiler
...
This was missed, there should be an implementation in the base Compiler
class, if for nothing else to help mypy
4 years ago
Dylan Baker
b1b8e777a2
rust: override get_linker_always_args
...
instead of opencoding what should be there in the rust compile rule
4 years ago
Volker-Weissmann
4ca9a16288
.C files are now treated as C++ code
4 years ago
Peter Harris
be015a37d7
Visual Studio Address Sanitizer updates
...
* Allow address sanitizer for Visual Studio 2019 version 16.9
Address Sanitizer was first supported with the current syntax in Visual
Studio 16.9.0 (cl version 19.28.29910).
* VS: Convert /fsanitize=address to project file setting
4 years ago
Jussi Pakkanen
ab0b727427
Add gnuXX stds to Objective C.
4 years ago
Jussi Pakkanen
c54dd63547
Make objective C use C standard version. Closes #5495 .
4 years ago
Alexander Neumann
8f12102549
deactivate intrinsic functions if no optimizations are requested
4 years ago
Ralf Gommers
a48a89374a
Clean up unused imports
4 years ago
Ralf Gommers
d0325c898a
Use sanity_check_impl for objc/objpp
...
This gets rid of compile warnings, and simplifies the code.
Note that `work_dir` in sanity_check_impl was incorrect,
it was used both to prepend to file names and as cwd=work_dir
argument to Popen. This is fixed here.
Closes gh-7344
4 years ago
Dylan Baker
f99ed692c4
environment: get environment variables for both host and build machines
...
Fixes #8605
4 years ago
Dylan Baker
2cd0723c42
Split environment variable and command line cflags
...
They are supposed to have different behavior. The environment variables
apply to both the compiler and linker when the compiler acts as a
linker, but the command line ones do not.
Fixes #8345
4 years ago
Olexa Bilaniuk
2579420a72
Strip host-compiler -std flag from NVCC line.
...
Closes #8523 .
4 years ago
Olexa Bilaniuk
5941e94ff8
Retract "DQSQ" merging in NVCC arguments handling.
...
No coverage, no tests, unreadable, unused, likely premature
optimization.
4 years ago
Olexa Bilaniuk
3dbd493de2
Canonicalize and merge consecutive -Xcompiler flags together.
...
Makes command-line more readable.
4 years ago
D Scott Phillips
703fd6d1fa
compilers: clang-cl: Also accept .s files ( #8520 )
...
* compilers: clang-cl: Also accept .s files
clang-cl has support for gas-compatible assembly files.
* Add clang-cl to '128 generated assembly' test
4 years ago
Jussi Pakkanen
9ab4dadef9
Remove -pipe from default list of args. Closes #8508 .
4 years ago
Dylan Baker
40e3577a65
split program related classes and functions out of dependencies
...
Dependencies is already a large and complicated package without adding
programs to the list. This also allows us to untangle a bit of spaghetti
that we have.
4 years ago
Remi Thebault
c756d97895
Fix D lib search path translation
...
This requires quite a complex and messy logic.
As @dcbaker suggested in #8491 , this could be replaced by
an abstraction over linker flags instead of having GNU flags
translated.
4 years ago
Dylan Baker
2be074b1d4
ninjabackend: Use rsp_file_syntax method
...
This also makes us of the new enum value in the backend, for better type
saftey.
4 years ago
Dylan Baker
320412b3bb
compilers/linkers: Add a methhod for getting the rspfile syntax
4 years ago
Jussi Pakkanen
d76345b4be
Add address sanitizer support for Visual Studio.
4 years ago
Vili Väinölä
96405c3923
Add /Od flag to msvc optimization 0 args
...
Without specifying optimization the used optimization depends on vs runtime-library.
With mdd it is /Od but with md it is /O2.
4 years ago
Dylan Baker
504ae2dee8
compilers: Use EnvironmentException not EnvironmentError/OSError
...
The latter is a python built-in exception, the former is a meson
exception.
4 years ago
Eli Schwartz
6a0fabc647
mass rewrite of string formatting to use f-strings everywhere
...
performed by running "pyupgrade --py36-plus" and committing the results
4 years ago