Just detect lrelease as done with other Qt tools.
Uses -version instead of -v to probe version since lrelease don't
support it.
Signed-off-by: Alexis Jeandet <alexis.jeandet@member.fsf.org>
BOOST_LIBS could become outdated in future versions, which would result
in dependency('boost', modules : [ 'foo' ], required : false) to fail,
although required was set to false. Therefore turn the exception into
log_fail(). If required was set to true, this will still be caught since
is_found remains False.
This also improves logging by printing all invalid module names instead
of only the first one.
f.ex when you don't have the llvm-static package installed, the error
message when generating libs is cryptic and uninformative since we
discard stderr.
Sometimes pkg-config can decide that the libdir is a system library dir
and must not be included in the output because that would mess up the
library search order for pkg-config libraries that must be sourced from
a non-system prefix.
However, when we're doing manual searching, we always want to see the
library directory even if it's the system path, otherwise we can't do
manual searching at all.
Escaping spaces with '\ ' is the only way that works with both
pkg-config and pkgconf, so quote that way and unquote inside Meson.
This should work on all platforms.
Also fix the unit test to do the same.
https://github.com/pkgconf/pkgconf/issues/153
When `static: true` is passed to dependency(), we parse the pkg-config
output and manually search for `-lfoo`, etc in the library paths
gathered from `-Lbar` arguments in the output.
If there are no `-L` arguments in the output, the behaviour is the
same as before. If there are `-L` arguments and we can't find a static
library, we will error out.
We can now specify the library type we want to search for, and whether
we want to prefer static libraries over shared ones or the other way
around. This functionality is not exposed to build files yet.
LLVM >= 3.9 provides an llvm-config that has a sane mechanism for
selecting static vs dynamic linking. LLVM < 3.9 (but >= 3.5) not so
much. For those older LLVM versions, llvm-config will always provide
arguments for statically linking LLVM, even if there is a library for
dynamic linking.
Fixes#2442
PkgConfig automatically removes -L paths from libdirs if the -L points
to a system path. It knows what these paths are by taking this as a
configure option at build time, which the distro maintainers set
appropriately and everything works. This allows one to have two
versions of a package installed, a system and non system, and then
override PKG_CONFIG_PATH to use the non system version, and everything
just works. For non-pkgconfig dependencies (such as LLVM) meson needs to
strip these themselves to avoid breaking the above use case.
The new implementation will correctly pick boost from 3 possible
locations on windows and two locations on posix compatible OSs.
The new search algorithm also differentiates between debug and
release builds of Boost and multi or single threading builds.
It was also decided to map "Meson modules" to Boost software libraries
and not Boost modules since it there are a lot of options regarding
linking. Some modules can even be used either as headers-only or with
dynamic linking.
This commit also fixes a bug that prevented header-only use on Windows.
Fixes: #2274#2239#1803#669
This allows the logic in a meson.build file to be simplified (ie, some
dependencies can add the same module requirements) but meson will only
check for them once. Since set is inherently unordered, use sorted to
make the output deterministic.
* add support for cups dependencies
libcups has its own cups-config tool rather than using pkg-config.
This adds support for cups-config, based on pcap-config and
sdl2-config implementations.
This change also includes the unit test case and documentation for
cups dependency object implementation, and libcups2 dep to CI image.
Libpcap has its own pcap-config tool rather than using pkg-config. Add
support for pcap-config, based on the existing implementation of
sdl2-config that is there already.
We prefer pkg-config files, though only OpenMPI supplies them.
Otherwise, check environment variables and search for wrappers and ask
them for what to do.
Fix an error in the windows vulkan_sdk library finding.
Also don't fail the vulkan test only because no vulkan
driver is installed (should fix the travis error).
Rework the vulkan module:
- adopt the VULKAN_SDK paths for its linux version
- add sanity tests for the VULKAN_SDK path
- add guessing as last fallback, needed on linux systems
on which no vulkan pkgconfig is installed [ubuntu atm]
- restructure exception handling/branching
Not tested on windows yet.