From build.log checking for freetype-config... freetype-config checking for x86_64-pc-linux-gnu-pkg-config... (cached) x86_64-pc-linux-gnu-pkg-config checking for x86_64-pc-linux-gnu-icu-config... x86_64-pc-linux-gnu-icu-config checking for x86_64-pc-linux-gnu-pkg-config... (cached) x86_64-pc-linux-gnu-pkg-config checking requested system `kpathsea' library... ok checking requested system `zlib' library... ok checking requested system `libpaper' library... ok checking requested system `libpng' library... ok checking requested system `freetype2' library... failed checking requested system `pixman' library... failed checking requested system `cairo' library... failed checking requested system `gmp' library... failed checking requested system `mpfr' library... failed checking requested system `poppler' library... failed checking requested system `xpdf' library... failed checking requested system `zziplib' library... failed checking requested system `graphite2' library... failed checking requested system `teckit' library... failed checking requested system `icu' library... ok checking requested system `harfbuzz' library... ok configure: error: some requested system libraries failed And from config.log (for freetype2) configure:21852: checking requested system `freetype2' library configure:21868: x86_64-pc-linux-gnu-gcc -o conftest -march=native -O0 -pipe -g -ggdb -I/usr/include/freetype2 -I/storage/strogdon/gentoo-rap/usr/include/libpng16 -Wl,-O1 -Wl,--as-needed conftest.c -L/usr/lib/x86_64-linux-gnu -lfreetype -lz -lpng16 -lz -lpaper -lz -lkpathsea >&5 conftest.c:44:10: fatal error: ft2build.h: No such file or directory 44 | #include <ft2build.h> | ^~~~~~~~~~~~ compilation terminated. It looks like the config step is not looking for the libs in Prefix. pkg-config --cflags freetype2 -I/storage/strogdon/gentoo-rap/usr/include/freetype2 Everything is present.
Created attachment 584006 [details] config.log config.log added
From the attached config.log it would appear that configure finds the host /usr/bin/freetype-config and uses it instead of pkg-config. The output from freetype-config is /usr/bin/freetype-config --cflags -I/usr/include/freetype2 /usr/bin/freetype-config --libs -L/usr/lib/x86_64-linux-gnu -lfreetype -lz which is consistent with the failure. I'm not sure how to neuter this.
The main reason for the failure is that my host has an old version of freetype installed freetype-config --ftversion 2.4.9 Newer versions don't even ship freetype-config. Two solutions I see are: 1) patch texlive-20190410-source/m4/kpse-freetype2-flags.m4 to only use pkg-config. I believe this will require running autoconf. 2) exclude the host from the search path for freetype-config/pkg-config. Prefix installs of freetype will not have freetype-config.
<hat type="TeX team member"> I'd consider this bug invalid, TL upstream has finally added a check for pkg-config presense in the system because freetype-config on its way out. Both works indepedently fine (depending on freetype version installed in the system). There is no reason to patch anything. </hat>
(In reply to Mikle Kolyada from comment #4) > <hat type="TeX team member"> > > I'd consider this bug invalid, TL upstream has finally added a check for > pkg-config presense in the system because freetype-config on its way out. > Both works indepedently fine (depending on freetype version installed in the > system). There is no reason to patch anything. > > </hat> Problem here is that there is a freetype-config available in PATH, which isn't provided by us (Gentoo Prefix). We know there is a pkg-config available here, but it won't be used because freetype-config is tried first. We need a way to force it to try pkg-config only, because we know that's the only thing that's going to return correct results (because it is provided by us).
(In reply to Fabian Groffen from comment #5) > (In reply to Mikle Kolyada from comment #4) > > <hat type="TeX team member"> > > > > I'd consider this bug invalid, TL upstream has finally added a check for > > pkg-config presense in the system because freetype-config on its way out. > > Both works indepedently fine (depending on freetype version installed in the > > system). There is no reason to patch anything. > > > > </hat> > > Problem here is that there is a freetype-config available in PATH, which > isn't provided by us (Gentoo Prefix). We know there is a pkg-config > available here, but it won't be used because freetype-config is tried first. > We need a way to force it to try pkg-config only, because we know that's the > only thing that's going to return correct results (because it is provided by > us). Understood :) Well, the simpliest solution as I see it would be to add `unset FT2_CONFIG` into the ebuild (as it holds the freetype-config path), but I have no prefix installation to test if this would be sufficient or not.
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=19a7e03e9f127f8cddf956292b24c2f0a4df4cc9 commit 19a7e03e9f127f8cddf956292b24c2f0a4df4cc9 Author: Mikle Kolyada <zlogene@gentoo.org> AuthorDate: 2019-07-27 07:44:04 +0000 Commit: Mikle Kolyada <zlogene@gentoo.org> CommitDate: 2019-07-27 07:45:55 +0000 app-text/texlive-core: disable freetype-config Closes: https://bugs.gentoo.org/690094 Package-Manager: Portage-2.3.66, Repoman-2.3.16 Signed-off-by: Mikle Kolyada <zlogene@gentoo.org> app-text/texlive-core/texlive-core-2019-r4.ebuild | 5 +++++ 1 file changed, 5 insertions(+)
Thanks guys!