[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [ft-devel] autoconf-based cross-building patch ([ft] FT2 Cross-compi

From: Antoine Leca
Subject: Re: [ft-devel] autoconf-based cross-building patch ([ft] FT2 Cross-compile Error)
Date: Tue, 08 Nov 2011 15:10:43 +0100
User-agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; fr; rv: Gecko/20100228 Thunderbird/ Mnenhy/

[ Sorry if it appears duplicated, I sent first with the wrong name. ]

Aaron Parr wrote:
> Sorry to resurrect an ancient thread,

Indeed ancient! However that thread
was about Toshiya-san providing us an updated version of the autoconf
machinery, dealing correctly with a (then new) locally-built helper
tool, apinames; and added a new file named docs/INSTALL.CROSS.

Do you mean you are having problem with the cross-compilation machinery?
Note that most in this area comes from autoconf (currently 2.68), I do
not believe there are much Freetype-specific stuff, probably only the
part with deals with extension for executables (EXEEXT_BUILD, E_BUILD).

> but I ran into a similar problem when attempting to cross-compile
> freetype2 v2.4.6 using LTIB.

Do ``LTIB'' do anything special to "process" the (uncommon) Freetype
configuration process? I browsed the web site about it without success.

> In the hopes of saving someone else the trouble, I'm including my
> solution in the form of the attached patch which explains the problem
> and shows my hacky fix to allow it to build under LTIB.
> -Aaron
> # 2011-Nov-07
> # This patch provides a workaround for config problems caused by LTIB's env 
> setup.
> # In a nutshell, two issues were occurring:
> # 1) Freetype2's configure script was ignoring --build=XXX options

I cannot reproduce that in a basic (clean) installation of Freetype.
Is it possible to you to provide me the .log file of the configure
phase? (and of the former steps, if any.)

>  and guessing the wrong compiler triplet for the build machine when
> called in LTIB environment

You mean, {FT2src}/build/unix/configure does not use CC_BUILD when
passed _as_argument_ on the command line? Strange, it does work here...
Are you sure you are passing it _after_ configure in the main
invocation, like in
    $ path/to/top/configure --build=current-machine-triplet \
        CC_BUILD=overridden-building-compiler \
        --host=target-machine-triplet \

As documented in the INSTALL.CROSS document and clearly explained in the
thread you mentioned, something along the lines of
    $ CC_BUILD=overridden-building-compiler \
        CC=overridden-target-gcc \
        path/to/top/configure --build=c-m-3 --host=t-m-3
is NOT guaranteed to work!

Also note that Freetype chose (in 2006) to name it CC_BUILD, while other
packages commonly use instead HOST_CC (*BSD heritage, confusing in the
GNU world which is based on the Canadian cross-compilation scheme) or
CC_FOR_BUILD (preferred in GNU world.)

> # 2) The [triplet]-gcc file was adding some command switchs and
> somehow using the path to find "the true gcc" when compiling. Since
> the LTIB environment places its own spoof dirs first in the path,
> [triplet]-gcc wound up calling the cross compiler.

I am not sure this is any different from the problem above.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]