summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHeiko Becker <heirecka@exherbo.org>2021-07-27 23:30:16 +0200
committerWerner Lemberg <wl@gnu.org>2021-07-29 08:33:56 +0200
commit47b1a541cb1943d85da3976b93f9a5ed490288e2 (patch)
tree77dfa8ffe3786e4cc479001576d570517899b41c
parentd2367abac0859b09d8defe034dd6ebbc0391a51a (diff)
downloadfreetype2-47b1a541cb1943d85da3976b93f9a5ed490288e2.tar.gz
* meson.build: Honor `--includedir` instead of hard-coding 'include'.
Signed-off-by: Heiko Becker <heirecka@exherbo.org>
-rw-r--r--meson.build13
1 files changed, 7 insertions, 6 deletions
diff --git a/meson.build b/meson.build
index 0eb780bfd..5bfa188a8 100644
--- a/meson.build
+++ b/meson.build
@@ -49,6 +49,7 @@ ft2_pkgconfig_version = run_command(python_exe,
ft2_includes = include_directories('include')
+freetype_includedir = join_paths(get_option('includedir'), 'freetype2')
# Generate a custom `ftmodule.h` version based on the content of
# `modules.cfg`.
@@ -59,7 +60,7 @@ ftmodule_h = custom_target('ftmodule.h',
command: [python_exe, files('builds/meson/parse_modules_cfg.py'),
'--format=ftmodule.h', '@INPUT@', '--output', '@OUTPUT@'],
install: true,
- install_dir: 'include/freetype2/freetype/config',
+ install_dir: join_paths(freetype_includedir, 'freetype/config'),
)
ft2_sources = [ftmodule_h]
@@ -303,7 +304,7 @@ ftoption_h = custom_target('ftoption.h',
output: 'ftoption.h',
command: ftoption_command,
install: true,
- install_dir: 'include/freetype2/freetype/config',
+ install_dir: join_paths(freetype_includedir, 'freetype/config'),
)
ft2_sources += ftoption_h
ft2_defines += ['-DFT_CONFIG_OPTIONS_H=<ftoption.h>']
@@ -330,7 +331,7 @@ if use_unix_ftsystem_c
output: 'ftconfig.h',
command: ftconfig_command,
install: true,
- install_dir: 'include/freetype2/freetype/config',
+ install_dir: join_paths(freetype_includedir, 'freetype/config'),
)
ft2_sources += ftconfig_h
ft2_defines += ['-DFT_CONFIG_CONFIG_H=<ftconfig.h>']
@@ -361,11 +362,11 @@ meson.override_dependency('freetype2', freetype_dep)
# i.e., the subdir value seems to be ignored, contrary to examples in the
# Meson documentation.
install_headers('include/ft2build.h',
- install_dir: 'include/freetype2')
+ install_dir: freetype_includedir)
install_headers(ft2_public_headers,
- install_dir: 'include/freetype2/freetype')
+ install_dir: join_paths(freetype_includedir, 'freetype'))
install_headers(ft2_config_headers,
- install_dir: 'include/freetype2/freetype/config')
+ install_dir: join_paths(freetype_includedir, 'freetype/config'))
pkgconfig = import('pkgconfig')