freetype-devel
[Top][All Lists]
Advanced

[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: Werner LEMBERG
Subject: Re: [ft-devel] autoconf-based cross-building patch ([ft] FT2 Cross-compile Error)
Date: Tue, 08 Nov 2011 08:02:50 +0100 (CET)

> Sorry to resurrect an ancient thread, but I ran into a similar
> problem when attempting to cross-compile freetype2 v2.4.6 using
> LTIB.  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.

Thanks!  Some comments:

> # 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
> #    and guessing the wrong compiler triplet for the build machine
> #    when called in LTIB environment
> #
> #   FIX: remove call to builds/unix/config.guess in favor of
> #   '/usr/bin/gcc -dumpmachine'

This is a hack, of course.  My knowedge of the LTIB environment is
zero, but if it differs so much from a normal setup that
`config.guess' fails, I strongly suggest that you report the problem
to Ben Elliston <address@hidden> who maintains the `config.guess' and
`config.sub' scripts.  For a new release, FreeType always uses the
most recent version of those files, directly pulling them from the git
repository.

  http://git.savannah.gnu.org/cgit/config.git/

> # 2) The [triplet]-gcc file was adding some command switches 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.
> #
> #    FIX: modify the variable holding the native compiler call
> #    (CC_BUILD) to set the environment to something resonable when
> #    using [triplet]-gcc as determined by the above fix.  (env
> #    PATH=/usr/bin XXX)
> #
> #    Note that the problem is caused by bad env settings -- using
> #    the configure to set up a "proper" no-spoof cross-compile works
> #    fine.

No idea how to solve this in a portable way...


    Werner



reply via email to

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