Commit Graph

72 Commits

Author SHA1 Message Date
Wolfgang Stöggl f037e7ef45 Fix typos found by codespell
- Typos were found by codespell v1.16.0
2019-11-06 09:55:30 -05:00
Daniel Mensinger 80ec5e9d28 Fix all flake8 warnings 2019-10-20 17:44:43 +03:00
Matt Turner 20519a0e1a envconfig: Add Alpha CPU family 2019-10-15 21:47:58 +03:00
Nathan Rossi 2dd5e695c7 envconfig: Add MicroBlaze CPU family
Add the CPU family for the MicroBlaze processor.

Signed-off-by: Nathan Rossi <nathan@nathanrossi.com>
2019-09-26 20:28:42 +03:00
Aleksey Gurtovoy 75daed27bc mesonlib.split_args/quote_arg/join_args 2019-09-05 23:42:47 +03:00
Dylan Baker fe645a0a9e envconfig: make MachineInfo.is_windows and is_cygwin match mesonlib
The mesonlib versions are slightly more specific in what they accept.
2019-08-27 21:07:12 +03:00
Dylan Baker d3a7537346 envconfig: Add missing MachineInfo is_<os> methods
mesonlib defines is_sunos, is_dragonflybsd, and is_freebsd, which
MachineInfo does not. This should be corrected.
2019-08-27 21:07:12 +03:00
nia e085aa089f NetBSD detection in envconfig.MachineInfo 2019-08-23 13:10:25 -07:00
Jussi Pakkanen f41bdae368 Add basic Webassembly support via Emscripten. 2019-08-05 19:31:32 +03:00
Michael Hirsch, Ph.D 324c5b9aae check that compiler name is not blank or empty
pep8
2019-07-06 00:28:58 +03:00
Marvin Scholz 0bf5c27b64 env: Do not return empty tool env vars
A compiler or other tool with an empty string as name does not make
sense as it anyway can not be used and causes a failure later in
parse_entry.

Fix #5451
2019-07-05 20:58:33 +03:00
Roman Shpuntov 3b17344b11 tvOS: added support AppleTVOS 2019-06-13 21:31:03 +03:00
John Ericson 957d8e051c Make `PerMachine` and `MachineChoice` have just `build` and `host`
Meson itself *almost* only cares about the build and host platforms. The
exception is it takes a `target_machine` in the cross file and exposes
it to the user; but it doesn't do anything else with it. It's therefore
overkill to put target in `PerMachine` and `MachineChoice`. Instead, we
make a `PerThreeMachine` only for the machine infos.

Additionally fix a few other things that were bugging me in the process:

 - Get rid of `MachineInfos` class. Since `envconfig.py` was created, it
   has no methods that couldn't just got on `PerMachine`

 - Make `default_missing` and `miss_defaulting` work functionally. That
   means we can just locally bind rather than bind as class vars the
   "unfrozen" configuration. This helps prevent bugs where one forgets
   to freeze a configuration.
2019-05-16 00:27:57 +03:00
Ross Burton ae9a6417fe envconfig: mingw is also Windows
Also change the same idiom for Darwin to use a set().
2019-05-02 14:03:08 -07:00
Dylan Baker edb1229a48 mesonlib: Make a few type annotations strings
Mypy know what to do with these and isn't confused, but some versions of
python 3.5 (at least 3.5.2) can't handle these annotations. By making
them strings the python interpreter wont try to evaluate them.

Fixes #5326
2019-05-02 23:38:36 +03:00
John Ericson 4c2617a9c6 Add some type annotations and fix lints
Some things, like `method[...](...)` or `x: ... = ...` python 3.5
doesn't support, so I made a comment instead with the intention that it
can someday be made into a real annotation.
2019-05-02 10:58:23 -07:00
Dylan Baker 205cf95f99 envconfig: Add type annotations 2019-04-22 13:49:50 -07:00
Dylan Baker b8ec23b69d envconfig: simplify exception handling.
Currently this takes a return value, and in the error case sets it,
then has a separate if to hanle that. Instead just set the return
value in the error handler.
2019-04-22 13:49:50 -07:00
Ross Burton c6abca289b envconfig: remove unused parse_datafile()
The cross-file cleanup meant this function is no longer used, so remove it.
2019-03-20 20:55:32 +02:00
Dylan Baker 914056f68a envconfig: Store whether the cpu_familiy is 64 bit
We'll need this in the llvm-config logic to determine the right
llvm-config to call on Fedora 30+, but this feels like the sort of
information that might be useful elsewhere. This does not expose this
information as part of the public API, it's only accessible at the
python layer.
2019-03-14 23:35:26 +02:00
John Ericson c2db7a9cee Sync up initialization logic with Properties and BinaryTable
1. They (and the others) all use PerMachineDefaultable. It's not the
    best class, but consistency come first. (It and all of them can be
    improved accross the board later.)

 2. They use `None` as the default argument so as not to mutate what's
    effectively a global variables. (Thanks @dcbaker!)

 3. They have a `fallback` field to centralize authority on when
    environment variables should be consulted.
2019-02-27 13:10:16 -08:00
John Ericson 2622e9ec32 Move some configuration classes out of environment.py
First of all, I'd like compilers and other modules that environment.py
currently imports to be able to take these without creating
hard-to-follow module cycles.

Second of all, environment.py's exact purpose seems a bit obscured.
Splitting the data types (and basic pure functions) from the more
complex logic that infers that data seems like a good way to separate
concerns.
2019-02-27 13:10:16 -08:00