summaryrefslogtreecommitdiff
path: root/mesonbuild/dependencies/dev.py
AgeCommit message (Collapse)Author
2021-11-15dependencies/zlib: Add system zlib method for androidDudemanguy
The same method that the BSDs use should also work for android. Also update the tests and docs where appropriate.
2021-10-27fix various flake8 whitespace errorsEli Schwartz
2021-09-25dependencies: Add JDK system dependency for SolarisAlan Coopersmith
Handle is_sunos() machines in __machine_info_to_platform_include_dir
2021-07-13dependencies: drop Dependency.methods and Dependency.get_methods()Dylan Baker
Both of these are artifacts of the time before Dependency Factories, when a dependency that could be discovered multiple ways did ugly stuff like finding a specific dependency, then replacing it's own attributes with that dependency's attributes. We don't have cases of that left in the tree, so let's get rid of this code too
2021-07-04dependencies: Deterministic LLVM compile and link arg ordering (#8959)kira78
* dependencies: Deterministic LLVM compile and link arg ordering In LLVMDependencyConfigTool, the members compile_args and required_modules are either converted to or stored as sets, which do not have a stable ordering. This results in nondeterministic builds, particularly with required_modules causing the order in which the LLVM libraries are linked in to the output binaries to change across independent builds. As any guarantee about ordering for compile_args is lost by being converted from a list to a set and back, and the modules added to required_modules was even already sorted once, sort both when converting them to lists. * Use mesonlib.OrderedSet instead of sorting the sets. Co-authored-by: Kaelyn Takata <kaelyn.alexi@protonmail.com>
2021-06-25Split compiler detection from EnvironmentDaniel Mensinger
This moves all the compiler detection logic into the new compilers.detect module. This dramatically reduces the size and complexity of Environment.
2021-06-17move base class for system dependencies into base.pyEli Schwartz
In accordance with review comments; it's small enough this seems fitting.
2021-06-14dependencies: Use the SystemDependencyDylan Baker
This fixes these dependencies, which currently return the name of the dependency as the type. Fixes #8877
2021-06-09compilers: Fix missing functions in Compiler base classDaniel Mensinger
2021-06-09typing: Fully annotate dependenciesDaniel Mensinger
2021-06-03deps: Split dependencies.baseDaniel Mensinger
Split the Factory and dependency classes out of the base.py script to improve maintainability.
2021-05-28dependencies/zlib: System Dependency needs a clib_compiler on windowsDylan Baker
Otherwise it'll except when it tries to get an attribute from None that doesn't exist.
2021-04-12dependency: Add JDK system dependencyTristan Partin
The JDK system dependency is important for detecting JDK include paths that may be useful when developing a JNI interface.
2021-03-04mass rewrite of string formatting to use f-strings everywhereEli Schwartz
performed by running "pyupgrade --py36-plus" and committing the results
2020-10-22depenencies/llvm: Handle llvm-config --shared-mode failing (#7379)Dylan Baker
* depenencies/llvm: Handle llvm-config --shared-mode failing Fixes: #7371 Fixes: #7878 * test cases/llvm: Refactor to use test.json Instead of trying to cover everything internally
2020-09-29dependencies/zlib: Fix header detectionDylan Baker
has_header returns a tuple of (found: bool, cached: bool), so `if has_header` will always return true because the tuple is non-empty. We need to check if the found value is true or not.
2020-04-12Fix VS Intellisense for projects which depend on LLVM found via CMake.Jesse Natalie
2020-04-10Log when ignoring LLVM because dynamic was requestedJesse Natalie
Without this, there's tons of log output about finding LLVM, followed by "couldn't find LLVM."
2020-03-19cmake: Add find_package COMPONETS supportDaniel Mensinger
2020-01-31dependencies: Add a zlib system dependency for windowsDylan Baker
2020-01-31dependencies: Add system zlib method for freebsd and dragonflybsdDylan Baker
I've tested this on FreeBSD, and dragonfly's userland is close enough I'm willing to call it good without testing. OpenBSD and NetBSD also have a zlib in their base configurations, but I'm not confident enough to enable those without testing.
2020-01-31dependencies: Add a zlib system dependency for macOSDylan Baker
This comes pre-installed, but currently we don't have a way to detect it without relying on pkg-config or cmake. This is only valid with the apple clang-based compilers, as they do some special magic to get headers.
2020-01-30Small cleanups for the LLVM dependency class (#6548)Dylan Baker
2020-01-29dependencies: Rename _add_sub_dependency2 to _add_sub_dependencyDylan Baker
Since the original _add_sub_dependency is no longer in use.
2020-01-29dependencies: Use a DependencyFactory for threadsDylan Baker
This lets us make a number of uses of threads safer, because we can use the threads_factory instead of the ThreadDependency
2020-01-29dependencies: Use DependencyFactory for gmockDylan Baker
2020-01-29dependencies: Use a DependencyFactory for gtestDylan Baker
2020-01-29dependencies: Use a DependencyFactory for LLVMDylan Baker
2020-01-29dependencies: Make Dependency initializer signatures matchDylan Baker
Currently PkgConfig takes language as a keyword parameter in position 3, while the others take it as positional in position 2. Because most dependencies don't actually set a language (they use C style linking), using a positional argument makes more sense. ExtraFrameworkDependencies is even more different, and duplicates some arguments from the base ExternalDependency class. For later changes I'm planning to make having all of the dependencies use the same signature is really, really helpful.
2020-01-29dependencies/base: Split process_method_kw out of DependencyDylan Baker
I want to use this in a new class as well, that doesn't descend from Dependency.
2020-01-26cmake: Refactor CMakeExecutor and CMakeTraceParserDaniel Mensinger
This moves most of the execution code from the CMakeInterpreter into CMakeExecutor. Also, CMakeTraceParser is now responsible for determining the trace cmd arguments.
2020-01-08types: import typing as T (fixes #6333)Daniel Mensinger
2019-12-05lgtm: fix Multiple calls to __init__Daniel Mensinger
Some slight refactoring for the dependency classes and I switched the elbrus compiler to the GnuLikeCompiler. This is also the correct use according to the documentation of GnuLikeCompiler.
2019-11-06Fix typos found by codespellWolfgang Stöggl
- Typos were found by codespell v1.16.0
2019-09-29Move the list of LLVM version suffixes to a common placeTing-Wei Lan
Both scan-build and llvm-config need the same list of LLVM version suffixes. It is better to keep the list at a common place instead of having several copies in different files, which is likely to become out-of-sync when the list is updated.
2019-07-02dependencies/dev: Switch order of llvm dependency findersDylan Baker
Cmake ignores shared vs dynamic linking, and always returns static. This went unnoticed, but results in regresssions for mesa. We need to fix cmake, but with 0.51.1 due out shortly switching the order provides a quick fix to restore expected functionality seems acceptable. Fixes #5568
2019-06-12cmake: Move parsing the CMake trace into the CMake moduleDaniel Mensinger
2019-06-09Purge `is_cross` and friends without changing user interfacesJohn Ericson
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.
2019-05-27dependencies/llvm: Fixup bad output from llvm-config on windowsDylan Baker
It turns out that llvm-config on windows can return such wonderful output as `-LIBDIR:c:\\... c:\\abslute\\path\\to\\lib.lib`, which was all fine and dandy when we were blindly passing it through, GCC/MinGW ignored it and MSVC understood it meant `/LIBDIR:`; however, after we added some code to validate linker arguments, and we have some code before the validation that tries to remove posix style -L arguments, resulting in IBDIR:..., which doesn't validate. This patch fixes up the output of llvm-config so that -LIBDIR: is replaced by the the link libdir argument of the compiler, via the compiler/linker method for getting that. Fixes #5419
2019-05-03cmake: Fixed new thread dependencyDaniel Mensinger
2019-05-03cmake: LLVM better modules handlingDaniel Mensinger
2019-05-03cmake: revert module name mappingDaniel Mensinger
2019-05-03cmake: minor code fixesDaniel Mensinger
2019-05-03CMake: optional modules supportDaniel Mensinger
2019-05-03LLVM: Added CMake backendDaniel Mensinger
2019-05-03LLVM dependency refactoringDaniel Mensinger
2019-05-02dependencies: Use the _add_sub_dependencyDylan Baker
2019-04-05dependencies/dev: Use ext_deps for GTest in GMockDylan Baker
Rather than assigning the gtest variables to gmock, just set gtest as a sub dependency.
2019-04-05dependencies/misc: don't special case threadsDylan Baker
Instad of having special casing of threads in the backends and everywehre else, do what we did for openmp, create a real dependency. Then make use of the fact that dependencies can now have sub dependencies to add threads.
2019-03-14dependencies/llvm: Add support for fedora 30Dylan Baker
In Fedora 30 the llvm-config binary has the number of bits in the isa added as a suffic to the name llvm-config-64 or llvm-config-32, and no naked llvm-config binary is provided. This commit moves the list of llvm-config binaries to the constructor so that we can modify the list on a per-instance basis, and adds the new Feodra names. Fixes #5059