You are not logged in.

#1 2013-12-15 11:10:43

mmatt
Member
Registered: 2009-01-18
Posts: 5

[SOLVED] CEGUI compiled without freetype - Arch's bug or CEGUI's?

Apologies if this is in the wrong place; although I've been using Arch for a long time I've never had cause to post in the forums before... This isn't a question about solving a particular problem but rather where it should be reported having found the issue.

Anyway, running an application which depends on cegui is throwing exceptions during font loading with the message "CEGUI was compiled without freetype support.". Note that this will only happen if the application uses dynamic fonts i.e. tries to load a *.ttf font file.

I've rebuilt using the PKGBUILD from the community repository and cmake fails to find the freetype include directories.

Setting the following cmake variables resolved this:

  -DFREETYPE_H_PATH_ft2build=/usr/include/freetype2/ \
  -DFREETYPE_H_PATH_ftconfig=/usr/include/freetype2/config/ \

I was about to file an Arch bug for this, but arguably this is a problem with CEGUI's FindFreetype.cmake. The following patch will also resolve the problem for building on an arch system:

  diff -r 319182022f9f cmake/FindFreetype.cmake
  --- a/cmake/FindFreetype.cmake  Sat Dec 07 09:00:48 2013 +0000
  +++ b/cmake/FindFreetype.cmake  Sun Dec 15 10:30:53 2013 +0000
  @@ -3,8 +3,8 @@
   ################################################################################
   include(FindPackageHandleStandardArgs)
   
  -find_path(FREETYPE_H_PATH_ft2build NAMES ft2build.h)
  -find_path(FREETYPE_H_PATH_ftconfig NAMES freetype/config/ftconfig.h PATH_SUFFIXES freetype2)
  +find_path(FREETYPE_H_PATH_ft2build NAMES ft2build.h PATH_SUFFIXES freetype2)
  +find_path(FREETYPE_H_PATH_ftconfig NAMES config/ftconfig.h PATH_SUFFIXES freetype2)
   find_library(FREETYPE_LIB NAMES freetype2 freetype libfreetype PATH_SUFFIXES dynamic)
   find_library(FREETYPE_LIB_DBG NAMES freetype_d libfreetype_d PATH_SUFFIXES dynamic)
   mark_as_advanced(FREETYPE_H_PATH_ft2build FREETYPE_H_PATH_ftconfig FREETYPE_LIB FREETYPE_LIB_DBG)

But then again I'm no cmake expert, so this may cause issues on other systems.

Packages:

  • cegui 0.8.2-6

  • freetype2 2.5.2-1

My question: Should I report this as an Arch bug (it is related to Arch's packaging of the project) or report it upstream (the cmake find file should presumably be capable of finding the headers in /usr/include/freetype2/)?

Last edited by mmatt (2013-12-20 07:26:56)

Offline

#2 2013-12-20 02:06:17

Svenstaro
Administrator
From: Germany
Registered: 2008-11-19
Posts: 388

Re: [SOLVED] CEGUI compiled without freetype - Arch's bug or CEGUI's?

I fixed this for you. Next time report an upstream bug, attach your patch and then make an Arch bug in which you link to the upstream bug report.

Offline

#3 2013-12-20 07:25:13

mmatt
Member
Registered: 2009-01-18
Posts: 5

Re: [SOLVED] CEGUI compiled without freetype - Arch's bug or CEGUI's?

Many thanks Sven, I will follow your advice next time.

Offline

Board footer

Powered by FluxBB