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 501066 - Missing quotes around gtkdoc-rebase check cause a warning
Missing quotes around gtkdoc-rebase check cause a warning
Status: RESOLVED FIXED
Product: gtk-doc
Classification: Platform
Component: general
unspecified
Other Linux
: Normal normal
: 1.10
Assigned To: gtk-doc maintainers
gtk-doc maintainers
: 501617 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2007-12-02 17:32 UTC by Loïc Minier
Modified: 2007-12-05 14:57 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Add double-quotes around ` which gtkdoc-rebase` to prevent the warning (1.01 KB, patch)
2007-12-02 17:35 UTC, Loïc Minier
committed Details | Review

Description Loïc Minier 2007-12-02 17:32:39 UTC
Hi,

When building gtk-doc aware packages with --disable-gtk-doc in a chroot where gtk-doc isn't installed, the following test in gtk-doc.make causes a sh syntax warning:
    if test `which gtkdoc-rebase` != ""; then \

the warning is:
    /bin/sh: line 11: test: !=: unary operator expected

I think the `which gtkdoc-rebase` should be within double quotes:
    if test "`which gtkdoc-rebase`" != ""; then

Sample build logs with the error:
http://buildd.debian.org/fetch.cgi?&pkg=glib2.0&ver=2.14.4-2&arch=alpha&stamp=1196340485&file=log

Bye,
Comment 1 Loïc Minier 2007-12-02 17:35:49 UTC
Created attachment 100051 [details] [review]
Add double-quotes around ` which gtkdoc-rebase` to prevent the warning
Comment 2 Stefan Sauer (gstreamer, gtkdoc dev) 2007-12-04 06:55:49 UTC
Thanks for spotting and patch!

2007-12-02  Loïc Minier  <lool@dooz.org>

	* gtk-doc.make:
	* gtk-doc.notmpl.make:
	  Add double-quotes around `which gtkdoc-rebase` to prevent "test"
	  from failing with "/bin/sh: line 11: test: !=: unary operator
	  expected ".  Fixes #501066.
Comment 3 Stefan Sauer (gstreamer, gtkdoc dev) 2007-12-05 11:18:00 UTC
*** Bug 501617 has been marked as a duplicate of this bug. ***
Comment 4 Geert Stappers 2007-12-05 13:23:37 UTC
Bug 501617 is not a duplicate of this bug.
Comment 5 Stefan Sauer (gstreamer, gtkdoc dev) 2007-12-05 14:56:06 UTC
Better fix according to Bug 501617 committed.
Comment 6 Stefan Sauer (gstreamer, gtkdoc dev) 2007-12-05 14:57:13 UTC
*** Bug 501617 has been marked as a duplicate of this bug. ***