Bug 96236 - dri_interface.h:404: error: redefinition of typedef ‘mesa_glinterop_device_info’
Summary: dri_interface.h:404: error: redefinition of typedef ‘mesa_glinterop_device_info’
Status: RESOLVED FIXED
Alias: None
Product: Mesa
Classification: Unclassified
Component: Mesa core (show other bugs)
Version: git
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: mesa-dev
QA Contact: mesa-dev
URL:
Whiteboard:
Keywords: regression
Depends on:
Blocks:
 
Reported: 2016-05-27 05:17 UTC by Vinson Lee
Modified: 2016-06-01 15:07 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments

Description Vinson Lee 2016-05-27 05:17:28 UTC
mesa: 8314dd7ff2c4719ffb64b202cf5fdd0e38ad276e (master 11.3.0-devel)

$ gcc --version
gcc (GCC) 4.4.7 20120313 (Red Hat 4.4.7-17)
Copyright (C) 2010 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.


  Compiling src/gallium/state_trackers/dri/dri2.c ...
In file included from src/mesa/drivers/dri/common/dri_util.h:57,
                 from src/gallium/state_trackers/dri/dri_screen.h:35,
                 from src/gallium/state_trackers/dri/dri2.c:48:
include/GL/internal/dri_interface.h:404: error: redefinition of typedef ‘mesa_glinterop_device_info’
include/GL/mesa_glinterop.h:116: note: previous declaration of ‘mesa_glinterop_device_info’ was here
include/GL/internal/dri_interface.h:405: error: redefinition of typedef ‘mesa_glinterop_export_in’
include/GL/mesa_glinterop.h:181: note: previous declaration of ‘mesa_glinterop_export_in’ was here
include/GL/internal/dri_interface.h:406: error: redefinition of typedef ‘mesa_glinterop_export_out’
include/GL/mesa_glinterop.h:236: note: previous declaration of ‘mesa_glinterop_export_out’ was here
Comment 1 Emil Velikov 2016-06-01 15:07:46 UTC
Should be fixed with

commit 13faddb6b8e30ff0e81e62fb863304a57c712aae
Author: Emil Velikov <emil.velikov@collabora.com>
Date:   Mon May 30 10:56:33 2016 +0100

    mesa_glinterop: remove mesa_glinterop typedefs
    
    As is there are two places that do the typedefs - dri_interface.h and
    this header. As we cannot include the former in here, just drop the
    typedefs and use the struct directly (as needed).
    
    This is required because typedef redefinition is C11 feature which is
    not supported on all the versions of GCC used to build mesa.
    
    v2: Kill the typedef alltogether, as per Marek.
    
    Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=96236
    Cc: Vinson Lee <vlee@freedesktop.org>
    Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
    Reviewed-by: Marek Olšák <marek.olsak@amd.com>


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.