mbox series

[RFC,0/3] mesa: Initial build fixups for AOSP/master

Message ID 20190502180346.4769-1-john.stultz@linaro.org (mailing list archive)
Headers show
Series mesa: Initial build fixups for AOSP/master | expand

Message

John Stultz May 2, 2019, 6:03 p.m. UTC
Somewhat recent changes in the AOSP build system has been made
which fairly severely restricts the build environment. This has
made it difficult to test mesa/master w/ AOSP/master.

I'm working with others to try to remedy this, but as a first
step I used some hacks to temporarily remove the build environment
restrictions, and unsuprizingly found mesa/master has a few
build issues when trying to build w/ freedreno.

So this patch set provides only some very basic build fixes
that are needed to get mesa/master building w/ AOSP/master
(minus the build restrictions on external tools).

Feedback would be greatly appreciated!

thanks
-john

Cc: Rob Clark <robdclark@chromium.org>
Cc: Emil Velikov <emil.l.velikov@gmail.com>
Cc: Amit Pundir <amit.pundir@linaro.org>
Cc: Sumit Semwal <sumit.semwal@linaro.org>
Cc: Alistair Strachan <astrachan@google.com>
Cc: Greg Hartman <ghartman@google.com>
Cc: Tapani Pälli <tapani.palli@intel.com>
Cc: Jason Ekstrand <jason@jlekstrand.net>

Alistair Strachan (1):
  mesa: android: Remove unnecessary dependency tracking rules

Amit Pundir (1):
  mesa: android: freedreno: build libfreedreno_{drm,ir3} static libs

John Stultz (1):
  mesa: android: freedreno: Fix build failure due to path change

 Android.mk                                   |  1 +
 src/compiler/Android.glsl.gen.mk             |  2 -
 src/compiler/Android.nir.gen.mk              |  2 -
 src/freedreno/Android.drm.mk                 | 41 ++++++++++++++++
 src/freedreno/Android.ir3.mk                 | 51 ++++++++++++++++++++
 src/freedreno/Android.mk                     | 30 ++++++++++++
 src/freedreno/Makefile.sources               |  2 +
 src/gallium/Android.common.mk                |  5 +-
 src/gallium/drivers/freedreno/Android.gen.mk |  2 +-
 src/gallium/drivers/freedreno/Android.mk     |  2 +-
 src/gallium/targets/dri/Android.mk           |  4 ++
 11 files changed, 135 insertions(+), 7 deletions(-)
 create mode 100644 src/freedreno/Android.drm.mk
 create mode 100644 src/freedreno/Android.ir3.mk
 create mode 100644 src/freedreno/Android.mk

Comments

Greg Hartman May 2, 2019, 8:19 p.m. UTC | #1
+ dwillemsen@google.com background on the build changes.

Thanks for doing this. It will be helpful to have fixes to make this build
again.

On Thu, May 2, 2019 at 11:03 AM John Stultz <john.stultz@linaro.org> wrote:

