Bug 1519308 - Try toolchain-prefixed pkg-config. r=froydnj

When doing cross-compiles for Desktop, system pkg-config is going to be
looking for .pc files for the host, but systems setup for cross-compiles
come with a toolchain-prefixed pkg-config, which we should be looking
for.

Differential Revision: https://phabricator.services.mozilla.com/D16318

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Mike Hommey 2019-01-11 15:54:51 +00:00
Родитель 9f9340299c
Коммит fe50d1eef4
2 изменённых файлов: 7 добавлений и 6 удалений

Просмотреть файл

@ -5,10 +5,10 @@
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
@depends('--enable-compile-environment')
def pkg_config(compile_env):
if compile_env:
return ('pkg-config',)
@depends(toolchain_prefix, when=compile_environment)
def pkg_config(prefixes):
return tuple('{}pkg-config'.format(p)
for p in (prefixes or ()) + ('',))
pkg_config = check_prog('PKG_CONFIG', pkg_config, allow_missing=True)

Просмотреть файл

@ -123,13 +123,14 @@ js_option(env='MOZ_PGO', help='Build with profile guided optimizations')
set_config('MOZ_PGO', depends('MOZ_PGO')(lambda x: bool(x)))
include('build/moz.configure/toolchain.configure',
when='--enable-compile-environment')
include('build/moz.configure/pkg.configure')
# Make this assignment here rather than in pkg.configure to avoid
# requiring this file in unit tests.
add_old_configure_assignment('PKG_CONFIG', pkg_config)
include('build/moz.configure/toolchain.configure',
when='--enable-compile-environment')
include('build/moz.configure/memory.configure',
when='--enable-compile-environment')
include('build/moz.configure/headers.configure',