This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH v2] Fix libgfortran cross compile configury w.r.t newlib
- From: Richard Earnshaw <rearnsha at arm dot com>
- To: Marcus Shawcroft <marcus dot shawcroft at gmail dot com>
- Cc: Marcus Shawcroft <Marcus dot Shawcroft at arm dot com>, Steve Ellcey <sellcey at mips dot com>, "burnus at net-b dot de" <burnus at net-b dot de>, "gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>, "fortran at gcc dot gnu dot org" <fortran at gcc dot gnu dot org>
- Date: Tue, 15 Oct 2013 15:13:58 +0100
- Subject: Re: [PATCH v2] Fix libgfortran cross compile configury w.r.t newlib
- Authentication-results: sourceware.org; auth=none
- References: <52443AFE dot 5050802 at arm dot com> <1380298134 dot 5988 dot 61 dot camel at ubuntu-sellcey> <52497156 dot 5010203 at arm dot com> <524AB4AD dot 6070508 at arm dot com> <CAFqB+PxJR53JGV3f8dy7SNRHbdVMc0aqAC5ruFC6S0WXtksE5w at mail dot gmail dot com>
On 15/10/13 12:31, Marcus Shawcroft wrote:
> On 1 October 2013 12:40, Marcus Shawcroft <marcus.shawcroft@arm.com> wrote:
>> On 30/09/13 13:40, Marcus Shawcroft wrote:
>>
>>>> Well, I thought this patch would work for me, but it does not. It looks
>>>> like gcc_no_link is set to 'no' on my target because, technically, I can
>>>> link even if I don't use a linker script. I just can't find any
>>>> functions.
>>>>
>>
>>> In which case gating on gcc_no_link could be replaced with a test that
>>> looks to see if we can link with the library. Perhaps looking for
>>> exit() or some such that might reasonably be expected to be present.
>>>
>>> For example:
>>>
>>> AC_CHECK_FUNC(exit)
>>> if test "x${with_newlib}" = "xyes" -a "x${ac_cv_func_exit}" = "xno"; then
>>>
>>> /Marcus
>>>
>>>
>>>
>>>
>>
>>
>> Patch attached.
>>
>> /Marcus
>>
>> 2013-10-01 Marcus Shawcroft <marcus.shawcroft@arm.com>
>>
>> * configure.ac (AC_CHECK_FUNCS_ONCE): Add for exit() then make
>> existing AC_CHECK_FUNCS_ONCE dependent on outcome.
>
> Ping^2
>
> /Marcus
>
OK provided no Fortran maintainer objects within the next 24 hours.
R.