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 625862 - [docs] unused symbol GST_CAT_LEVEL_LOG_valist breaks the build
[docs] unused symbol GST_CAT_LEVEL_LOG_valist breaks the build
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gstreamer (core)
git master
Other Linux
: Normal normal
: 0.10.31
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2010-08-02 18:39 UTC by Víctor Manuel Jáquez Leal
Modified: 2010-08-05 14:41 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
adds the missing symbol in gkt-doc (1.78 KB, application/empty)
2010-08-02 18:39 UTC, Víctor Manuel Jáquez Leal
Details

Description Víctor Manuel Jáquez Leal 2010-08-02 18:39:46 UTC
Created attachment 167000 [details]
adds the missing symbol in gkt-doc

Because of the gtk-doc.mak, the compilation is broken if a gstreamer-unused.txt file is generated, and using HEAD the symbol GST_CAT_LEVEL_LOG_valist is found as unused.
Comment 1 Tim-Philipp Müller 2010-08-02 23:03:07 UTC
This symbol is private and not really supposed to be part of the API.

Is this enough to fix the build again for you?

diff --git a/docs/gst/gstreamer-sections.txt b/docs/gst/gstreamer-sections.txt
index 3f9920f..5cd498f 100644
--- a/docs/gst/gstreamer-sections.txt
+++ b/docs/gst/gstreamer-sections.txt
@@ -1046,6 +1046,7 @@ gst_debug_color_flags_get_type
 gst_debug_level_get_type
 gst_debug_graph_details_get_type
 M_PI
+GST_CAT_LEVEL_LOG_valist
 </SECTION>
 
 Is this with gtk-doc HEAD or what version of gtk-doc? (I don't get this with 1.15).
Comment 2 Víctor Manuel Jáquez Leal 2010-08-03 08:26:41 UTC
(In reply to comment #1)
> This symbol is private and not really supposed to be part of the API.
> 
> Is this enough to fix the build again for you?
> 
> diff --git a/docs/gst/gstreamer-sections.txt b/docs/gst/gstreamer-sections.txt
> index 3f9920f..5cd498f 100644
> --- a/docs/gst/gstreamer-sections.txt
> +++ b/docs/gst/gstreamer-sections.txt
> @@ -1046,6 +1046,7 @@ gst_debug_color_flags_get_type
>  gst_debug_level_get_type
>  gst_debug_graph_details_get_type
>  M_PI
> +GST_CAT_LEVEL_LOG_valist
>  </SECTION>
> 
>  Is this with gtk-doc HEAD or what version of gtk-doc? (I don't get this with
> 1.15).

I didn't notice the private subsection, so yes, adding the symbol there fixes the compilation (reference generation)

Thanks
Comment 3 Víctor Manuel Jáquez Leal 2010-08-03 08:27:34 UTC
(In reply to comment #1)
>  Is this with gtk-doc HEAD or what version of gtk-doc? (I don't get this with
> 1.15).

I'm using gtk-doc HEAD
Comment 4 Tim-Philipp Müller 2010-08-03 08:39:23 UTC
And out of curiosity: is this on Linux or Windows?
Comment 5 Víctor Manuel Jáquez Leal 2010-08-03 08:47:08 UTC
(In reply to comment #4)
> And out of curiosity: is this on Linux or Windows?

Linux.
Comment 6 Tim-Philipp Müller 2010-08-03 10:48:56 UTC
Still wonder why this breaks for you but not for me (I also have stuff in -unused.txt, but not this one).

Is that DOCS_ARE_INCOMPLETE_PLEASE_FIXME variable defined in your environment/.spec file/whatever?


commit 31ec8282b59632ab1a84b8d998a8183954485999
Author: Tim-Philipp Müller <tim.muller@collabora.co.uk>
Date:   Tue Aug 3 11:37:13 2010 +0100

    docs: fix build with gtk-doc from git
    
    For some reason the static inline function GST_CAT_LEVEL_LOG_valist is
    now picked up, which then breaks the build because it's not documented,
    so add it to the sections file.
    
    Based on patch by Víctor Manuel Jáquez Leal <vjaquez@igalia.com>.
    
    Fixes #625862.
Comment 7 Víctor Manuel Jáquez Leal 2010-08-03 11:15:25 UTC
(In reply to comment #6)
> Still wonder why this breaks for you but not for me (I also have stuff in
> -unused.txt, but not this one).
> 
> Is that DOCS_ARE_INCOMPLETE_PLEASE_FIXME variable defined in your
> environment/.spec file/whatever?
 
Nope, but without this patch a I got the following error:

*** Rebuilding template files ***
if test x"." != x. ; then \
            cp ./gstreamer-sections.txt . ; \
            touch gstreamer-decl.txt ; \
        fi
gtkdoc-mktmpl --module=gstreamer | tee tmpl-build.log
./gstreamer-decl.txt:9937: warning: GstTagList has multiple definitions.
./gstreamer-unused.txt:1: warning: 1 unused declarations.They should be added to gstreamer-sections.txt in the appropriate place.
make[1]: *** [tmpl-build.stamp] Error 1
make[1]: Leaving directory `/home/vjaquez/checkout/gnome2/gstreamer/docs/gst'
make: *** [all] Error 2

And the gstreamer-unused.txt file contains the symbol GST_CAT_LEVEL_LOG_valist

With this patch, if I run `make tmpl-build.stamp` everything goes smooth and no symbols are stored in gstreamer-unused.txt

I guess these lines in common/gtk-doc.mak throw this error

	@if test -s $(DOC_MODULE)-unused.txt; then \
	    exit $(if $(DOCS_ARE_INCOMPLETE_PLEASE_FIXME),0,1); fi

As you may see, the exit command is executed, only the result value changes if the $DOCS_ARE_INCOMPLETE_PLEASE_FIXME is set or not.
Comment 8 Tim-Philipp Müller 2010-08-05 13:59:21 UTC
For what it's worth, the exit 0 doesn't really seem to be a problem here (the following lines in the makefile are still executed), and I can reproduce this 

Let's do this then, I don't think it should error out for things like this anyway:

1f8914bdd3536d63d785aa5e8dbba725e4cad624
Author: Tim-Philipp Müller <tim.muller@collabora.co.uk>
Date:   Tue Aug 3 10:35:27 2010 +0100

    Revert "gtk-doc.mak: make build break on new api that has not been added to the sections file"
    
    This reverts commit 30c7a70b1d4765d26789950ca8e983284c0a05b3.
    
    Docs stuff should never break the build (it's fragile enough as it is), especially
    not when whether things break or not depends on factors outside of the source tree
    such as, for example, the gtk-doc version being used. Also, hooks like this are
    probably more appropriate for the check or distcheck target.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=625862

Hope this one works. If not, please re-open.
Comment 9 Víctor Manuel Jáquez Leal 2010-08-05 14:41:55 UTC
(In reply to comment #8)
> Hope this one works. If not, please re-open.

It works. Thanks.