[Mesa-dev] [PATCH] android: virgl: fix libmesa_virgil_common build and dependencies

Mauro Rossi issor.oruam at gmail.com
Sat Jun 29 15:19:49 UTC 2019


Hi,

On Tue, Jun 25, 2019 at 12:07 PM Chih-Wei Huang <cwhuang at android-x86.org>
wrote:

> Mauro Rossi <issor.oruam at gmail.com> 於 2019年6月25日 週二 下午5:52寫道:
> >
> > Hi,
> >
> > On Mon, Jun 24, 2019 at 8:55 AM Chih-Wei Huang <cwhuang at android-x86.org>
> wrote:
> >>
> >> Mauro Rossi <issor.oruam at gmail.com> 於 2019年6月15日 週六 下午1:39寫道:
> >> >
> >> > Fixes the following building errors and resolves Bug 110922
> >> > Fixes gallium_dri target missing symbols at linking.
> >> >
> >> > external/mesa/src/gallium/winsys/virgl/drm/Android.mk:
> >> > error: libmesa_winsys_virgl (STATIC_LIBRARIES android-x86_64) missing
> libmesa_winsys_virgl_common (STATIC_LIBRARIES android-x86_64)
> >> > ...
> >> > external/mesa/src/gallium/winsys/virgl/vtest/Android.mk:
> >> > error: libmesa_winsys_virgl_vtest (STATIC_LIBRARIES android-x86_64)
> missing libmesa_winsys_virgl_common (STATIC_LIBRARIES android-x86_64)
> >> > ...
> >> > build/core/main.mk:728: error: exiting from previous errors.
> >> >
> >> > In file included from
> external/mesa/src/gallium/winsys/virgl/vtest/virgl_vtest_socket.c:34:
> >> >
> external/mesa/src/gallium/winsys/virgl/vtest/virgl_vtest_winsys.h:35:10:
> >> > fatal error: 'virgl_resource_cache.h' file not found
> >> >          ^~~~~~~~~~~~~~~~~~~~~~~~
> >> > 1 error generated.
> >> >
> >> > In file included from
> external/mesa/src/gallium/winsys/virgl/vtest/virgl_vtest_winsys.c:32:
> >> >
> external/mesa/src/gallium/winsys/virgl/vtest/virgl_vtest_winsys.h:35:10:
> >> > fatal error: 'virgl_resource_cache.h' file not found
> >> > #include "virgl_resource_cache.h"
> >> >          ^~~~~~~~~~~~~~~~~~~~~~~~
> >> > 1 error generated.
> >> >
> >> > Fixes: b18f09a ("virgl: Introduce virgl_resource_cache")
> >> > Signed-off-by: Mauro Rossi <issor.oruam at gmail.com>
> >> > ---
> >> >  src/gallium/Android.mk                    | 2 +-
> >> >  src/gallium/drivers/virgl/Android.mk      | 2 +-
> >> >  src/gallium/winsys/virgl/drm/Android.mk   | 2 ++
> >> >  src/gallium/winsys/virgl/vtest/Android.mk | 2 ++
> >> >  4 files changed, 6 insertions(+), 2 deletions(-)
> >> >
> >> > diff --git a/src/gallium/Android.mk b/src/gallium/Android.mk
> >> > index 3a3f042c7a..37e923c225 100644
> >> > --- a/src/gallium/Android.mk
> >> > +++ b/src/gallium/Android.mk
> >> > @@ -43,7 +43,7 @@ SUBDIRS += winsys/radeon/drm drivers/r300
> >> >  SUBDIRS += winsys/radeon/drm drivers/r600
> >> >  SUBDIRS += winsys/radeon/drm winsys/amdgpu/drm drivers/radeonsi
> >> >  SUBDIRS += winsys/vc4/drm drivers/vc4
> >> > -SUBDIRS += winsys/virgl/drm winsys/virgl/vtest drivers/virgl
> >> > +SUBDIRS += winsys/virgl/common winsys/virgl/drm winsys/virgl/vtest
> drivers/virgl
> >> >  SUBDIRS += winsys/svga/drm drivers/svga
> >> >  SUBDIRS += winsys/etnaviv/drm drivers/etnaviv drivers/renderonly
> >> >  SUBDIRS += state_trackers/dri
> >> > diff --git a/src/gallium/drivers/virgl/Android.mk
> b/src/gallium/drivers/virgl/Android.mk
> >> > index 0067dfa702..a6fe53fbe9 100644
> >> > --- a/src/gallium/drivers/virgl/Android.mk
> >> > +++ b/src/gallium/drivers/virgl/Android.mk
> >> > @@ -35,5 +35,5 @@ include $(BUILD_STATIC_LIBRARY)
> >> >
> >> >  ifneq ($(HAVE_GALLIUM_VIRGL),)
> >> >  GALLIUM_TARGET_DRIVERS += virtio_gpu
> >> > -$(eval GALLIUM_LIBS += $(LOCAL_MODULE) libmesa_winsys_virgl
> libmesa_winsys_virgl_vtest)
> >> > +$(eval GALLIUM_LIBS += $(LOCAL_MODULE) libmesa_winsys_virgl_common
> libmesa_winsys_virgl libmesa_winsys_virgl_vtest)
> >> >  endif
> >> > diff --git a/src/gallium/winsys/virgl/drm/Android.mk
> b/src/gallium/winsys/virgl/drm/Android.mk
> >> > index 5e2500774e..398a7645bc 100644
> >> > --- a/src/gallium/winsys/virgl/drm/Android.mk
> >> > +++ b/src/gallium/winsys/virgl/drm/Android.mk
> >> > @@ -27,6 +27,8 @@ include $(CLEAR_VARS)
> >> >
> >> >  LOCAL_SRC_FILES := $(C_SOURCES)
> >> >
> >> > +LOCAL_C_INCLUDES := $(GALLIUM_TOP)/winsys/virgl/common
> >>
> >> This should be unnecessary.
> >> The include path should be imported automatically.
> >> However, there is a typo in Android.mk of libmesa_winsys_virgl_common
> >> that prevents it from working. We should fix the typo instead of adding
> this.
> >> Will send a patch later.
> >
> >
> > I was also thinking the LOCAL_C_INCLUDES un-necessary,
> > but for some reason fatal error: '*.h' file not found was happening
> without this
> >
> > I double checked prior to submit the patch with the LOCAL_C_INCLUDES
> >
> >>
> >>
> >> > +
> >> >  LOCAL_MODULE := libmesa_winsys_virgl
> >> >
> >> >  LOCAL_STATIC_LIBRARIES := libmesa_winsys_virgl_common
> >> > diff --git a/src/gallium/winsys/virgl/vtest/Android.mk
> b/src/gallium/winsys/virgl/vtest/Android.mk
> >> > index 5b33f67711..6d35223c8e 100644
> >> > --- a/src/gallium/winsys/virgl/vtest/Android.mk
> >> > +++ b/src/gallium/winsys/virgl/vtest/Android.mk
> >> > @@ -27,6 +27,8 @@ include $(CLEAR_VARS)
> >> >
> >> >  LOCAL_SRC_FILES := $(C_SOURCES)
> >> >
> >> > +LOCAL_C_INCLUDES := $(GALLIUM_TOP)/winsys/virgl/common
> >>
> >> Ditto
> >
> >
> > Same comment here
> > The patch has been already commited to master to at least avoid the
> building errors
> >
> > If you find more correct way, please submit new patch to mesa-dev
>
> As said, the more correct way is to fix the typo
> in Android.mk of libmesa_winsys_virgl_common.
> I've submitted the patch.
>
> https://www.mail-archive.com/mesa-dev@lists.freedesktop.org/msg219133.html
>
>
> --
> Chih-Wei
> Android-x86 project
> http://www.android-x86.org


Thanks, I've tested and committed that patch
Mauro
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20190629/26f66c76/attachment.html>


More information about the mesa-dev mailing list