[Bug 703885] [osx build] error: redefinition of typedef

GStreamer (bugzilla.gnome.org) bugzilla at gnome.org
Wed Jul 10 03:05:17 PDT 2013


https://bugzilla.gnome.org/show_bug.cgi?id=703885
  GStreamer | gst-plugins-gl | git

--- Comment #5 from Julien Isorce <julien.isorce at gmail.com> 2013-07-10 10:05:13 UTC ---
(In reply to comment #4)
> Ah, so the Apple compiler does not like duplicated typedefs? 

Yes:

The one that comes with Xcode to build apps on ios (Iphone/Ipad)

i686-apple-darwin11-llvm-gcc-4.2 (GCC) 4.2.1 (Based on Apple Inc. build 5658)
(LLVM build 2336.11.00)
Using built-in specs.
Target: i686-apple-darwin11
Configured with: /private/var/tmp/llvmgcc42/llvmgcc42-2336.11~182/src/configure
--disable-checking --enable-werror
--prefix=/Applications/Xcode.app/Contents/Developer/usr/llvm-gcc-4.2
--mandir=/share/man --enable-languages=c,objc,c++,obj-c++
--program-prefix=llvm- --program-transform-name=/^[cg][^.-]*$/s/$/-4.2/
--with-slibdir=/usr/lib --build=i686-apple-darwin11
--enable-llvm=/private/var/tmp/llvmgcc42/llvmgcc42-2336.11~182/dst-llvmCore/Developer/usr/local
--program-prefix=i686-apple-darwin11- --host=x86_64-apple-darwin11
--target=i686-apple-darwin11 --with-gxx-include-dir=/usr/include/c++/4.2.1
Thread model: posix
gcc version 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2336.11.00)



Same result when using Xcode and making a C project for OSX: "redefinition of
typedef is a C11 feature". And it seems that the apple compiler does not
support C11


I do not have the error with gcc that comes from macports:


gcc-mp-4.7 (MacPorts gcc47 4.7.3_1) 4.7.3
Using built-in specs.
COLLECT_GCC=gcc-mp-4.7
COLLECT_LTO_WRAPPER=/opt/local/libexec/gcc/x86_64-apple-darwin12/4.7.3/lto-wrapper
Target: x86_64-apple-darwin12
Configured with: ../gcc-4.7.3/configure --prefix=/opt/local
--build=x86_64-apple-darwin12
--enable-languages=c,c++,objc,obj-c++,lto,fortran,java
--libdir=/opt/local/lib/gcc47 --includedir=/opt/local/include/gcc47
--infodir=/opt/local/share/info --mandir=/opt/local/share/man
--datarootdir=/opt/local/share/gcc-4.7 --with-libiconv-prefix=/opt/local
--with-local-prefix=/opt/local --with-system-zlib --disable-nls
--program-suffix=-mp-4.7 --with-gxx-include-dir=/opt/local/include/gcc47/c++/
--with-gmp=/opt/local --with-mpfr=/opt/local --with-mpc=/opt/local
--with-ppl=/opt/local --with-cloog=/opt/local --enable-cloog-backend=isl
--disable-cloog-version-check --enable-stage1-checking --disable-multilib
--enable-lto --enable-libstdcxx-time --with-as=/opt/local/bin/as
--with-ld=/opt/local/bin/ld --with-ar=/opt/local/bin/ar
--with-bugurl=https://trac.macports.org/newticket --disable-ppl-version-check
--with-pkgversion='MacPorts gcc47 4.7.3_1'
Thread model: posix
gcc version 4.7.3 (MacPorts gcc47 4.7.3_1) 


> I wonder why we
> don't have that in GStreamer, I'm sure the same is used there in some places
> for circular includes...

I thought too so I did a quick search and I could not find one example from
GStreamer.

> 
> Is it a compiler warning or an error? And which are the circular includes and
> types involved?

Apparently GstGLDisplay, GstGLWindow, GstGLShader, GstGLDownload etc ...


Also I forgot to add lot of files in my patch, so a new patch follows!

-- 
Configure bugmail: https://bugzilla.gnome.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.


More information about the gstreamer-bugs mailing list