GNOME Bugzilla – Bug 144592
compile fails on /bin/sh: -c: line 1: syntax error near unexpected token `;' in en folder
Last modified: 2004-12-22 21:47:04 UTC
During the compile of dia-0.93 I'm encountering this issue when installing the en folder whcih doesn't exists in dia-0.93 Making install in en /bin/sh: -c: line 1: syntax error near unexpected token `;' /bin/sh: -c: line 1: `for file in ; do scrollkeeper-preinstall /usr/test/garnome2/share/gnome/help/dia/en/dia.xml ./$file $file.out; done; touch omf_timestamp' /usr/bin/ginstall -c -m 644 ./dia.1 /usr/test/garnome2/man/man1/dia.1 /bin/sh: -c: line 1: syntax error near unexpected token `;' /bin/sh: -c: line 1: `for file in ; do /usr/bin/ginstall -c -m 644 $file.out /usr/test/garnome2/share/omf/dia/$file; done' make[6]: *** [install-data-hook-omf] Error 2 make[5]: *** [install-data-am] Error 2 make[4]: *** [install-am] Error 2 make[3]: *** [install-recursive] Error 1 make[2]: *** [install-recursive] Error 1 make[1]: *** [install-work/main.d/dia-0.93/Makefile] Error 2 make: *** [paranoid-install] Error 2 bash-2.05$ pwd /usr/download/projects/garnome--kenny--2.7--patch-4/garnome/office I'm using garnome gnome 2.7 gcc-3.4.0,glibc-2.3.2
I'm also seeing this (in stage "make install DESTDIR=..."), trying to compile dia 0.94 on Sparc/Solaris, gtk+ 2.2.4, glib 2.1.5, gcc 3.4.1. The problem seems to be that $omffile must not be empty in this case: Earlier in the output, there is: for file in ; do \ scrollkeeper-preinstall /usr/local/share/gnome/help/dia/en/dia.xml ./$file $file.out; \ done; \ touch omf_timestamp /bin/bash: -c: line 1: syntax error near unexpected token `;' /bin/bash: -c: line 1: `for file in ; do scrollkeeper-preinstall /usr/local/share/gnome/help/dia/en/dia.xml ./$file $file.out; done; touch omf_timestamp' gmake[3]: [omf_timestamp] Error 2 (ignored) which does not make the whole thing stop. However, the following does: for file in ; do \ /usr/public/bin/install -c -m 644 $file.out /tmp/gnome_root/dia-0.94/usr/local/share/omf/dia/$file; \ done /bin/bash: -c: line 1: syntax error near unexpected token `;' /bin/bash: -c: line 1: `for file in ; do /usr/public/bin/install -c -m 644 $file.out /tmp/gnome_root/dia-0.94/usr/local/share/omf/dia/$file; done' gmake[4]: *** [install-data-hook-omf] Error 2 HTH
I've not seen the problem anymore when I upgraded to garnome-2.8 (the stable branch for gnome-2.8) and gcc-3.4.2 compiling dia-0.94.
So this can be closed as fixed (by time;), couldn't it?
For me Yes. I don't know about Jens though
I can't simply upgrade from GTK 2.2 to GTK 2.8. A lot of other things might break just because of this which means more work for me. I think it's a little too easy to say it's fixed unless you mention somewhere that dia requires GTK 2.8. Currently, you don't - which implies that it should work with GTK 2.x, which is not true if this bug stays FIXED.
We definitely don't want to require 2.8 yet, it's too recent. 2.4 is fine, 2.6 I'd want to hear how far into distros it is. Could you check if it works with gtk 2.4/2.6?
I'm on Sparc/Solaris, no distro - i.e. everything has to be compiled. Much work. Maybe Stef can help.
I'm also using Solaris 9/SPARC and AFAIK, I've successfully compiled dia. Not sure if I was using patches to do so, but I surely remember, there are some GNOME applications which have the same problem as pointed here. I will check my patch list at work. Oh, and I'm using GNOME 2.6.2 (with many apps pushed to latest stable versions).
Created attachment 33357 [details] [review] Hack to make omf.make work (maybe)
Could you try the patch attached? It hacks the omf.make file to not try empty for loops. Not that a bash that dies on empty loops is nice, but this may help for now.
The patch did not work. I guess this is because the (first) error appears in doc/en which you couldn't see from what I posted (sorry for that). Maybe it would work if we would patch doc/en/Makefile and doc/pl/Makefile as well. Just do a "grep -r omffile *" to see if there is more to be done. "Dumb" question: Why is this variable empty at all?
I'm currently compiling with GTK+ 2.4.13. This works fine. I've long gone from gtk+ 2.2.*
Dumb answer: Because I don't know what should be put in it. Docs are rather skimpy, do you have an idea? You'll have to recreate the Makefiles by running ./autogen.sh and ./configure.in first. It doesn't reliably recreate them, and the Makefile.am's include the fixed files.
No idea, sorry. I'm not familiar with dia and its internals at all. About autogen.sh: I first need to upgrade autoconf (version 2.57 installed). However, not all hunks succeed (autogen.sh output): Running gettextize... Copying file po/Makefile.in.in Please add the files codeset.m4 gettext.m4 glibc21.m4 iconv.m4 isc-posix.m4 lcmessage.m4 progtest.m4 from the /usr/local/share/aclocal directory to your autoconf macro directory or directly to your aclocal.m4 file. You will also need config.guess and config.sub, which you can get from ftp://ftp.gnu.org/pub/gnu/config/. Running intltoolize patching file po/Makefile.in.in Hunk #1 succeeded at 21 (offset 7 lines). Hunk #2 FAILED at 46. Hunk #3 succeeded at 88 with fuzz 2 (offset -4 lines). Hunk #4 succeeded at 207 (offset -11 lines). Hunk #5 succeeded at 225 (offset -4 lines). 1 out of 5 hunks FAILED -- saving rejects to file po/Makefile.in.in.rej Running libtoolize You should update your `aclocal.m4' by running aclocal. aclocal: configure.in: 55: macro `AM_PATH_GLIB_2_0' not found in library aclocal: configure.in: 56: macro `AM_PATH_GTK_2_0' not found in library aclocal: configure.in: 234: macro `AM_GLIB_GNU_GETTEXT' not found in library configure.in:5: error: Autoconf version 2.58 or higher is required aclocal.m4:7437: AM_INIT_AUTOMAKE is expanded from... configure.in:5: the top level autom4te: /usr/public/bin/gm4 failed with exit status: 1 autoheader: /usr/public/bin/autom4te failed with exit status: 1 configure.in:5: error: Autoconf version 2.58 or higher is required aclocal.m4:7437: AM_INIT_AUTOMAKE is expanded from... configure.in:5: the top level autom4te: /usr/public/bin/gm4 failed with exit status: 1 configure.in: `AM_INIT_AUTOMAKE' must be used automake: no `Makefile.am' found or specified configure.in:5: error: Autoconf version 2.58 or higher is required aclocal.m4:7437: AM_INIT_AUTOMAKE is expanded from... configure.in:5: the top level autom4te: /usr/public/bin/gm4 failed with exit status: 1 You may want to run ./configure --enable-maintainer-mode --enable-db2html to build dia Anyone with successfully updated files? Would ease testing for me...
Did some updates: autoconf 2.59 automake 1.9.3 GTK 2.4.13 More problems...: patching file omf.make + ./autogen.sh Running gettextize... Copying file mkinstalldirs Copying file po/Makefile.in.in Please add the files codeset.m4 gettext.m4 glibc21.m4 iconv.m4 isc-posix.m4 lcmessage.m4 progtest.m4 from the /usr/local/share/aclocal directory to your autoconf macro directory or directly to your aclocal.m4 file. You will also need config.guess and config.sub, which you can get from ftp://ftp.gnu.org/pub/gnu/config/. Running intltoolize Looks like a unified context diff. Hunk #2 failed at line 38. Hunk #3 failed at line 88. Hunk #4 failed at line 219. Hunk #5 succeeded at 212 (offset 4 lines) 3 out of 5 hunks failed: saving rejects to po/Makefile.in.in.rej done Running libtoolize You should update your `aclocal.m4' by running aclocal. /usr/local/share/aclocal/xml-i18n-tools.m4:24: warning: underquoted definition of XML_I18N_TOOLS_NEWER_THAN_0_9 (... many more warnings of the same type skipped ...) You may want to run ./configure --enable-maintainer-mode --enable-db2html to build dia + exit 0 Executing(%build): /bin/sh -e /tmp/rpm-tmp.28888 + umask 022 + cd /software/work/packages/BUILD + cd dia-0.94 + [ -d /tmp/gnome_root/dia-0.94 ] + ./configure --prefix=/usr/local CC=cc LDFLAGS=-R/usr/local/lib -L/usr/local/lib checking for a BSD-compatible install... /usr/public/bin/install -c checking whether build environment is sane... yes checking for gawk... gawk checking whether make sets $(MAKE)... yes checking for gcc... cc checking for C compiler default output file name... a.out checking whether the C compiler works... yes checking whether we are cross compiling... no checking for suffix of executables... checking for suffix of object files... o checking whether we are using the GNU C compiler... no checking whether cc accepts -g... yes checking for cc option to accept ANSI C... none needed checking for style of include used by make... GNU checking dependency style of cc... none checking whether we are using the GNU C++ compiler... no checking whether CC accepts -g... yes checking dependency style of CC... none checking whether to enable maintainer-specific portions of Makefiles... no checking build system type... sparc-sun-solaris2.8 checking host system type... sparc-sun-solaris2.8 checking for ranlib... ranlib checking for non-GNU ld... /usr/ccs/bin/ld checking if the linker (/usr/ccs/bin/ld) is GNU ld... no checking for BSD-compatible nm... /usr/ccs/bin/nm -p checking whether ln -s works... yes loading cache /dev/null within ltconfig ./ltconfig: .: /dev/null: not a regular file ltconfig: you must specify a host type if you use `--no-verify' Try `ltconfig --help' for more information. configure: error: libtool configure failed Bad exit status from /tmp/rpm-tmp.28888 (%build)
Hmmm... that's the same place I've gotten to with compiling on Mac OS X.