aedi: enable creation of freetype cmake modules

This commit is contained in:
alexey.lysiuk 2021-08-02 10:37:01 +03:00
parent 97110d58dc
commit 7c195e5a99
2 changed files with 10 additions and 1 deletions

View file

@ -161,6 +161,16 @@ class FreeTypeTarget(CMakeStaticDependencyTarget):
os.makedirs(bin_path)
shutil.copy(state.patch_path / 'freetype-config', bin_path)
def update_linker_flags(line: str):
link_flags = '-lbrotlicommon -lbrotlidec -lbz2 -lfreetype -lharfbuzz -lpng16 -lz ' \
'-lc++ -framework CoreFoundation -framework CoreGraphics -framework CoreText'
link_var = ' INTERFACE_LINK_LIBRARIES '
return f'{link_var}"{link_flags}"\n' if line.startswith(link_var) else line
cmake_module = state.install_path / 'lib/cmake/freetype/freetype-config.cmake'
self.update_text_file(cmake_module, update_linker_flags)
class FtglTarget(ConfigureMakeStaticDependencyTarget):
def __init__(self, name='ftgl'):

1
deps/.gitignore vendored
View file

@ -41,7 +41,6 @@
# Libraries, tier 2
/brotli/bin/
/freetype/lib/cmake/
/lua/bin/
/lua/man/
/lzma/bin/