diff options
author | Lukas Oberhuber <@lukaso> | 2021-11-21 07:58:50 +0100 |
---|---|---|
committer | Werner Lemberg <wl@gnu.org> | 2021-11-21 10:41:53 +0100 |
commit | 896630bed63d42feb246a5781fe7d90e484362a1 (patch) | |
tree | 450d0d7ba103ed61878ce8c734a618412710bc71 | |
parent | a11650d7faf4e91d6ad9aafb1bde5207c2c25124 (diff) | |
download | freetype2-896630bed63d42feb246a5781fe7d90e484362a1.tar.gz |
* meson.build: Fix compatibility version on MacOS.
Fixes #1117.
-rw-r--r-- | meson.build | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/meson.build b/meson.build index 97f309988..74fde432f 100644 --- a/meson.build +++ b/meson.build @@ -237,6 +237,20 @@ endif ft2_deps = [] +# Correct compatibility version for OS x +# +# OSX sets the compatibility_version (aka libtools version) differently from +# the library name. +# +if host_machine.system() == 'darwin' + # Maintain compatibility with autotools on macOS + common_ldflags = [ + '-compatibility_version', ft2_pkgconfig_version.split('.')[0], + '-current_version', ft2_pkgconfig_version + ] +endif + + # Generate `ftoption.h` based on available dependencies. process_header_command = [python_exe, @@ -344,6 +358,7 @@ ft2_lib = library('freetype', dependencies: ft2_deps, install: true, version: ft2_so_version, + link_args: common_ldflags, ) |