[Mesa-dev] [PATCH] android: fix outdir for gen_enum_to_str files

Mauro Rossi issor.oruam at gmail.com
Fri Mar 3 19:01:15 UTC 2017


2017-03-03 11:52 GMT+01:00 Tapani Pälli <tapani.palli at intel.com>:
> when files are being generated the value of $intermediates var content can be
> completely random, this makes sure that outdir is the wanted one.

The value of intermediates variable is local to the module and is set
at the line:

intermediates := $(call local-generated-sources-dir)

For confirmation, why is $(vulkan_api_xml) variable ok
and $(intermediates) not ok in the generation rules?

Mauro

>
> Fixes: 3f2cb699 ("android: vulkan: add support for libmesa_vulkan_util")
> Signed-off-by: Tapani Pälli <tapani.palli at intel.com>
> ---
>  src/vulkan/Android.mk | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/src/vulkan/Android.mk b/src/vulkan/Android.mk
> index 9f71d8f..7653f34 100644
> --- a/src/vulkan/Android.mk
> +++ b/src/vulkan/Android.mk
> @@ -1,4 +1,5 @@
>  # Copyright © 2017 Mauro Rossi <issor.oruam at gmail.com>
> +# Copyright © 2017 Intel Corporation
>  #
>  # Permission is hereby granted, free of charge, to any person obtaining a
>  # copy of this software and associated documentation files (the "Software"),
> @@ -45,7 +46,7 @@ vulkan_api_xml = $(MESA_TOP)/src/vulkan/registry/vk.xml
>  $(LOCAL_GENERATED_SOURCES): $(MESA_TOP)/src/vulkan/util/gen_enum_to_str.py $(vulkan_api_xml)
>         @echo "target Generated: $(PRIVATE_MODULE) <= $(notdir $(@))"
>         @mkdir -p $(dir $@)
> -       $(hide) $(MESA_PYTHON2) $(MESA_TOP)/src/vulkan/util/gen_enum_to_str.py --xml $(vulkan_api_xml) --outdir $(intermediates)/util
> +       $(hide) $(MESA_PYTHON2) $(MESA_TOP)/src/vulkan/util/gen_enum_to_str.py --xml $(vulkan_api_xml) --outdir $(dir $@)
>
>  LOCAL_EXPORT_C_INCLUDE_DIRS := \
>          $(intermediates)
> --
> 2.9.3
>


More information about the mesa-dev mailing list