From 66ee42d194bef1d045918c54cc81a9cb186bd440 Mon Sep 17 00:00:00 2001 From: Silviu Tantos Date: Fri, 16 May 2014 12:10:01 +0200 Subject: [PATCH] Fix for bug #3029. The FreeType class does not override the ``get_extension`` method, by default this method will return None. https://github.com/matplotlib/matplotlib/blob/6cf6063c7a3037d52545b2b7268623d33da0ecdd/setupext.py#L387 When calling the ``_check_for_pkg_config`` method a new extension will be created that what won't contain the original flags added by the ``add_flags`` method. https://github.com/matplotlib/matplotlib/blob/6cf6063c7a3037d52545b2b7268623d33da0ecdd/setupext.py#L438 --- setupext.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/setupext.py b/setupext.py index fcb053458268..4a6eeec813d1 100644 --- a/setupext.py +++ b/setupext.py @@ -917,6 +917,10 @@ def add_flags(self, ext): default_libraries=['freetype', 'z'], alt_exec='freetype-config') + def get_extension(self): + ext = make_extension('freetype2', []) + self.add_flags(ext) + return ext class FT2Font(SetupPackage): name = 'ft2font'