Closed
Description
Bug summary
Respected community members,
Hi all,
A recent commit has broken AIX internal CI build. The error we get is as follows:
../src/ft2font_wrapper.cpp:114:35: error: 'FT_LOAD_LOAD_BITMAP_METRICS_ONLY' was not declared in this scope; did you mean 'FT_LOAD_BITMAP_METRICS_ONLY'?
114 | #define DECLARE_FLAG(name) name = FT_LOAD_##name
| ^~~~~~~~
../src/ft2font_wrapper.cpp:135:5: note: in expansion of macro 'DECLARE_FLAG'
135 | DECLARE_FLAG(LOAD_BITMAP_METRICS_ONLY),
| ^~~~~~~~~~~~
I guess this is a recent change and as the error says,, we need to make the macro FT_LOAD_BITMAP_METRICS_ONLY. Looking at the code I made the below change and the build break was fixed.
# diff -u src/ft2font_wrapper.cpp_orig src/ft2font_wrapper.cpp
--- src/ft2font_wrapper.cpp_orig 2024-10-24 23:22:49.946878380 -0500
+++ src/ft2font_wrapper.cpp 2024-10-24 23:23:27.346913670 -0500
@@ -132,7 +132,7 @@
DECLARE_FLAG(COMPUTE_METRICS),
#endif
#ifdef FT_LOAD_BITMAP_METRICS_ONLY // backcompat: ft 2.7.1.
- DECLARE_FLAG(LOAD_BITMAP_METRICS_ONLY),
+ DECLARE_FLAG(BITMAP_METRICS_ONLY),
#endif
#ifdef FT_LOAD_NO_SVG // backcompat: ft 2.13.1.
DECLARE_FLAG(LOAD_NO_SVG),
Kindly let me know if this is okay and I can create a pull request.
Code for reproduction
Build matplotlib in AIX using meson.
meson setup build --prefix=$PWD/install_dir -Dsystem-freetype=true
meson compile -C build -j8 --verbose
meson install -C build --no-rebuild
Actual outcome
NA
Expected outcome
NA
Additional information
No response
Operating system
No response
Matplotlib Version
Master branch
Matplotlib Backend
No response
Python version
No response
Jupyter version
No response
Installation
None
Metadata
Metadata
Assignees
Labels
No labels