NetBSD Problem Report #53614

From  Mon Sep 17 22:00:30 2018
Return-Path: <>
Received: from ( [])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(Client CN "", Issuer " CA" (not verified))
	by (Postfix) with ESMTPS id 155697A158
	for <>; Mon, 17 Sep 2018 22:00:30 +0000 (UTC)
Message-Id: <>
Date: Mon, 17 Sep 2018 22:00:28 +0000 (UTC)
Subject: x11/libXft has inconsistent freetype2 dependency
X-Send-Pr-Version: www-1.0

>Number:         53614
>Category:       pkg
>Synopsis:       x11/libXft has inconsistent freetype2 dependency
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon Sep 17 22:05:00 +0000 2018
>Last-Modified:  Tue Sep 18 12:40:00 +0000 2018
>Originator:     Mike Volokhov
>Release:        pkgsrc-2018Q2
Darwin wakizashi.local 17.7.0 Darwin Kernel Version 17.7.0: Thu Jun 21 22:53:14 PDT 2018; root:xnu-4570.71.2~1/RELEASE_X86_64 x86_64

On macOS X 10.13 with latest XQuartz 2.7.11 installed when building package x11/libXft the configure stage can't be passed due to ancient freetype2 library.

pkgsrc$ cd x11/libXft && make configure
=> Bootstrap dependency digest>=20010302: found digest-20160304
WARNING: [] Every package should define a LICENSE.
===> Skipping vulnerability checks.
WARNING: No /opt/pkg/pkgdb/pkg-vulnerabilities file found.
WARNING: To fix run: `/opt/pkg/sbin/pkg_admin -K /opt/pkg/pkgdb fetch-pkg-vulnerabilities'.
=> Checksum SHA1 OK for libXft-2.3.2.tar.bz2
=> Checksum RMD160 OK for libXft-2.3.2.tar.bz2
=> Checksum SHA512 OK for libXft-2.3.2.tar.bz2
===> Installing dependencies for libXft-2.3.2nb2
=> Tool dependency libtool-base>=2.4.2nb9: found libtool-base-2.4.6nb1
=> Tool dependency pkgconf-[0-9]*: found pkgconf-1.4.1nb1
=> Tool dependency checkperms>=1.1: found checkperms-1.12
=> Build dependency x11-links>=1.12: found x11-links-1.12
=> Build dependency cwrappers>=20150314: found cwrappers-20180325
=> Full dependency zlib>=1.2.3: found zlib-1.2.11
=> Full dependency fontconfig>=2.13.0: found fontconfig-2.13.0nb1
=> Full dependency freetype2>=2.4.11: found freetype2-2.9
===> Overriding tools for libXft-2.3.2nb2
===> Extracting for libXft-2.3.2nb2
===> Patching for libXft-2.3.2nb2
===> Creating toolchain wrappers for libXft-2.3.2nb2
===> Configuring for libXft-2.3.2nb2
=> Modifying GNU configure scripts to avoid --recheck
=> Replacing config-guess with pkgsrc versions
=> Replacing config-sub with pkgsrc versions
=> Replacing install-sh with pkgsrc version
=> Checking for portability problems in extracted files
... (some lines passed) ...
checking for XRENDER... yes
checking for FREETYPE... yes
checking for FONTCONFIG... configure: error: Package requirements (fontconfig >= 2.5.92) were not met:

Package dependency requirement 'freetype2 >= 21.0.15' could not be satisfied.
Package 'freetype2' has version '18.6.12', required version is '>= 21.0.15'

Consider adjusting the PKG_CONFIG_PATH environment variable if you
installed software in a non-standard prefix.

Alternatively, you may set the environment variables FONTCONFIG_CFLAGS
and FONTCONFIG_LIBS to avoid the need to call pkg-config.
See the pkg-config man page for more details.

*** Error code 1

libXft$ ls -l work/.buildlink/lib/libfreetype.*
lrwxr-xr-x  1 mishka  staff  32 Sep 18 00:55 work/.buildlink/lib/libfreetype.6.dylib -> /opt/X11/lib/libfreetype.6.dylib
lrwxr-xr-x  1 mishka  staff  30 Sep 18 00:55 work/.buildlink/lib/libfreetype.dylib -> /opt/X11/lib/libfreetype.dylib
Providing explicit version dependency forces pkgsrc to use own freetype library which fixes the issue:

Index: Makefile
RCS file: /cvsroot/pkgsrc/x11/libXft/Makefile,v
retrieving revision 1.19
diff -u -r1.19 Makefile
--- Makefile	12 Mar 2018 11:15:53 -0000	1.19
+++ Makefile	17 Sep 2018 21:59:03 -0000
@@ -20,6 +20,7 @@
 .include "../../devel/zlib/"
 BUILDLINK_API_DEPENDS.fontconfig+=	fontconfig>=2.6
 .include "../../fonts/fontconfig/"
+BUILDLINK_API_DEPENDS.freetype2+=	freetype2>=2.8.1
 .include "../../graphics/freetype2/"
 .include "../../x11/libXrender/"
 .include "../../x11/libX11/"


From: Mike Volokhov <>
Subject: Re: pkg/53614
Date: Tue, 18 Sep 2018 02:30:11 +0300

 FYI the graphics/cairo fails for the same reason despite configure =
 fontconfig issue:

 Package dependency requirement 'freetype2 >=3D 21.0.15' could not be =
 Package 'freetype2' has version '18.6.12', required version is '>=3D =

 Again, bumping required freetype2 version (already referenced by the =
 resurrects the package.=

From: Mike Volokhov <>
Subject: Re: pkg/53614
Date: Tue, 18 Sep 2018 02:54:09 +0300

 Same with graphics/cairo-gobject - as soon as freetype version
 were referenced the package builds just fine. Also, perhaps
 the fontconfig should be referenced there as well.

From: Mike Volokhov <>
Subject: Re: pkg/53614
Date: Tue, 18 Sep 2018 15:38:12 +0300


 finally I've ended up setting USE_BUILTIN.freetype2=no pkgsrc wide.
 Might be good idea to adjust the for Darwin - for native
 X11 (i.e. Quartz) it's kinda required, and for pkgsrc X11 it will
 be implied automatically.


NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.43 2018/01/16 07:36:43 maya Exp $
$NetBSD:,v 1.9 2014/08/02 14:16:04 spz Exp $
Copyright © 1994-2017 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.