/bin/sh ../../../../../libtool --silent --mode=compile --tag=CXX g++ -DHAVE_CONFIG_H -I. -I. -I../../../../.. -I/usr/include -I/usr/include/freetype2 -I/usr/kde/3.2/include -I/usr/qt/3/include -I/usr/X11R6/include -DQT_THREAD_SUPPORT -D_REENTRANT -Wnon-virtual-dtor -Wno-long-long -Wundef -Wall -W -Wpointer-arith -Wwrite-strings -ansi -D_XOPEN_SOURCE=500 -D_BSD_SOURCE -Wcast-align -Wconversion -Wchar-subscripts -DNDEBUG -DNO_DEBUG -O2 -march=i686 -O2 -pipe -fno-exceptions -fno-check-new -fno-common -DQT_CLEAN_NAMESPACE -DQT_NO_ASCII_CAST -DQT_NO_STL -DQT_NO_COMPAT -DQT_NO_TRANSLATION -fexceptions -c -o Glyph.lo `test -f 'Glyph.cpp' || echo './'`Glyph.cpp In file included from Font.cpp:25: Font.h:74: syntax error before `&' Font.h:79: syntax error before `;' In file included from Converter.h:29, from Font.cpp:27: /usr/include/freetype2/freetype/ftoutln.h:101: `FT_Error' was not declared in this scope /usr/include/freetype2/freetype/ftoutln.h:102: syntax error before `(' /usr/include/freetype2/freetype/ftoutln.h:136: `FT_Error' was not declared in this scope /usr/include/freetype2/freetype/ftoutln.h:137: redefinition of `int FT_EXPORT' /usr/include/freetype2/freetype/ftoutln.h:102: `int FT_EXPORT' previously defined here /usr/include/freetype2/freetype/ftoutln.h:137: syntax error before `(' /usr/include/freetype2/freetype/ftoutln.h:143: `FT_Error' was not declared in this scope /usr/include/freetype2/freetype/ftoutln.h:144: redefinition of `int FT_EXPORT' /usr/include/freetype2/freetype/ftoutln.h:137: `int FT_EXPORT' previously defined here /usr/include/freetype2/freetype/ftoutln.h:144: syntax error before `(' /usr/include/freetype2/freetype/ftoutln.h:174: `FT_Error' was not declared in this scope /usr/include/freetype2/freetype/ftoutln.h:175: redefinition of `int FT_EXPORT' /usr/include/freetype2/freetype/ftoutln.h:144: `int FT_EXPORT' previously defined here /usr/include/freetype2/freetype/ftoutln.h:175: syntax error before `(' /usr/include/freetype2/freetype/ftoutln.h:179: `FT_Error' was not declared in this scope /usr/include/freetype2/freetype/ftoutln.h:180: redefinition of `int FT_EXPORT' /usr/include/freetype2/freetype/ftoutln.h:175: `int FT_EXPORT' previously defined here /usr/include/freetype2/freetype/ftoutln.h:180: syntax error before `(' /usr/include/freetype2/freetype/ftoutln.h:198: `FT_Error' was not declared in this scope /usr/include/freetype2/freetype/ftoutln.h:199: redefinition of `int FT_EXPORT' /usr/include/freetype2/freetype/ftoutln.h:180: `int FT_EXPORT' previously defined here /usr/include/freetype2/freetype/ftoutln.h:199: syntax error before `(' /usr/include/freetype2/freetype/ftoutln.h: In function `int FT_EXPORT()': /usr/include/freetype2/freetype/ftoutln.h:226: `int FT_EXPORT()' redeclared as different kind of symbol /usr/include/freetype2/freetype/ftoutln.h:199: previous declaration of `int FT_EXPORT' /usr/include/freetype2/freetype/ftoutln.h:199: previous non-function declaration `int FT_EXPORT' /usr/include/freetype2/freetype/ftoutln.h:226: conflicts with function declaration `int FT_EXPORT()' /usr/include/freetype2/freetype/ftoutln.h:226: parse error before `(' /usr/include/freetype2/freetype/ftoutln.h:226: `FT_Outline' undeclared (first use this function) /usr/include/freetype2/freetype/ftoutln.h:226: (Each undeclared identifier is reported only once /usr/include/freetype2/freetype/ftoutln.h:226: for each function it appears in.) /usr/include/freetype2/freetype/ftoutln.h:226: `outline' undeclared (first use this function) /usr/include/freetype2/freetype/ftoutln.h:227: `FT_BBox' undeclared (first use this function) /usr/include/freetype2/freetype/ftoutln.h:227: `acbox' undeclared (first use this function) /usr/include/freetype2/freetype/ftoutln.h:227: confused by earlier errors, bailing out cpp0: output pipe has been closed make[6]: *** [Font.lo] Error 1 make[6]: *** Waiting for unfinished jobs.... In file included from Glyph.cpp:22: Glyph.h:53: syntax error before `*' Glyph.h:57: syntax error before `[' Glyph.cpp:62: syntax error before `*' make[6]: *** [Glyph.lo] Error 1 make[6]: Leaving directory `/var/tmp/portage/kdegraphics-3.2.0/work/kdegraphics-3.2.0/ksvg/impl/libs/libtext2path/src' make[5]: *** [all-recursive] Error 1 make[5]: Leaving directory `/var/tmp/portage/kdegraphics-3.2.0/work/kdegraphics-3.2.0/ksvg/impl/libs/libtext2path' make[4]: *** [all-recursive] Error 1 make[4]: Leaving directory `/var/tmp/portage/kdegraphics-3.2.0/work/kdegraphics-3.2.0/ksvg/impl/libs' make[3]: *** [all-recursive] Error 1 make[3]: Leaving directory `/var/tmp/portage/kdegraphics-3.2.0/work/kdegraphics-3.2.0/ksvg/impl' make[2]: *** [all-recursive] Error 1 make[2]: Leaving directory `/var/tmp/portage/kdegraphics-3.2.0/work/kdegraphics-3.2.0/ksvg' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/var/tmp/portage/kdegraphics-3.2.0/work/kdegraphics-3.2.0' make: *** [all] Error 2 !!! ERROR: kde-base/kdegraphics-3.2.0 failed. !!! Function kde_src_compile, Line 127, Exitcode 2 !!! died running emake, kde_src_compile:make Reproducible: Always Steps to Reproduce: 1. emerge -u kde 2. 3. Portage 2.0.50-r1 (default-1.0, gcc-2.95.3, glibc-2.2.5-r2,2.2.5-r9, 2.4.23) ================================================================= System uname: 2.4.23 i686 Pentium III (Coppermine) Gentoo Base System version 1.4.3.13 Autoconf: sys-devel/autoconf-2.58 Automake: sys-devel/automake-1.7.7 ACCEPT_KEYWORDS="x86" AUTOCLEAN="yes" CFLAGS="-march=i686 -O2 -pipe" CHOST="i686-pc-linux-gnu" COMPILER="" CONFIG_PROTECT="/etc /usr/X11R6/lib/X11/xkb /usr/kde/2/share/config /usr/kde/3.1/share/config /usr/kde/3/share/config /usr/share/config /usr/share/texmf/tex/generic/config/ /usr/share/texmf/tex/platex/config/ /var/qmail/control" CONFIG_PROTECT_MASK="/etc/gconf /etc/env.d" CXXFLAGS="-march=i686 -O2 -pipe" DISTDIR="/usr/portage/distfiles" FEATURES="autoaddcvs ccache sandbox" GENTOO_MIRRORS="ftp://ftp.ussg.iu.edu/pub/linux/gentoo ftp://ftp.gtlib.cc.gatech.edu/pub/gentoo http://adelie.polymtl.ca/ http://gentoo.seren.com/gentoo" MAKEOPTS="-j2" PKGDIR="/usr/portage/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage" PORTDIR_OVERLAY="" SYNC="rsync://rsync.us.gentoo.org/gentoo-portage" USE="3dnow X aalib alsa apm arts avi berkdb cdr crypt cups encode esd gdbm gif gnome-libs gpm gtk guile imlib java jpeg kde libg++ libwww mikmod mmx motif mozilla mpeg mysql ncurses nls oggvorbis opengl oss pam pdflib perl png postgres python qt quicktime readline scanner sdl slang spell ssl svga tcltk tcpd tetex tiff truetype x86 xml2 xmms xv"
I am getting the same problem. I tried to re-emerge freetype but that did not fix it.
I am not sure what the root cause is but, it looks like there are two freetype.h files on my system. One in /usr/include/freetype and the other in /usr/include/freetype2/freetype. Because the include path to the compile have /usr/include before /usr/include/freetype2 the first version of freetype.h is used. This version is the wrong one. I moved /usr/include/freetype to /usr/include/freetype.old so that the freetype.h in there would not be used. This has worked for me but it does really answer the real cause of the problem.
Same problem here. # qpkg -f -v /usr/include/freetype2/freetype/freetype.h media-libs/freetype-2.1.4 * # qpkg -f -v /usr/include/freetype/freetype.h media-libs/freetype-1.3.1-r3 *
Crazy fix that simply reorders the include paths in all Makefile.in files. Add this to kdegraphics-3.2.0.ebuild: *************************************************************************** src_unpack() { unpack "$A" cd "$S" # Bug 41467 echo "Fixing Freetype include dir presedence problem" find . -name Makefile.in | while read f; do sed 's/INCLUDES *= *\(.*\) \($(LIBFREETYPE_CFLAGS)\)/INCLUDES = \2 \1/' "$f" | sed 's/INCLUDES *= *\(.*\) \($(FREETYPE_CFLAGS)\)/INCLUDES = \2 \1/' > "$f.fixed" mv -f "$f.fixed" "$f" done } *************************************************************************** No guarantees, here. It did, however, make kdegraphics-3.2.0 compile on my system.
Any reason you have freetype1 around? I thought freetype2 was a replacement for it.
I took Richard Taylor's advice and moved /usr/include/freetype to /usr/include/freetype.old So is perhaps the real problem that when installing freetype2, it does not un-install freetype1? Perhaps we dont actually want to do this either. In that case, how do we maintain freetype1 and 2 together?
# grep -H freetype-1 /var/db/pkg/*/*/DEPEND /var/db/pkg/x11-wm/enlightenment-0.16.6/DEPEND: =media-libs/freetype-1* enlightenment-0.16.6.ebuild: ********************************************** DEPEND=">=media-libs/fnlib-0.5 esd? ( >=media-sound/esound-0.2.19 ) =media-libs/freetype-1* >=gnome-base/libghttp-1.0.9-r1 >=media-libs/imlib-1.9.8" **********************************************
Unmerging freetype 1.3.1-r3 seems to have done the trick. I believe it's stagnant anyways; I'll double-check if anything is dependant on it shortly. It would, however, be nice to get this l'il buglet squashed before dozens of users run screaming to RPMs. :P
*** Bug 44856 has been marked as a duplicate of this bug. ***
Since it's a freetype thing, I'll let the maintainer decide what to do :)
includes look fine to me, it also works fine here. I noticed both users seemed to be on gcc2 . Bit of a long shot, but might that be the cause ? Nobody on gcc3 experiencing it ? As for a solution, this really should go ok judging from the source & g++ lines. A somewhat dirty workaround would probably be to just force the inclusion of the freetype2 dir before anything else (define it in C(XX)FLAGS might work). Basicly what was suggested in comment #4 . Reassigning : kde team should fix this.
It works fine here (gcc 3). The problem seems to be local and it seems to be more related to having multiple instances of freetype installed.
i got that, but the way of inclusion is meant to solve this problem (check out how it includes freetype stuff). So that's why i think the gcc behaviour here is (/was) incorrect. Having both freetype1 & 2 installed should be no problem.
I think it looks like freetype was not very well designed for cohabitation between version 1 and 2. But then, I'm no libraries expert. Look at this: # grep INCLUDES kdegraphics-3.2.0/ksvg/impl/libs/libtext2path/src/Makefile.am INCLUDES = $(FRIBIDI_CFLAGS) $(FREETYPE_CFLAGS) $(all_includes) # fribidi-config --cflags -I/usr/include # freetype-config --cflags -I/usr/include/freetype2 # ll /usr/include/freetype2/freetype/freetype.h /usr/include/freetype/freetype.h -rw-r--r-- 1 root root 44K Mar 22 07:25 /usr/include/freetype/freetype.h -rw-r--r-- 1 root root 189K Mar 19 10:40 /usr/include/freetype2/freetype/freetype.h So, the fribidi-thing will add /usr/include to the inclusion path before freetype gets to add /usr/include/freetype2. Since there is a "freetype/freetype.h" in both of these directories, the first one will be used, which, according to my comment #3 belongs to freetype 1, and not version 2.
were it not that freetype/freetype.h never gets included directly here afaics. In theory it should go ok, so i still think it's a gcc2 thing messing with includes. That's why i suggest the simple solution to just switch the includes around for now.
I think the "switching includes around" idea is good. I do still, however, think that something is wrong with freetype 1/2. Let's look at the file Glyph.h in the directory where compilation fails: > cd kdegraphics-3.2.0/ksvg/impl/libs/libtext2path/src > grep -i '#include.*ft' Glyph.h #include <ft2build.h> #include FT_FREETYPE_H OK, so let's try to find out where FT_FREETYPE_H is defined: > grep '^#include' /usr/include/ft2build.h #include <freetype/config/ftheader.h> > grep 'define.*FT_FREETYPE_H' /usr/include/freetype2/freetype/config/ftheader.h #define FT_FREETYPE_H <freetype/freetype.h> So, freetype/freetype.h _does_ get included, as far as I can see.
right, keen eye there. But still it seems to be a gcc2 only include re-ordering issue. I don't see the harm in reordering in an ebuild as a fix for now. These problems used to be fairly common time ago when freetype2 was younger, but i haven't seen one in a long while. The whole new freetype include setup seems to be focused at moving towards a better header files seperation to avoid just these problems, so future versions should eventually fix it. We might consider doing some similar preliminary work ourselves (shouldn't be too hard if we complete the move to >=ft-2.17).
Reassigning, nothing KDE can do for this bug.
How about WONTFIX? Could really care less about gcc-2.95, you can't even install it on Gentoo any more without a major hassle.
no problem with that