> Somewhat recent changes in the AOSP build system has been made
> which fairly severely restricts the build environment. This has
> made it difficult to test mesa/master w/ AOSP/master.
>
> I'm working with others to try to remedy this, but as a first
> step I used some hacks to temporarily remove the build environment
> restrictions, and unsuprizingly found mesa/master has a few
> build issues when trying to build w/ freedreno.
>
> So this patch set provides only some very basic build fixes
> that are needed to get mesa/master building w/ AOSP/master
> (minus the build restrictions on external tools).
>
> Feedback would be greatly appreciated!
>
> thanks
> -john
>
> Cc: Rob Clark <robdclark@chromium.org>
> Cc: Emil Velikov <emil.l.velikov@gmail.com>
> Cc: Amit Pundir <amit.pundir@linaro.org>
> Cc: Sumit Semwal <sumit.semwal@linaro.org>
> Cc: Alistair Strachan <astrachan@google.com>
> Cc: Greg Hartman <ghartman@google.com>
> Cc: Tapani Pälli <tapani.palli@intel.com>
> Cc: Jason Ekstrand <jason@jlekstrand.net>
>
> Alistair Strachan (1):
>   mesa: android: Remove unnecessary dependency tracking rules
>
> Amit Pundir (1):
>   mesa: android: freedreno: build libfreedreno_{drm,ir3} static libs
>
> John Stultz (1):
>   mesa: android: freedreno: Fix build failure due to path change
>
>  Android.mk                                   |  1 +
>  src/compiler/Android.glsl.gen.mk             |  2 -
>  src/compiler/Android.nir.gen.mk              |  2 -
>  src/freedreno/Android.drm.mk                 | 41 ++++++++++++++++
>  src/freedreno/Android.ir3.mk                 | 51 ++++++++++++++++++++
>  src/freedreno/Android.mk                     | 30 ++++++++++++
>  src/freedreno/Makefile.sources               |  2 +
>  src/gallium/Android.common.mk                |  5 +-
>  src/gallium/drivers/freedreno/Android.gen.mk |  2 +-
>  src/gallium/drivers/freedreno/Android.mk     |  2 +-
>  src/gallium/targets/dri/Android.mk           |  4 ++
>  11 files changed, 135 insertions(+), 7 deletions(-)
>  create mode 100644 src/freedreno/Android.drm.mk
>  create mode 100644 src/freedreno/Android.ir3.mk
>  create mode 100644 src/freedreno/Android.mk
>
> --
> 2.17.1
>
>
<div dir="ltr">+ <a href="mailto:dwillemsen@google.com">dwillemsen@google.com</a> background on the build changes.<div><br><div>Thanks for doing this. It will be helpful to have fixes to make this build again.</div></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, May 2, 2019 at 11:03 AM John Stultz &lt;<a href="mailto:john.stultz@linaro.org">john.stultz@linaro.org</a>&gt; wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Somewhat recent changes in the AOSP build system has been made<br>
which fairly severely restricts the build environment. This has<br>
made it difficult to test mesa/master w/ AOSP/master.<br>
<br>
I&#39;m working with others to try to remedy this, but as a first<br>
step I used some hacks to temporarily remove the build environment<br>
restrictions, and unsuprizingly found mesa/master has a few<br>
build issues when trying to build w/ freedreno.<br>
<br>
So this patch set provides only some very basic build fixes<br>
that are needed to get mesa/master building w/ AOSP/master<br>
(minus the build restrictions on external tools).<br>
<br>
Feedback would be greatly appreciated!<br>
<br>
thanks<br>
-john<br>
<br>
Cc: Rob Clark &lt;<a href="mailto:robdclark@chromium.org" target="_blank">robdclark@chromium.org</a>&gt;<br>
Cc: Emil Velikov &lt;<a href="mailto:emil.l.velikov@gmail.com" target="_blank">emil.l.velikov@gmail.com</a>&gt;<br>
Cc: Amit Pundir &lt;<a href="mailto:amit.pundir@linaro.org" target="_blank">amit.pundir@linaro.org</a>&gt;<br>
Cc: Sumit Semwal &lt;<a href="mailto:sumit.semwal@linaro.org" target="_blank">sumit.semwal@linaro.org</a>&gt;<br>
Cc: Alistair Strachan &lt;<a href="mailto:astrachan@google.com" target="_blank">astrachan@google.com</a>&gt;<br>
Cc: Greg Hartman &lt;<a href="mailto:ghartman@google.com" target="_blank">ghartman@google.com</a>&gt;<br>
Cc: Tapani Pälli &lt;<a href="mailto:tapani.palli@intel.com" target="_blank">tapani.palli@intel.com</a>&gt;<br>
Cc: Jason Ekstrand &lt;<a href="mailto:jason@jlekstrand.net" target="_blank">jason@jlekstrand.net</a>&gt;<br>
<br>
Alistair Strachan (1):<br>
  mesa: android: Remove unnecessary dependency tracking rules<br>
<br>
Amit Pundir (1):<br>
  mesa: android: freedreno: build libfreedreno_{drm,ir3} static libs<br>
<br>
John Stultz (1):<br>
  mesa: android: freedreno: Fix build failure due to path change<br>
<br>
 Android.mk                                   |  1 +<br>
 src/compiler/<a href="http://Android.glsl.gen.mk" rel="noreferrer" target="_blank">Android.glsl.gen.mk</a>             |  2 -<br>
 src/compiler/<a href="http://Android.nir.gen.mk" rel="noreferrer" target="_blank">Android.nir.gen.mk</a>              |  2 -<br>
 src/freedreno/<a href="http://Android.drm.mk" rel="noreferrer" target="_blank">Android.drm.mk</a>                 | 41 ++++++++++++++++<br>
 src/freedreno/<a href="http://Android.ir3.mk" rel="noreferrer" target="_blank">Android.ir3.mk</a>                 | 51 ++++++++++++++++++++<br>
 src/freedreno/Android.mk                     | 30 ++++++++++++<br>
 src/freedreno/Makefile.sources               |  2 +<br>
 src/gallium/<a href="http://Android.common.mk" rel="noreferrer" target="_blank">Android.common.mk</a>                |  5 +-<br>
 src/gallium/drivers/freedreno/<a href="http://Android.gen.mk" rel="noreferrer" target="_blank">Android.gen.mk</a> |  2 +-<br>
 src/gallium/drivers/freedreno/Android.mk     |  2 +-<br>
 src/gallium/targets/dri/Android.mk           |  4 ++<br>
 11 files changed, 135 insertions(+), 7 deletions(-)<br>
 create mode 100644 src/freedreno/<a href="http://Android.drm.mk" rel="noreferrer" target="_blank">Android.drm.mk</a><br>
 create mode 100644 src/freedreno/<a href="http://Android.ir3.mk" rel="noreferrer" target="_blank">Android.ir3.mk</a><br>
 create mode 100644 src/freedreno/Android.mk<br>
