Xavier Claessens
86aaac8e42
backends: Stop separating base and compiler options
...
Since OptionKey is used we can mix all options together in a single
dictionary. That's already what we do in coredata.options.
3 years ago
Eli Schwartz
a28d546795
flake8: fix wonky comment style
3 years ago
Eli Schwartz
8947352889
fix various flake8 whitespace errors
3 years ago
Eli Schwartz
4ab70c5512
fix extra whitespace
...
discovered via flake8 --select E303
3 years ago
Eli Schwartz
5a8e066c56
remove useless variables that are no longer or were never used
3 years ago
Eli Schwartz
c43bad2369
fix untested codepath? add:item() is surely a typo, not a real function
3 years ago
Dylan Baker
b60bd0e299
pyllint: enable consider-user-enumerate
...
This caught a couple of cases of us doing:
```python
for i in range(len(x)):
v = x[i]
```
which are places to use enumerate instead.
It also caught a couple of cases of:
```python
assert len(x) == len(y)
for i in range(len(x)):
xv = x[i]
yv = y[i]
```
Which should instead be using zip()
```python
for xv, yv in zip(x, y):
...
```
3 years ago
Dylan Baker
4d7031437c
pylint: turn on superflous-parens
...
We have a lot of these. Some of them are harmless, if unidiomatic, such
as `if (condition)`, others are potentially dangerous `assert(...)`, as
`assert(condtion)` works as expected, but `assert(condition, message)`
will result in an assertion that never triggers, as what you're actually
asserting is `bool(tuple[2])`, which will always be true.
3 years ago
Dylan Baker
278942a447
pylint: enable consider-iterating-dictionary
...
This didn't actually catch what it's supposed to, which is cases of:
```python
for x in dict.keys():
y = dict[x]
```
But it did catch one unnecessary use of keys(), and one case where we
were doing something in an inefficient way. I've rewritten:
```python
if name.value in [x.value for x in self.kwargs.keys() if isinstance(x, IdNode)]:
```
as
``python
if any((isinstance(x, IdNode) and name.value == x.value) for x in self.kwargs):
```
Which avoids doing two iterations, one to build the list, and a
second to do a search for name.value in said list, which does a single
short circuiting walk, as any returns as soon as one check returns True.
3 years ago
Jussi Pakkanen
3f380b8e1d
Fix duplicated frameworks in the Xcode backend.
3 years ago
Jussi Pakkanen
85d102bc6e
Fix multiple generators in target in Xcode.
3 years ago
Jussi Pakkanen
267d5385d4
Path special casing for the Xcode backend.
3 years ago
Jussi Pakkanen
12e7b3afcf
Handle .C extension in Xcode.
3 years ago
Dylan Baker
0ca0e6116c
backends: remove unused name parameter from as_meson_exe_cmdline
...
This parameter isn't used, at all, so just remove it
3 years ago
Eli Schwartz
59d4f771d2
editorconfig: add setting to trim trailing whitespace
...
and clean up all outstanding issues
Skip 'test cases/common/141 special characters/meson.build' since it
intentionally uses trailing newlines.
3 years ago
Eli Schwartz
dd31891c1f
more f-strings too complex to be caught by pyupgrade
3 years ago
Eli Schwartz
48ebfa9a99
another pyupgrade pass
4 years ago
Jussi Pakkanen
43f0aa17b7
Add swift executable support in Xcode.
4 years ago
Jussi Pakkanen
e23fd086bf
Remove unnecessary hierarchical layer.
4 years ago
Jussi Pakkanen
b84265052e
Remove top level sources entry as unnecessary.
4 years ago
Jussi Pakkanen
7ceba6388c
Add meson.build files to pbxgroup.
4 years ago
Jussi Pakkanen
818685ec18
Write project info in a tree structure rather than the current flat one.
4 years ago
Jussi Pakkanen
53f6ef3b7b
Xcode: fix project cleaning.
4 years ago
Jussi Pakkanen
1a31882f59
Xcode: make Swift projects work.
4 years ago
Jussi Pakkanen
1cd80985b4
Xcode: add objective C++ flags to plain C++ because Xcode requires it.
4 years ago
Jussi Pakkanen
0e4c358f35
Xcode: add objective C flags to plain C because Xcode requires it.
4 years ago
Jussi Pakkanen
aa2a153afb
Xcode: fix linking to customtargetindex objects.
4 years ago
Jussi Pakkanen
22d0e6dd55
Xcode: even more command line argument expansion.
4 years ago
Jussi Pakkanen
0785ec3317
Xcode: Quote McQuoteface.
4 years ago
Jussi Pakkanen
ee2363dbb7
Xcode: handle CustomTargetIndexes.
4 years ago
Jussi Pakkanen
2a341dd4ec
Xcode: ever more quoting.
4 years ago
Jussi Pakkanen
7fba94997f
Xcode: only add source and build dirs if implicit_include_directories is set.
4 years ago
Jussi Pakkanen
bff85e2a6c
Xcode: do not link shared modules against executables.
4 years ago
Jussi Pakkanen
40fb466513
Xcode: add missing quote character.
4 years ago
Jussi Pakkanen
965f7e18fa
Xcode: fix shell quotings.
4 years ago
Jussi Pakkanen
4881c2cf98
Xcode: skip link language override test.
4 years ago
Jussi Pakkanen
674538d8c9
Xcode: put all include dirs via a property rather than a cmd line arg.
4 years ago
Jussi Pakkanen
b42a5e21d0
Xcode: add target private dir to include path.
4 years ago
Jussi Pakkanen
3f99830f74
Xcode: quote some entries as needed.
4 years ago
Jussi Pakkanen
d116d94f92
Xcode: fix file objects in various places.
4 years ago
Jussi Pakkanen
7803405128
Xcode: fix compiling shared modules.
4 years ago
Jussi Pakkanen
6f76fce904
Xcode: regenerato project file when build conf changes.
4 years ago
Jussi Pakkanen
8943945efe
Xcode: replace all backslashes with eight backslashes. Because obviously.
4 years ago
Jussi Pakkanen
68dda2a241
Xcode: fix generators that take custom targets as inputs.
4 years ago
Jussi Pakkanen
e422e9c634
Xcode: add proper target dependencies to custom targets.
4 years ago
Jussi Pakkanen
126db6de12
Xcode: fix running commands that lie in the build root dir.
4 years ago
Jussi Pakkanen
09d89dfaeb
Xcode: fix custom target chaining.
4 years ago
Jussi Pakkanen
fa947e6d75
Xcode: made custom targets into top level AggregateTargets.
4 years ago
Jussi Pakkanen
cc2a2e8492
Xcode: make the test target depend on build_all target.
4 years ago
Jussi Pakkanen
48e38fbaeb
Xcode: fix custom targets that produce objs and libs.
4 years ago