GNOME Bugzilla – Bug 78256
Tru64 compilation problems with Glib 2.0.1
Last modified: 2004-12-22 21:47:04 UTC
Compiling on a Compaq Alpha under Tru64 Unix. I see that some of my previous issues have been resolved; great. Here are the current problems with Glib 2.0.1: gconvert.c: In function `open_converter': gconvert.c:369: warning: passing arg 3 of `g_iconv' from incompatible pointer type gconvert.c:369: warning: passing arg 5 of `g_iconv' from incompatible pointer type gutils.c: In function `g_get_any_init': gutils.c:799: warning: unused variable `error' from gspawn.c:28: /usr/local/lib/gcc-lib/alpha-dec- osf4.0d/2.8.1/include/sys/param.h:356: warning: `MIN' redefined ../glib/gmacros.h:137: warning: this is the location of the previous definition /usr/local/lib/gcc-lib/alpha-dec- osf4.0d/2.8.1/include/sys/param.h:357: warning: `MAX' redefined ../glib/gmacros.h:134: warning: this is the location of the previous definition testglib.c: In function `main': testglib.c:929: warning: field width is not type int (arg 2) testglib.c:929: warning: unknown conversion type character `1' in format $ gdb testglib (gdb) run Starting program: /usr/users/coul1358/glib- 2.0.1/tests/testglib Program received signal SIGSEGV, Segmentation fault. 0x3ff800d758c in __memccpy () (gdb) bt
+ Trace 20635
The gspawn.c warning seems to be a compiler/system header bug. There is no reason to include sys/param.h from gspawn.c. The testglib.c warning is a quality-of- implementation issue with printf on your system: it cannot handle %10000.10000f, which is admittedly a bit silly as a format - the test is disabled for win32, where it seems to cause similar problems. I propose to just remove the %10000.10000f test, since this limitation is unlikely to cause problems in practise. The glibc implementation of printf seems to have no limits in this area, it happly works with %100000.100000f. It would be interesting to learn where the various systems have their limit wrt to precision and width, sysconf doesn't seem to provide this information.
*** This bug has been marked as a duplicate of 78197 ***
Didn't really want to mark this one as a duplicate, though the segfault part is a duplicate of that bug.
The gconvert warnings indicate non-compliance on Tru64's part with SUSv3, and since they are harmless can be ignored. The gspawn warning will go with the patch in bug 71704 It looks to me like the testglib warning is not on the %10000.10000f line, but instead on the positional parameters line: tmp_string = g_strdup_printf ("%2$*1$s", 5, "c"); It looks like your version of GCC doesn't support positional parameters. Recent versions (post-2.95?) do. *** This bug has been marked as a duplicate of 81669 ***