<br>
-- <br>
2.17.1<br>
<br>
</blockquote></div>
Rob Clark May 2, 2019, 8:31 p.m. UTC | #2
fyi, John pushed a MR w/ the same patches:
https://gitlab.freedesktop.org/mesa/mesa/merge_requests/795

(I'm not really an expert on android build system, but if it works,
then ack-by from me)

BR,
-R

On Thu, May 2, 2019 at 1:20 PM Greg Hartman <ghartman@google.com> wrote:
>
> + dwillemsen@google.com background on the build changes.
>
> Thanks for doing this. It will be helpful to have fixes to make this build again.
>
> On Thu, May 2, 2019 at 11:03 AM John Stultz <john.stultz@linaro.org> wrote:
>>
>> Somewhat recent changes in the AOSP build system has been made
>> which fairly severely restricts the build environment. This has
>> made it difficult to test mesa/master w/ AOSP/master.
>>
>> I'm working with others to try to remedy this, but as a first
>> step I used some hacks to temporarily remove the build environment
>> restrictions, and unsuprizingly found mesa/master has a few
>> build issues when trying to build w/ freedreno.
>>
>> So this patch set provides only some very basic build fixes
>> that are needed to get mesa/master building w/ AOSP/master
>> (minus the build restrictions on external tools).
>>
>> Feedback would be greatly appreciated!
>>
>> thanks
>> -john
>>
>> Cc: Rob Clark <robdclark@chromium.org>
>> Cc: Emil Velikov <emil.l.velikov@gmail.com>
>> Cc: Amit Pundir <amit.pundir@linaro.org>
>> Cc: Sumit Semwal <sumit.semwal@linaro.org>
>> Cc: Alistair Strachan <astrachan@google.com>
>> Cc: Greg Hartman <ghartman@google.com>
>> Cc: Tapani Pälli <tapani.palli@intel.com>
>> Cc: Jason Ekstrand <jason@jlekstrand.net>
>>
>> Alistair Strachan (1):
>>   mesa: android: Remove unnecessary dependency tracking rules
>>
>> Amit Pundir (1):
>>   mesa: android: freedreno: build libfreedreno_{drm,ir3} static libs
>>
>> John Stultz (1):
>>   mesa: android: freedreno: Fix build failure due to path change
>>
>>  Android.mk                                   |  1 +
>>  src/compiler/Android.glsl.gen.mk             |  2 -
>>  src/compiler/Android.nir.gen.mk              |  2 -
>>  src/freedreno/Android.drm.mk                 | 41 ++++++++++++++++
>>  src/freedreno/Android.ir3.mk                 | 51 ++++++++++++++++++++
>>  src/freedreno/Android.mk                     | 30 ++++++++++++
>>  src/freedreno/Makefile.sources               |  2 +
>>  src/gallium/Android.common.mk                |  5 +-
>>  src/gallium/drivers/freedreno/Android.gen.mk |  2 +-
>>  src/gallium/drivers/freedreno/Android.mk     |  2 +-
>>  src/gallium/targets/dri/Android.mk           |  4 ++
>>  11 files changed, 135 insertions(+), 7 deletions(-)
>>  create mode 100644 src/freedreno/Android.drm.mk
>>  create mode 100644 src/freedreno/Android.ir3.mk
>>  create mode 100644 src/freedreno/Android.mk
>>
>> --
>> 2.17.1
>>
John Stultz May 2, 2019, 8:38 p.m. UTC | #3
On Thu, May 2, 2019 at 1:31 PM Rob Clark <robdclark@chromium.org> wrote:
>
> fyi, John pushed a MR w/ the same patches:
> https://gitlab.freedesktop.org/mesa/mesa/merge_requests/795
>
> (I'm not really an expert on android build system, but if it works,
> then ack-by from me)
>

So there's one new issue that cropped up when I re-based, but I'll
have a fix for that here in a second and will update the MR.

