On Fri, Apr 28, 2017 at 10:58 AM, Mauro Rossi <issor.or...@gmail.com> wrote: > 2017-04-28 14:23 GMT+02:00 Rob Herring <r...@kernel.org>: >> On Thu, Apr 27, 2017 at 9:50 PM, Chih-Wei Huang <cwhu...@android-x86.org> >> wrote: >>> A typo in the subject? >>> (s/building/build/) >> >> It's a bit misleading as originally I wrote it such that a blank >> BOARD_GPU_DRIVERS would enable all drivers, then changed it to "all". >> So it's not really a default anymore. >> >>> 2017-04-28 3:43 GMT+08:00 Rob Herring <r...@kernel.org>: >>>> If BOARD_GPU_DRIVERS is empty, build all the drivers. This doesn't >>>> enable building mesa as that is controlled by including libGLES_mesa in >>>> the product. >>>> >>>> Signed-off-by: Rob Herring <r...@kernel.org> >>>> --- >>>> Android.mk | 8 ++++++++ >>>> 1 file changed, 8 insertions(+) >>>> >>>> diff --git a/Android.mk b/Android.mk >>>> index 9f481ee7e109..76858c1616bc 100644 >>>> --- a/Android.mk >>>> +++ b/Android.mk >>>> @@ -1,3 +1,4 @@ >>>> + >>>> # Mesa 3-D graphics library >>>> # >>>> # Copyright (C) 2010-2011 Chia-I Wu <olva...@gmail.com> >>>> @@ -53,8 +54,15 @@ gallium_drivers := \ >>>> vc4.HAVE_GALLIUM_VC4 \ >>>> virgl.HAVE_GALLIUM_VIRGL >>>> >>>> +$(warning $(BOARD_GPU_DRIVERS)) >>>> + >>>> +ifeq ($(BOARD_GPU_DRIVERS),all) >>>> +MESA_BUILD_CLASSIC := $(filter HAVE_%, $(subst ., , $(classic_drivers))) >>>> +MESA_BUILD_GALLIUM := $(filter HAVE_%, $(subst ., , $(gallium_drivers))) >>>> +else >>>> MESA_BUILD_CLASSIC := $(strip $(foreach d, $(BOARD_GPU_DRIVERS), >>>> $(patsubst $(d).%,%, $(filter $(d).%, $(classic_drivers))))) >>>> MESA_BUILD_GALLIUM := $(strip $(foreach d, $(BOARD_GPU_DRIVERS), >>>> $(patsubst $(d).%,%, $(filter $(d).%, $(gallium_drivers))))) >>>> +endif >>>> $(foreach d, $(MESA_BUILD_CLASSIC) $(MESA_BUILD_GALLIUM), $(eval $(d) := >>>> true)) >>>> >>>> # host and target must be the same arch to generate matypes.h >>>> -- >>> >>> Aren't some drivers for arm or x86 only? >> >> In practice, yes. But they should build on all architectures so folks >> can easily build test. If the arm only ones required an arm compiler >> for example, then none of the x86 folks would build them and check >> that their changes don't break any drivers. >> >>> Is it really possible to build all drivers? >> >> Yes. That is what my CI job does. >> >> Rob > > Is it possible to leave a $(warning ) in case someone specifies a > new/wrong driver in BOARD_GPU_DRIVERS?
Okay. It wasn't immediately > In case I wanted to use mesa 17.2 to build swrast only, considering > that radeonsi/radeon require LLVM 3.8.0, how can I do that if mesa > builds everything? BOARD_GPU_DRIVERS=swrast > Why should we completely loose the possibility to control the list of > drivers in android, which is basically a one driver case (swrast) for > some android-x86 boards or when we could live with intel drivers like > in an Atom tablet? You haven't. The existing way to list drivers is unchanged externally. Rob _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev