summaryrefslogtreecommitdiff
path: root/mesonbuild/build.py
Commit message (Collapse)AuthorAgeFilesLines
...
* build: Fix type signature of rich comparison dundersDylan Baker2019-12-051-4/+12
| | | | | | | | | | | | | There are three problems: 1) Dunders like `__lt__` and `__gt__` don't return bool, they return either a bool or the NotImplemented singleton to signal that they don't know how to be compared. 2) The don't take type object, the take `typing.Any` 3) They need to return NotImplemented if the comparison is not implemented, this allows python to try the inverse dunder from the other object. If that object returns NotImplemented as well a TypeError is raised.
* lgtm: fix Incomplete orderingDaniel Mensinger2019-12-051-9/+12
|
* lgtm: fix Mismatch between signature and use of an overridden methodDaniel Mensinger2019-12-051-3/+6
| | | | | by renaming process_kwargs to process_kwargs_base for the base target class.
* lgtm: fix format string numberingDaniel Mensinger2019-12-051-1/+1
|
* improve error message when old version detectedtaz-0072019-11-301-1/+2
| | | Be more explicit about the --wipe command requiring to be executed from the source dir.
* Fix link_whole with a custom targetXavier Claessens2019-11-251-1/+4
| | | | | | | | t.pic won't be defined. We can only hope it has been built with -fPIC. Linker will complain otherwise any way. t.extract_all_objects_recurse() won't be defined. We could support this case by extracting the archive somewhere and pick object files.
* Store run target names in build.Jussi Pakkanen2019-11-101-0/+1
| | | | | This way we can easily check that we only provide builtin targets such as clang-format if the user has not provided their own.
* Fix *.pdb files missing in meson introspect --installed outputJakub Adam2019-10-091-1/+33
| | | | | On Windows, make sure the introspect command lists all Program database (PDB) files containing debugging information that Meson will install.
* Use include_type instead of is_systemDaniel Mensinger2019-10-031-4/+7
|
* Also add support for declare_dependency objectsDaniel Mensinger2019-10-031-1/+3
|
* use getters for dependency accessDaniel Mensinger2019-10-031-3/+3
|
* Recursively include all objects from uninstalled static librariesXavier Claessens2019-10-011-1/+8
|
* Do not promote to link_whole when an internal library links to anotherXavier Claessens2019-10-011-1/+1
|
* pkgconfig: Include dependencies of uninstalled static librariesXavier Claessens2019-10-011-17/+10
|
* pkgconfig: Do not include uninstalled static librariesXavier Claessens2019-10-011-3/+7
|
* Fix link_with of a static library with an uninstalled static libraryXavier Claessens2019-10-011-0/+7
|
* Fix link_whole of static librariesXavier Claessens2019-10-011-1/+9
|
* CUDA support on WindowsAleksey Gurtovoy2019-09-241-1/+1
|
* Merge pull request #5681 from dcbaker/dynamic-linker-splitJussi Pakkanen2019-08-201-3/+7
|\ | | | | split dynamic linker representations from compilers
| * compilers: Dispatch to dynamic linker classDylan Baker2019-08-141-3/+7
| | | | | | | | | | Most of the cuda code is from Olexa Bilaniuk. Most of the PGI code is from Michael Hirsc
* | Make .extract_objects() work correctly as an input to custom_targetRachel Mant2019-08-171-5/+14
|/
* Add basic Webassembly support via Emscripten.Jussi Pakkanen2019-08-051-0/+2
|
* Accept vs_module_defs for modulesMarc-André Lureau2019-07-171-1/+1
| | | | | | Like shared libraries, modules may have vs_module_defs. Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
* Add alias_target() functionXavier Claessens2019-07-101-0/+4
|
* sanitycheckc: avoid linking sanitycheckc when cross compilingCody Schafer2019-06-271-1/+1
|
* tvOS: added support AppleTVOSRoman Shpuntov2019-06-131-1/+1
|
* Add some type annotationsJohn Ericson2019-06-091-7/+7
| | | | | | 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.
* Purge `is_cross` and friends without changing user interfacesJohn Ericson2019-06-091-80/+77
| | | | | | | | | | | | In most cases instead pass `for_machine`, the name of the relevant machines (what compilers target, what targets run on, etc). This allows us to use the cross code path in the native case, deduplicating the code. As one can see, environment got bigger as more information is kept structured there, while ninjabackend got a smaller. Overall a few amount of lines were added, but the hope is what's added is a lot simpler than what's removed.
* Use `env.machines.*` to avoid some `is_cross`John Ericson2019-06-091-10/+10
| | | | | This is a small example of the `is_cross` removal the that abstraction enables.
* Generators can have extra target dependencies. Closes #4131.Jussi Pakkanen2019-05-201-0/+7
|
* Remove compiler data from build objectJon Turney2019-05-201-7/+0
| | | | | The actual data is in Coredata (which is serialized) and we just held a reference in Build for (in)convenience.
* build: add a few annotationsDylan Baker2019-05-141-4/+4
| | | | As needed by mtest
* build: TestSetup doesn't take keyword argumentsDylan Baker2019-05-141-1/+3
| | | | | | | | This function is currently setup with keyword arguments defaulting to None. However, it is never called without passing all of it's arguments explicitly, and only one of it's arguments would actually be valid as None. So just drop that, and make them all positional. And annotate them.
* build: Treat ICL like MSVC in regards to standard lib linkingDylan Baker2019-05-131-1/+1
|
* per-target manual specification of link_languageMichael Hirsch, Ph.D2019-05-021-6/+17
|
* Merge pull request #5161 from TheQwertiest/feature/custom_target_linkJussi Pakkanen2019-05-021-6/+26
|\ | | | | Can link against custom_target[i]
| * Cleaned up `isinstance` usageTheQwertiest2019-04-291-5/+5
| |
| * Use parent `custom_target` for dependency handling (for consistency and ↵TheQwertiest2019-04-291-1/+1
| | | | | | | | future-proofing)
| * Added custom_target[i] support for link_with and link_wholeTheQwertiest2019-04-291-6/+26
| |
* | Add some type annotations and fix lintsJohn Ericson2019-05-021-2/+2
|/ | | | | | 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.
* Don't use mutable types as default argumentsDylan Baker2019-04-231-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | This isn't safe given the way python implements default arguments. Basically python store a reference to the instance it was passed, and then if that argument is not provided it uses the default. That means that two calls to the same function get the same instance, if one of them mutates that instance every subsequent call that gets the default will receive the mutated instance. The idiom to this in python is to use None and replace the None, def in(value: str, container: Optional[List[str]]) -> boolean: return src in (container or []) if there is no chance of mutation it's less code to use or and take advantage of None being falsy. If you may want to mutate the value passed in you need a ternary (this example is stupid): def add(value: str, container: Optional[List[str]]) -> None: container = container if container is not None else [] container.append(value) I've used or everywhere I'm sure that the value will not be mutated by the function and erred toward caution by using ternaries for the rest.
* generator: add dependency on generator in source treePaolo Bonzini2019-04-161-2/+10
| | | | | | | | | | | | | | | | | If find_program() returns a file from the source directory, anything that uses it should add the file to the dependencies, so that they are rebuilt whenever the script changes. Generator is not doing that. While at it, I am doing two related fixes: - Generator is not checking whther the generator actually was found, resulting in a Python error involving NoneType if it isn't. To minimize backwards compatibility issues, I am only raising the error when g.process() is acutally called. - the error message for custom_target with a nonexisting program erroneously mention a not-found external program "nonexistingprogram". The new error is similar to the one I am adding for generators.
* interpreter: Warn when environment() ops are overridenNirbheek Chauhan2019-04-131-0/+9
| | | | | | | | Warn when someone tries to use append() or prepend() on an env var which already has an operation set on it. People seem to think that multiple append/prepend operations stack, but they don't. Closes https://github.com/mesonbuild/meson/issues/5087
* dependencies: Add ext_deps to all dependenciesDylan Baker2019-04-051-0/+1
| | | | | | | I'll be using this later, but it seems useful to allow dependencies to that have special handlers to declare that they depend on other dependencies. This should allow us to stop treating threads special internally and just make it a normal dependency.
* Merge pull request #5103 from mesonbuild/linkcustomJussi Pakkanen2019-04-011-3/+28
|\ | | | | Can link against custom targets
| * Support link_whole with custom targets.Jussi Pakkanen2019-03-281-2/+7
| |
| * Win fixes.Jussi Pakkanen2019-03-191-0/+3
| |
| * Can link against custom targets. Closes #4908.Jussi Pakkanen2019-03-181-1/+18
| |
* | Better error message when PCH argument is not a string.Jussi Pakkanen2019-03-241-0/+2
| |
* | Fix setup so test suite runs with rustc + MSVC. Closes: 5099Jussi Pakkanen2019-03-241-1/+10
|/