After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 643939 - Need ERROR_OBJCFLAGS: osxvideosink does not compile on OSX 10.5 due to -Waddress
Need ERROR_OBJCFLAGS: osxvideosink does not compile on OSX 10.5 due to -Waddress
Status: RESOLVED OBSOLETE
Product: GStreamer
Classification: Platform
Component: gst-plugins-good
0.10.27
Other Mac OS
: Normal enhancement
: git master
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2011-03-05 11:20 UTC by Ruben Vermeersch
Modified: 2013-07-17 10:27 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
config.log (160.51 KB, application/octet-stream)
2011-03-05 12:34 UTC, Ruben Vermeersch
Details
Same output, readable (4.30 KB, application/octet-stream)
2011-03-05 12:56 UTC, Ruben Vermeersch
Details

Description Ruben Vermeersch 2011-03-05 11:20:18 UTC
gst-plugins-good 0.10.27 uses -Waddress, which is not supported by the gcc version shipped by Apple on Mac OSX Leopard:


$ gcc --version
i686-apple-darwin9-gcc-4.0.1 (GCC) 4.0.1 (Apple Inc. build 5493)
Copyright (C) 2005 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.

$ gcc -Waddress -o test test.c 
cc1: error: unrecognized command line option "-Waddress"



While I could not test it, a look at [1] shows that this is still the case in git.
Perhaps it would be best to make the use of this flag conditional based on the GCC version?


[1] http://cgit.freedesktop.org/gstreamer/gst-plugins-good/tree/configure.ac
Comment 1 Sebastian Dröge (slomo) 2011-03-05 11:38:02 UTC
What's the output of configure? configure checks for all of the warning compiler flags if they're supported by the compiler before using them
Comment 2 Ruben Vermeersch 2011-03-05 12:34:04 UTC
Created attachment 182544 [details]
config.log

I've attached the config.log file, this should contain all the info you need, right?
Comment 3 Tim-Philipp Müller 2011-03-05 12:44:42 UTC
configure:24413: checking to see if compiler understands -Waddress
configure:24430: gcc-4.2 -std=gnu99 -c -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/include -D_XOPEN_SOURCE -isysroot /Developer/SDKs/MacOSX10.5.sdk -mmacosx-version-min=10.5 -m32 -arch i386 -Waddress -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/include -D_XOPEN_SOURCE -isysroot /Developer/SDKs/MacOSX10.5.sdk -mmacosx-version-min=10.5 -m32 -arch i386 conftest.c >&5
configure:24430: $? = 0
configure:24445: result: yes

No sign of any compiler warning/error/output (but note that configure seems to find/use gcc-4.2, but your gcc is 4.0.2).

What's the output of 'make' where it fails? (incl. 10 previous lines)
Comment 4 Ruben Vermeersch 2011-03-05 12:54:59 UTC
Apparently I also have gcc-4.2. However, gcc (without a version) refers to gcc 4.0.1.

Here's the output:


make -C oss4
make -C osxaudio
  CC     libgstosxaudio_la-gstosxringbuffer.lo
  CC     libgstoss4audio_la-oss4-audio.lo
  CC     libgstoss4audio_la-oss4-mixer.lo
  CC     libgstoss4audio_la-oss4-mixer-enum.lo
  CC     libgstoss4audio_la-oss4-mixer-slider.lo
  CC     libgstoss4audio_la-oss4-mixer-switch.lo
  CC     libgstosxaudio_la-gstosxaudioelement.lo
  CC     libgstoss4audio_la-oss4-property-probe.lo
  CC     libgstoss4audio_la-oss4-sink.lo
  CC     libgstosxaudio_la-gstosxaudiosink.lo
  CC     libgstoss4audio_la-oss4-source.lo
  CC     libgstosxaudio_la-gstosxaudiosrc.lo
  CCLD   libgstoss4audio.la
  CC     libgstosxaudio_la-gstosxaudio.lo
make -C osxvideo
  OBJC   libgstosxvideosink_la-osxvideosink.lo
cc1obj: error: unrecognized command line option "-Waddress"
make[3]: *** [libgstosxvideosink_la-osxvideosink.lo] Error 1
make[2]: *** [osxvideo] Error 2
make[2]: *** Waiting for unfinished jobs....
  CCLD   libgstosxaudio.la
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2

ERROR: command exited with exit code 512: make -j2


Running verbosely without -j2:


