meson: add patch to fix caching of pkg-config files.
Allows us to use the PKG_CONFIG variable to tell Meson which is the pkg-config to be used to get our native dependencies. We actually could always do that but Meson would cache the variable for the pkg-config file if we used the dependency() call without 'native: true' and after that all future usages of dependency() even with 'native: true' would use the cross-compile one. See this issue from where the patch came from: - https://github.com/mesonbuild/meson/issues/1736
This commit is contained in:
parent
22cb3e693c
commit
d642a5493d
2 changed files with 16 additions and 1 deletions
15
srcpkgs/meson/patches/fix-pkg-config-native-not-found.patch
Normal file
15
srcpkgs/meson/patches/fix-pkg-config-native-not-found.patch
Normal file
|
@ -0,0 +1,15 @@
|
|||
Source: https://github.com/mesonbuild/meson/issues/1736
|
||||
Upstream: Unknown
|
||||
Reason: prevents meson from caching a variable with the value of the cross-compile pkg-config that can be later used to fetch the value of a native pkg-config, fixes problems with finding native: true dependencies.
|
||||
|
||||
--- mesonbuild/dependencies/base.py
|
||||
+++ mesonbuild/dependencies/base.py
|
||||
@@ -448,7 +448,6 @@ class PkgConfigDependency(ExternalDependency):
|
||||
potential_pkgbin = ExternalProgram.from_cross_info(environment.cross_info, 'pkgconfig')
|
||||
if potential_pkgbin.found():
|
||||
self.pkgbin = potential_pkgbin
|
||||
- PkgConfigDependency.class_pkgbin = self.pkgbin
|
||||
else:
|
||||
mlog.debug('Cross pkg-config %s not found.' % potential_pkgbin.name)
|
||||
# Only search for the native pkg-config the first time and
|
||||
<Paste>
|
|
@ -1,7 +1,7 @@
|
|||
# Template file for 'meson'
|
||||
pkgname=meson
|
||||
version=0.47.2
|
||||
revision=1
|
||||
revision=2
|
||||
noarch=yes
|
||||
build_style=python3-module
|
||||
pycompile_module="mesonbuild"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue