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 674314 - Make gtk-doc not a hard dependency of GLib
Make gtk-doc not a hard dependency of GLib
Status: RESOLVED FIXED
Product: glib
Classification: Platform
Component: build
2.32.x
Other Linux
: Normal normal
: ---
Assigned To: gtkdev
gtkdev
Depends on:
Blocks:
 
 
Reported: 2012-04-18 10:06 UTC by Javier Jardón (IRC: jjardon)
Modified: 2012-08-05 13:36 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Make gtk-doc not a hard dependency of GLib (1.95 KB, patch)
2012-04-18 10:06 UTC, Javier Jardón (IRC: jjardon)
reviewed Details | Review
Make gtk-doc not a hard dependency of GLib.v2 (2.06 KB, patch)
2012-06-30 11:32 UTC, Javier Jardón (IRC: jjardon)
committed Details | Review

Description Javier Jardón (IRC: jjardon) 2012-04-18 10:06:07 UTC
Created attachment 212273 [details] [review]
Make gtk-doc not a hard dependency of GLib

Currently is difficult to compile GLib from VCS on macos/windows, as you need to ship shim layers for gnome-doc-tools and gtk-doc/doocbook-xsl, to build from git.

Post the patch here in case is useful for anyone
Comment 1 Colin Walters 2012-04-18 15:20:12 UTC
Review of attachment 212273 [details] [review]:

You might note that people can also use http://git.gnome.org/browse/gtk-doc-stub

::: autogen.sh
@@ +12,3 @@
+        echo "You don't have gtk-doc installed, and thus"
+        echo "won't be able to generate the documentation."
+        NOGTKDOC=1

Double-negative variables are confusing; call it "HAVE_GTK_DOC=no"  (and set HAVE_GTK_DOC=yes if we do have it ?

@@ +27,3 @@
 touch README INSTALL
 
+if test -z "$NOGTKDOC"; then

This would then be:

test x$HAVE_GTK_DOC = xyes

::: docs/Makefile.am
@@ +5,2 @@
 SUBDIRS = reference
+endif

I think to be nice, you want to add it to DIST_SUBDIRS if ENABLE_GTK_DOC is false.
Comment 2 Javier Jardón (IRC: jjardon) 2012-06-30 11:32:57 UTC
Created attachment 217696 [details] [review]
Make gtk-doc not a hard dependency of GLib.v2

New patch
Comment 3 Javier Jardón (IRC: jjardon) 2012-06-30 11:34:08 UTC
(In reply to comment #1)
> ::: autogen.sh
> @@ +12,3 @@
> +        echo "You don't have gtk-doc installed, and thus"
> +        echo "won't be able to generate the documentation."
> +        NOGTKDOC=1
> 
> Double-negative variables are confusing; call it "HAVE_GTK_DOC=no"  (and set
> HAVE_GTK_DOC=yes if we do have it ?

The new version doesnt have variables at all

> ::: docs/Makefile.am
> @@ +5,2 @@
>  SUBDIRS = reference
> +endif
> 
> I think to be nice, you want to add it to DIST_SUBDIRS if ENABLE_GTK_DOC is
> false.

I think this is automatically done by automake. See http://www.gnu.org/software/automake/manual/html_node/SUBDIRS-vs-DIST_005fSUBDIRS.html
Comment 4 Colin Walters 2012-06-30 13:48:52 UTC
Review of attachment 217696 [details] [review]:

The main question I have here is are you planning to patch all GNOME modules this way?  Or just GLib?  If the latter I can definitely understand, and agree it makes sense.  It would let oe-core drop some nasty code:
http://cgit.openembedded.org/openembedded-core/tree/meta/recipes-core/glib-2.0/glib-2.0_2.32.3.bb#n30

But if we're going beyond GLib into all of GNOME, I really think maintaining a module like gtk-doc-stub centrally is a lot saner than having it copied into each user.

::: autogen.sh
@@ +11,3 @@
 if test -z $GTKDOCIZE; then
+        echo "You don't have gtk-doc installed, and thus won't be able to generate the documentation."
+        echo 'EXTRA_DIST =' > gtk-doc.make

Is this really going to work?  You can see what I ended up needing in gtk-doc-stub here:
http://git.gnome.org/browse/gtk-doc-stub/tree/gtk-doc.make
Comment 5 Javier Jardón (IRC: jjardon) 2012-07-13 20:31:12 UTC
(In reply to comment #4)
> Review of attachment 217696 [details] [review]:
> 
> The main question I have here is are you planning to patch all GNOME modules
> this way?  Or just GLib?

No plans for other modules, just glib

> ::: autogen.sh
> @@ +11,3 @@
>  if test -z $GTKDOCIZE; then
> +        echo "You don't have gtk-doc installed, and thus won't be able to
> generate the documentation."
> +        echo 'EXTRA_DIST =' > gtk-doc.make
> 
> Is this really going to work?  You can see what I ended up needing in
> gtk-doc-stub here:
> http://git.gnome.org/browse/gtk-doc-stub/tree/gtk-doc.make

it works here, Its a similar patch as the systemd one
Comment 6 Colin Walters 2012-07-14 15:45:44 UTC
Review of attachment 217696 [details] [review]:

Ok.  Can you add a link to the bug in the patch?
Comment 7 Javier Jardón (IRC: jjardon) 2012-08-05 13:36:18 UTC
Comment on attachment 217696 [details] [review]
Make gtk-doc not a hard dependency of GLib.v2

commit 0f6a092cc5a1cc82a02b23e9daa15159319f929c