ake -C osxvideo
/bin/sh ../../libtool  --tag=disable-static  --mode=compile gcc -DHAVE_CONFIG_H -I. -I../..   -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/include -D_XOPEN_SOURCE -isysroot /Developer/SDKs/MacOSX10.5.sdk -mmacosx-version-min=10.5 -m32 -arch i386 -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/include -D_XOPEN_SOURCE -isysroot /Developer/SDKs/MacOSX10.5.sdk -mmacosx-version-min=10.5 -m32 -arch i386 -I../../gst-libs -D_REENTRANT -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/include/gstreamer-0.10 -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/include/glib-2.0 -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/lib/glib-2.0/include -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/include/libxml2    -DG_THREADS_MANDATORY -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wall -Wdeclaration-after-statement -Wpointer-arith -Wmissing-declarations -Wmissing-prototypes -Wredundant-decls -Wwrite-strings -Wold-style-definition -Winit-self -Wmissing-include-dirs -Waddress -Wno-multichar -Wnested-externs   -g    -D_REENTRANT -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/include/gstreamer-0.10 -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/include/glib-2.0 -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/lib/glib-2.0/include -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/include/libxml2   -D_REENTRANT -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/include/gstreamer-0.10 -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/include/glib-2.0 -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/lib/glib-2.0/include -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/include/libxml2   -Wno-aggregate-return  -MT libgstosxvideosink_la-osxvideosink.lo -MD -MP -MF .deps/libgstosxvideosink_la-osxvideosink.Tpo -c -o libgstosxvideosink_la-osxvideosink.lo `test -f 'osxvideosink.m' || echo './'`osxvideosink.m
libtool: compile:  gcc -DHAVE_CONFIG_H -I. -I../.. -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/include -D_XOPEN_SOURCE -isysroot /Developer/SDKs/MacOSX10.5.sdk -mmacosx-version-min=10.5 -m32 -arch i386 -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/include -D_XOPEN_SOURCE -isysroot /Developer/SDKs/MacOSX10.5.sdk -mmacosx-version-min=10.5 -m32 -arch i386 -I../../gst-libs -D_REENTRANT -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/include/gstreamer-0.10 -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/include/glib-2.0 -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/lib/glib-2.0/include -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/include/libxml2 -DG_THREADS_MANDATORY -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wall -Wdeclaration-after-statement -Wpointer-arith -Wmissing-declarations -Wmissing-prototypes -Wredundant-decls -Wwrite-strings -Wold-style-definition -Winit-self -Wmissing-include-dirs -Waddress -Wno-multichar -Wnested-externs -g -D_REENTRANT -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/include/gstreamer-0.10 -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/include/glib-2.0 -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/lib/glib-2.0/include -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/include/libxml2 -D_REENTRANT -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/include/gstreamer-0.10 -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/include/glib-2.0 -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/lib/glib-2.0/include -I/Users/ruben/Projects/bockbuild/profiles/banshee/build-root/_install/include/libxml2 -Wno-aggregate-return -MT libgstosxvideosink_la-osxvideosink.lo -MD -MP -MF .deps/libgstosxvideosink_la-osxvideosink.Tpo -c osxvideosink.m  -fno-common -DPIC -o .libs/libgstosxvideosink_la-osxvideosink.o
cc1obj: error: unrecognized command line option "-Waddress"
make[3]: *** [libgstosxvideosink_la-osxvideosink.lo] Error 1
make[2]: *** [osxvideo] Error 2
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2
Comment 5 Ruben Vermeersch 2011-03-05 12:56:08 UTC
Created attachment 182546 [details]
Same output, readable
Comment 6 Edward Hervey 2011-03-05 17:46:51 UTC
We normally check availability of compiler flags at configure time...

... but we only do that for CC/CXX and not for OBJC.
Comment 7 Sebastian Dröge (slomo) 2011-04-01 08:43:44 UTC
So we need all the checks for OBJC again and OBJC specific CFLAGS. Shouldn't be too hard to add, the same is already done for CXX in common/m4/gst-error.m4
Comment 8 Tim-Philipp Müller 2011-04-24 13:16:04 UTC
Not very elegant, but should hopefully help until we fix this properly:

 commit 85932c74df99d6d222c5e092db8354a24e717fa9
 Author: Tim-Philipp Müller <tim.muller@collabora.co.uk>
 Date:   Sun Apr 24 14:03:56 2011 +0100

    configure: don't pass -Waddress to ObjC compiler on OSX when compiling osxvideosink
    
    Temporary workaround until we fix this properly and check for
    the ObjC warning/error flags instead of just passing CFLAGS to the
    ObjC compiler.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=643939
Comment 9 Edward Hervey 2013-07-17 09:47:31 UTC
Haven't all those issues been fixed with latest osx commits in git master ?
Comment 10 Sebastian Dröge (slomo) 2013-07-17 10:27:14 UTC
Yes