diff options
author | Emmanuele Bassi <ebassi@gnome.org> | 2018-08-30 16:14:34 +0100 |
---|---|---|
committer | Emmanuele Bassi <ebassi@gnome.org> | 2018-08-30 16:16:36 +0100 |
commit | 453c85215cb7f562866b0daef6a9b24a6957bf73 (patch) | |
tree | e04dc50d82c7dd77fad9ff1f43a391b2460b019c /meson.build | |
parent | 2b93691f331115b7a18747163a5ec38e99392788 (diff) | |
download | pango-453c85215cb7f562866b0daef6a9b24a6957bf73.tar.gz |
build: Generate pkg-config files
Instead of using templates, ask Meson to generate the pkgconfig files
for us. This ensures that the generated files are:
- always valid
- always up to date with the build
- only built when needed without convoluted checks
Diffstat (limited to 'meson.build')
-rw-r--r-- | meson.build | 40 |
1 files changed, 1 insertions, 39 deletions
diff --git a/meson.build b/meson.build index aded99ce..c877d83f 100644 --- a/meson.build +++ b/meson.build @@ -456,46 +456,8 @@ if cairo_dep.found() endif endif -# Compat variables for pkgconfig -pkgconf = configuration_data() -pkgconf.set('prefix', pango_prefix) -pkgconf.set('exec_prefix', pango_prefix) -pkgconf.set('libdir', pango_libdir) -pkgconf.set('includedir', pango_includedir) -pkgconf.set('VERSION', meson.project_version()) -pkgconf.set('PANGO_API_VERSION', pango_api_version) -pkgconf.set('PKGCONFIG_CAIRO_REQUIRES', pangocairo_requires) -pkgconf.set('CAIRO_PC', cairo_pc) -pkgconf.set('CAIRO_LIB', cairo_lib) -pkgconf.set('FREETYPE2_PC', freetype2_pc) -pkgconf.set('FREETYPE2_LIB', freetype2_lib) -pkgconf.set('FONTCONFIG_PC', fontconfig_pc) -pkgconf.set('FONTCONFIG_LIB', fontconfig_lib) -pkgconf.set('HARFBUZZ_PC', harfbuzz_pc) -pkgconf.set('HARFBUZZ_LIB', harfbuzz_lib) - -pkgconf_files = [ - [ 'pango.pc' ], - [ 'pangowin32.pc', host_system == 'windows' ], - [ 'pangoft2.pc', build_pangoft2 ], - [ 'pangoxft.pc', xft_dep.found() ], - [ 'pangocairo.pc', cairo_dep.found() ], -] - -foreach pkg: pkgconf_files - pkg_name = pkg[0] - pkg_enabled = pkg.get(1, true) - - if pkg_enabled - configure_file(input: pkg_name + '.in', - output: pkg_name, - configuration: pkgconf, - install: true, - install_dir: join_paths(pango_libdir, 'pkgconfig')) - endif -endforeach - gnome = import('gnome') +pkgconfig = import('pkgconfig') # Internal configuration header configure_file(output: 'config.h', configuration: pango_conf) |