Freetype header problem


Forum: Extension Development
Topic: Freetype header problem
started by: WDef

Posted by WDef on June 08 2008,22:58
I'm having a crack at building Qt on dsl.

Running into errors beginning with:

Code Sample
/opt/compile-3.3.5/include/ft2build.h:55:38: freetype/config/ftheader.h: No such file or directory


Ideas?

Posted by WDef on June 08 2008,23:13
Never mind, I think I know what it is.

cairo uci also contains freetype, and I had that loaded. The build was looking at that instead of the freetype inside the compile uci since running freetype-config --cflags was pointing at the cairo headers.  I think.

Posted by Juanito on June 09 2008,04:11
That sounds about right - compile-3.3.5 contains freetype-config pointing at the base dsl freetype, whereas cairo-1.2 has freetype-config pointing at the freetype in cairo-1.2

I did things that way as cairo-1.2 was a "building block" on the way to compiling gtk2, gnomelibs, etc.

With the pkgconfig flag set, I don't think you'll need cflags to point at the cairo headers?

Posted by WDef on June 09 2008,10:40
Removing cairo uci and remounting compile uci sorted that out.
Posted by WDef on June 09 2008,18:28
Qt4 compiled, much to my amazement :=)

Explicitly set the include path to freetype2 and then ran into the PATH_MAX error,  or so I realized after tracing back through the header errors.  I don't really know if it's kosher but I got around it by setting:

Code Sample
#define PATH_MAX        4096 /* # chars in a path name including nul */


at the top of the compiler.h header in the Qt4 sources.

That value is what I assume it is supposed to be from linux/limits.h, but I don't really know (or why Qt4 can't find that).

The demos look very nice indeed - ultrasnazzy guis.

It's huge.  Stripping both binaries and libs gets it down to 570MB (from 1GB).

There are some other things that might be able to come out, but I'm loathe to remove the docs, demos or examples because it's a full development kit for using Qt4, and those things are accessible via its own guis, which would be nice to keep for programming.

I'll see what size uci it creates first - all of the text etc docs will compress to nothing.

EDIT:  might be ok to just put the QtCore and QtGui libs in a uci (that is the absolute minimum I think), but there is always going to be something that comes along that won't run.

Overly obsessing about the size of ucis is absolutely pointless anyway imho, it makes no difference whatsoever, except to the download size, and to all the things that won't run or to the lost functionality of the package because some key thing has been removed.

Posted by curaga on June 09 2008,19:07
So, I take you built all the examples and demos? Did you use Qt 4.4 or an older one?
'Cause I'm interested in trying the Qt4 Webkit edition, which was included as a demo in 4.4.

As for the libs and headers, my recent build of 4.3 was only about 50mb, but I think including everything is nice.

Posted by WDef on June 09 2008,19:37
It's the current Qt4.4 release, built everything.  It includes support for earlier Qt, but a lot has changed apparently.

No OpenGL support compiled in and I'm not sure about sound.

btw didn't know you did build it - where is that?

Posted by WDef on June 09 2008,22:25
I spoke too soon.  Almost everything seems to have built, but not phonon and not the webkit browser demo :(

In both those cases it seems only static libs got built, so the corresponding demo does not compile.  

I will have to look more closely at what headers and libs are required at that point;  it must be finding only corresponding static libs and thus building a static lib for qtwebkit.

Most other demos appear to have compiled against shared libs aok.

I see there has been a lot of buzz about the qt webkit demo (or is it astroturf, since it doesn't have bells and whistles yet) so I'd quite like to get this working.

Some of these demos (which are working applications) are way cool.

Posted by ^thehatsrule^ on June 10 2008,00:07
Quote (WDef @ June 09 2008,18:28)
Explicitly set the include path to freetype2 and then ran into the PATH_MAX error,  or so I realized after tracing back through the header errors.  I don't really know if it's kosher but I got around it by setting:

Code Sample
#define PATH_MAX        4096 /* # chars in a path name including nul */


at the top of the compiler.h header in the Qt4 sources.

That value is what I assume it is supposed to be from linux/limits.h, but I don't really know (or why Qt4 can't find that).
That's a problem with the compile-3.3.5 extension.
One way around it is to do the .../include workaround (see forum thread(s) or .info)

The .info has the wrong info, actually.  It has
Quote
$ cp -a /opt/compile-3.3.5/optional /opt
$ export CPPFLAGS=-I/opt/include
while the first line should be
Quote
$ cp -a /opt/compile-3.3.5/include /opt

Quote
EDIT:  might be ok to just put the QtCore and QtGui libs in a uci (that is the absolute minimum I think), but there is always going to be something that comes along that won't run.

Overly obsessing about the size of ucis is absolutely pointless anyway imho, it makes no difference whatsoever, except to the download size, and to all the things that won't run or to the lost functionality of the package because some key thing has been removed.
You could always make 2 extensions if there is a noticeable size difference (if you have time).

Posted by WDef on June 10 2008,09:28
Thanks for that.  I didn't try that workaround.  There were no other missing system defines except PATH_MAX apparently.

I'll fool around and see if I can get the webkit demo built first.

Posted by curaga on June 10 2008,13:15
Oh, that was on my 64-bit comp, to get Psi 0.11 running :p
And also to hold for Opera 9.5..

Powered by Ikonboard 3.1.2a
Ikonboard © 2001 Jarvis Entertainment Group, Inc.