[Mesa-dev] [PATCH 3/6] Android: Fix building secondary arch in mixed 32/64-bit builds

Rob Herring robh at kernel.org
Mon Feb 1 22:47:01 UTC 2016


On Sun, Jan 31, 2016 at 4:14 AM, Emil Velikov <emil.l.velikov at gmail.com> wrote:
> On 29 January 2016 at 20:52, Rob Herring <robh at kernel.org> wrote:
>> At least in Android M, using LOCAL_CC does not work for secondary arch
>> when doing dual arch builds. Use LOCAL_CLFAGS and LOCAL_CONLYFLAGS
>> instead.
>>
> Not really Android M specific afaict. You can get issues even with
> Android 4.{3,4} as long as you're using clang/llvm.

Looking at this some more, AFAICT, it has nothing to do with clang.
But I haven't tried either. I think the problem is TARGET_CC is not
set for the secondary arch. The secondary arch gets 2ND_TARGET_CC
instead.

However, I'd expect that Android L x86_64 builds in android-x86 would
be failing too. So maybe it is clang related. In any case, just
building various combinations just to improve the explanation doesn't
seem worthwhile. The fix is a cleaner solution no matter what.

> Android 4.4
> onwards introduced LOCAL_CONLYFLAGS and imho it's unreasonable to
> expect that mesa supports older Androids. Thus this change will be
> safe. Can you please add something alike my that two sentences to the
> commit message ?

Agreed, given that no one seems to be tracking mesa mainline in any
Android builds. I'll reword things and add this to make it clearer.

Rob

>> Cc: Emil Velikov <emil.l.velikov at gmail.com>
>> Cc: Chih-Wei Huang <cwhuang at android-x86.org>
>> Signed-off-by: Rob Herring <robh at kernel.org>
>> ---
>>  Android.common.mk | 9 ++++-----
>>  1 file changed, 4 insertions(+), 5 deletions(-)
>>
>> diff --git a/Android.common.mk b/Android.common.mk
>> index 948561c..c882209 100644
>> --- a/Android.common.mk
>> +++ b/Android.common.mk
>> @@ -22,12 +22,8 @@
>>  # DEALINGS IN THE SOFTWARE.
>>
>>  # use c99 compiler by default
> Please move this comment where it's applicable.
>
> -Emil


More information about the mesa-dev mailing list