Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
envconfig: add pkg_config_libdir property
In order to unify the use of sysroot in the cross-file, the pkg_config_libdir can now be passed directly in the file.
- Loading branch information
Stéphane Cerveau
committed
Jan 15, 2020
1 parent
71bbcc7
commit e9636cf
Showing
8 changed files
with
69 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
|
||
[properties] | ||
pkg_config_libdir = ['@pkg_config_libdir@'] | ||
|
||
[binaries] | ||
pkgconfig = 'pkg-config' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
project('crosspkgconfiglibdir') | ||
|
||
if get_option('generate') | ||
conf_data = configuration_data() | ||
conf_data.set('pkg_config_libdir', meson.current_source_dir()) | ||
|
||
configure_file(input: 'crossfile.in', | ||
output: 'crossfile', | ||
configuration: conf_data) | ||
message('Written cross file') | ||
else | ||
assert(meson.is_cross_build(), 'not setup as cross build') | ||
build = dependency('zlib', method : 'pkg-config', native : true) | ||
host = dependency('zlib', method : 'pkg-config', native : false) | ||
assert(build.version() != '9.9.99', 'wrong version for build machine dependency') | ||
assert(host.version() == '9.9.99', 'wrong version for host machine dependency') | ||
endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
option('generate', type : 'boolean', value : false) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
prefix=/usr | ||
exec_prefix=${prefix} | ||
libdir=${prefix}/lib/x86_64-linux-gnu | ||
sharedlibdir=${libdir} | ||
includedir=${prefix}/include | ||
|
||
Name: zlib | ||
Description: zlib compression library | ||
Version: 9.9.99 | ||
|
||
Requires: | ||
Libs: -L${libdir} -L${sharedlibdir} -lz | ||
Cflags: -I${includedir} |