[MacPorts] #62187: freetype @2.10.4: fatal error: 'ft2build.h' file not found

MacPorts noreply at macports.org
Sat Jan 30 23:06:39 UTC 2021


#62187: freetype @2.10.4: fatal error: 'ft2build.h' file not found
----------------------+----------------------
  Reporter:  nsklaus  |      Owner:  (none)
      Type:  defect   |     Status:  new
  Priority:  Normal   |  Milestone:
 Component:  ports    |    Version:  2.6.4
Resolution:           |   Keywords:  freetype
      Port:           |
----------------------+----------------------
Description changed by nsklaus:

Old description:

> i'm trying to compile two projects: wine and dwm
> both suffer from the same problem, they have trouble locating freetype
> files.
>
> here trying to compile dwm:
> {{{
> -> dwm $ sudo port install freetype
> Password:
> --->  Computing dependencies for freetype
> --->  Cleaning freetype
> --->  Scanning binaries for linking errors
> --->  No broken files found.
> --->  No broken ports found.
> -> dwm $
> -> dwm $ pwd
> /Users/klaus/Sources/dwm
> -> dwm $ make
> dwm build options:
> CFLAGS   = -std=c99 -pedantic -Wall -Wno-deprecated-declarations -Os
> -I/usr/X11R6/include -I/usr/include/freetype2 -D_DEFAULT_SOURCE
> -D_BSD_SOURCE -D_POSIX_C_SOURCE=200809L -DVERSION="6.2" -DXINERAMA
> LDFLAGS  = -L/usr/X11R6/lib -lX11 -lXinerama -lfontconfig -lXft -lX11-xcb
> -lxcb -lxcb-res
> CC       = cc
> cc -c -std=c99 -pedantic -Wall -Wno-deprecated-declarations -Os
> -I/usr/X11R6/include -I/usr/include/freetype2 -D_DEFAULT_SOURCE
> -D_BSD_SOURCE -D_POSIX_C_SOURCE=200809L -DVERSION=\"6.2\" -DXINERAMA
> drw.c
> In file included from drw.c:6:
> /usr/X11R6/include/X11/Xft/Xft.h:40:10: fatal error: 'ft2build.h' file
> not found
> #include <ft2build.h>
>          ^~~~~~~~~~~~
> 1 error generated.
> make: *** [drw.o] Error 1
> ?2 dwm $ l /opt/local/include/freetype2/
> /opt/local/include/freetype2/
> [1.5K]  freetype
> [ 990]  ft2build.h
>
> 1 directory, 1 file
> -> dwm $
>  }}}
>
> as for wine, i con configure and make it. no errors. freetype support is
> found during the ./configure.
> in the end when wine is built, i try to run it with: ./wine64 winecfg
> and there it complains it cannot find freetype support..
> here's the output:
> {{{
> -> wine-6.1 $ ./wine64 notepad
> Wine cannot find the FreeType font library.  To enable Wine to
> use TrueType fonts please install a version of FreeType greater than
> or equal to 2.0.5.
> http://www.freetype.org
> }}}
>
> i'm on macos 11.2 rc, arm64 arch, but i run everything through rosetta2
> (star term with roseetta2) so it's all x86_64 env.

New description:

 i'm trying to compile two projects: wine and dwm
 both suffer from the same problem, they have trouble locating freetype
 files.

 here trying to compile dwm:
 {{{
 -> dwm $ sudo port install freetype
 Password:
 --->  Computing dependencies for freetype
 --->  Cleaning freetype
 --->  Scanning binaries for linking errors
 --->  No broken files found.
 --->  No broken ports found.
 -> dwm $
 -> dwm $ pwd
 /Users/klaus/Sources/dwm
 -> dwm $ make
 dwm build options:
 CFLAGS   = -std=c99 -pedantic -Wall -Wno-deprecated-declarations -Os
 -I/usr/X11R6/include -I/usr/include/freetype2 -D_DEFAULT_SOURCE
 -D_BSD_SOURCE -D_POSIX_C_SOURCE=200809L -DVERSION="6.2" -DXINERAMA
 LDFLAGS  = -L/usr/X11R6/lib -lX11 -lXinerama -lfontconfig -lXft -lX11-xcb
 -lxcb -lxcb-res
 CC       = cc
 cc -c -std=c99 -pedantic -Wall -Wno-deprecated-declarations -Os
 -I/usr/X11R6/include -I/usr/include/freetype2 -D_DEFAULT_SOURCE
 -D_BSD_SOURCE -D_POSIX_C_SOURCE=200809L -DVERSION=\"6.2\" -DXINERAMA drw.c
 In file included from drw.c:6:
 /usr/X11R6/include/X11/Xft/Xft.h:40:10: fatal error: 'ft2build.h' file not
 found
 #include <ft2build.h>
          ^~~~~~~~~~~~
 1 error generated.
 make: *** [drw.o] Error 1
 ?2 dwm $ l /opt/local/include/freetype2/
 /opt/local/include/freetype2/
 [1.5K]  freetype
 [ 990]  ft2build.h

 1 directory, 1 file
 -> dwm $
  }}}

 as for wine, i con configure and make it. no errors. freetype support is
 found during the ./configure.
 in the end when wine is built, i try to run it with: ./wine64 winecfg
 and there it complains it cannot find freetype support..
 here's the output:
 {{{
 -> wine-6.1 $ ./wine64 notepad
 Wine cannot find the FreeType font library.  To enable Wine to
 use TrueType fonts please install a version of FreeType greater than
 or equal to 2.0.5.
 http://www.freetype.org
 }}}

 i'm on macos 11.2 rc, arm64 arch, but i run everything through rosetta2
 (start term with rosetta2) so it's all x86_64 env.

--

-- 
Ticket URL: <https://trac.macports.org/ticket/62187#comment:1>
MacPorts <https://www.macports.org/>
Ports system for macOS


More information about the macports-tickets mailing list