nanogui: how to cross compile FreeType font freetype1.3.1
Subject:
AW: [nanogui] how to cross compile FreeType font freetype1.3.1
From:
"Thomas Malkus" ####@####.####
Date:
1 Jul 2007 17:16:22 +0100
Message-Id: <001401c7bbfb$235a3bd0$6a0eb370$@de>
Hi,
> Right now I am trying to add freetype font into my application so
that I
> can use different size of fonts. I downloaded FreeType library 1.3.1
> from microwindows.org. However, I could not figure out how to cross
> compile this library. It seems that the configration file is
> complicated.
> Any one here made it work? Would you please give me a direction?
Yes, with a ARM9 (AT91RM9200) but not with freetype 1.3.1.
I had much trouble with freetype and nano-X, too. Now it is ok.
I use microwindows 0.91 (or CVS source) and freetype 2.0.9 (you
must search with Google for freetype-2.0.9.tar.gz)
For compiling freetype2 define the exports for your toolchain.
Example:
export CC=arm-linux-3.4.2-gcc
export CXX=arm-linux-3.4.2-g++
export CPP=arm-linux-3.4.2-cpp
export AR=arm-linux-3.4.2-ar
export RANLIB=arm-linux-3.4.2-ranlib
export STRIP=arm-linux-3.4.2-strip
Change to the freetype-2.0.9 directory and use (with the option
for your processor architecture.
./configure --host=arm-linux --enable-static
make
After build of freetype2 change the config of microwindows:
FREETYPE_FONT_DIR=$(YOURPATH)/fonts/truetype
HAVE_FREETYPE_2_SUPPORT = Y
INCFT2LIB = $(YOURPATH)/freetype-2.0.9/include
LIBFT2LIB = $(YOURPATH)/freetype-2.0.9/objs/.libs/libfreetype.a
and do a rebuild on microwindows.
You could also use MWFONTDIR as path to the font directory.
Regards, Tom