thanks
-john
John Stultz May 2, 2019, 8:52 p.m. UTC | #4
On Thu, May 2, 2019 at 1:20 PM Greg Hartman <ghartman@google.com> wrote:
>
> + dwillemsen@google.com background on the build changes.
>
> Thanks for doing this. It will be helpful to have fixes to make this build again.
>

We're still a bit out from getting master to build w/ the current AOSP tree.

We need solutions for the xgettext and the python-mako usage.  The
current AOSP tree checks in prebuilt-intermediates that are hand
generated (which is messy to re-create), so I'm thinking we should
externalize the intermediate source generation into something like a
script, which the build system can call in the normal case, or that we
can run independently on a host to generate prebuilt intermediate
source files that can be checked into the AOSP tree.

But I wanted to get these basic fixes in so its easier to have working
before and after trees to compare any such build changes.

thanks
-john
Dan Willemsen May 2, 2019, 9:57 p.m. UTC | #5
On Thu, May 2, 2019 at 1:52 PM John Stultz <john.stultz@linaro.org> wrote:
>
> We need solutions for the xgettext and the python-mako usage.

 Android doesn't support translations at this level, so you may be
able to just skip xgettext altogether.

- Dan
Rob Clark May 2, 2019, 10:19 p.m. UTC | #6
On Thu, May 2, 2019 at 2:57 PM Dan Willemsen <dwillemsen@google.com> wrote:
>
> On Thu, May 2, 2019 at 1:52 PM John Stultz <john.stultz@linaro.org> wrote:
> >
> > We need solutions for the xgettext and the python-mako usage.
>
>  Android doesn't support translations at this level, so you may be
> able to just skip xgettext altogether.
>

from quick look, gettext is just needed for docs build (which I guess
android doesn't do) and driconf (not supported on android afaiu,
although it could be nice if there was a way to support something like
driconf on android, but I guess a different topic[1]).. so yeah,
probably not needed

[1] and maybe not needed for driconf itself but just for
infrastructure for driconf gui tool, which probably doesn't make sense
on android.. only use-case where I think it could make sense is
switches to enable workarounds for buggy apps, ie. allowing
buggy/incorrect glsl.. maybe that just isn't as much a problem on
android?

BR,
-R
Emil Velikov May 3, 2019, 10:41 a.m. UTC | #7
On Thu, 2 May 2019 at 23:19, Rob Clark <robdclark@chromium.org> wrote:
>
> On Thu, May 2, 2019 at 2:57 PM Dan Willemsen <dwillemsen@google.com> wrote:
> >
> > On Thu, May 2, 2019 at 1:52 PM John Stultz <john.stultz@linaro.org> wrote:
> > >
> > > We need solutions for the xgettext and the python-mako usage.
> >
> >  Android doesn't support translations at this level, so you may be
> > able to just skip xgettext altogether.
> >
>
> from quick look, gettext is just needed for docs build (which I guess
> android doesn't do) and driconf (not supported on android afaiu,
> although it could be nice if there was a way to support something like
> driconf on android, but I guess a different topic[1]).. so yeah,
> probably not needed
>
Pretty much what I've mentioned last time John brought the gettext
patches - simply disable/drop the thing for Android.

One of these days we should even look closely at these "wanna-be
translations, yet 90% not translated" and drop all together?

-Emil
Dylan Baker May 7, 2019, 6:32 p.m. UTC | #8
Quoting Emil Velikov (2019-05-03 03:41:42)
> On Thu, 2 May 2019 at 23:19, Rob Clark <robdclark@chromium.org> wrote:
> >
> > On Thu, May 2, 2019 at 2:57 PM Dan Willemsen <dwillemsen@google.com> wrote:
> > >
> > > On Thu, May 2, 2019 at 1:52 PM John Stultz <john.stultz@linaro.org> wrote:
> > > >
> > > > We need solutions for the xgettext and the python-mako usage.
> > >
> > >  Android doesn't support translations at this level, so you may be
> > > able to just skip xgettext altogether.
> > >
> >
> > from quick look, gettext is just needed for docs build (which I guess
> > android doesn't do) and driconf (not supported on android afaiu,
> > although it could be nice if there was a way to support something like
> > driconf on android, but I guess a different topic[1]).. so yeah,
> > probably not needed
> >
> Pretty much what I've mentioned last time John brought the gettext
> patches - simply disable/drop the thing for Android.
> 
> One of these days we should even look closely at these "wanna-be
> translations, yet 90% not translated" and drop all together?
> 
> -Emil

Eric Engrstrom and I talked about this some time ago, the translations are very
incomplete and out of date at this point. Unless someone wants to step up and
maintain them I'd be in favor of dropping them all together.

Dylan