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 366203 - error building using mawk
error building using mawk
Status: RESOLVED INCOMPLETE
Product: gnome-doc-utils
Classification: Deprecated
Component: build utils
CVS HEAD
Other Linux
: Normal normal
: ---
Assigned To: gnome-doc-utils maintainers
gnome-doc-utils maintainers
Depends on:
Blocks:
 
 
Reported: 2006-10-28 10:40 UTC by Frederic Peters
Modified: 2008-10-12 16:45 UTC
See Also:
GNOME target: ---
GNOME version: 2.17/2.18



Description Frederic Peters 2006-10-28 10:40:58 UTC
jhbuild spotted an error in building gnome-doc-utils:
  http://jhbuild.bxlug.be/builds/2006-10-28-0001/logs/gnome-doc-utils/#build

mawk: ./xsldoc.awk: line 57: syntax error at or near ,
mawk: ./xsldoc.awk: line 76: syntax error at or near else
mawk: ./xsldoc.awk: line 77: return outside function body
mawk: ./xsldoc.awk: line 79: syntax error at or near }

I am no awk expert and fixed this by switching from mawk to gawk (looks like
match() has no third argument in mawk).

This is on Debian unstable, with mawk 1.3.3 and gawk 3.1.5.
Comment 1 Shaun McCance 2006-10-28 16:04:27 UTC
Damn, I knew I'd end up using a GNUism.  It looks like I'll just have to rewrite things not to use the three-argument form.  That's a hassle, but it's not hard.
Comment 2 Craig Keogh 2006-11-03 08:22:54 UTC
Could we have a revert please? This is a build blocker.
I tried to fix it myself, but I don't understand what xsldoc.awk is doing.

match is documented here:
http://www.gnu.org/software/gawk/manual/gawk.html#String-Functions
Comment 3 Craig Keogh 2006-11-03 08:29:38 UTC
Disregard comment 2, I got it to build by installing gawk, and using that instead of mawk. Ubuntu (edgy) uses mawk by default, FYI.
Comment 4 Shaun McCance 2006-11-03 16:13:10 UTC
I've removed the use of the three-argument form of match and used only what I believe to be portable awk routines:

http://cvs.gnome.org/viewcvs/gnome-doc-utils/doc/xslt/xsldoc.awk?r1=1.1&r2=1.2

I don't have any other versions of awk, but I did check this with 'gawk --compat', so it should be OK.  Please test with mawk and respond.
Comment 5 André Klapper 2008-10-12 16:45:59 UTC
Closing this bug report as no further information has been provided. Please feel free to reopen this bug if you can provide the information asked for.
Thanks!