[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Build problems with 1.4.12 ...

From: Timshel Knoll
Subject: Build problems with 1.4.12 ...
Date: Tue, 22 May 2001 17:49:00 +1000
User-agent: Mutt/1.3.17i

Andrew ...

Your CFLAGS += -Werror might have backfired on you ;-)

Using gcc 2.95.4, I have a number of failures during the build:


fprintf() arguments need a cast to long.

diff -u -r1.1.1.2 -r1.2
--- ext2_inode_relocator.c      2001/05/22 06:35:27
+++ ext2_inode_relocator.c      2001/05/22 07:39:13     1.2
@@ -389,8 +389,8 @@
                                                "inode %li ref error! (->%li, 
[%i]={%i, %i})\n",
-                                               entry->num,
-                                               entry->dest,
+                                               (long) entry->num,
+                                               (long) entry->dest,
                                                (int) entry->ref[j].offset);


gcc -DHAVE_CONFIG_H -I. -I. -I.. -I../include     -O2 -D_REENTRANT 
-DLOCALEDIR="\"/usr/share/locale\"" -DLOCALEDIR="\"/usr/share/locale\"" -W 
-Wall -Wno-unused -Wno-switch -Werror -c ui.c
cc1: warnings being treated as errors
ui.c: In function `complete_function':
ui.c:315: warning: implicit declaration of function `completion_matches'
ui.c:315: warning: return makes pointer from integer without a cast
ui.c:317: warning: return makes pointer from integer without a cast
make[3]: *** [ui.o] Error 1

This is using readline 4.2 (the 4.2-3 debian package, to be specific).
In /usr/include/readline/readline.h, this is the only mention of

#if 0
/* Backwards compatibility (compat.c).  These will go away sometime. */
extern void free_undo_list __P((void));
extern int maybe_save_line __P((void));
extern int maybe_unsave_line __P((void));
extern int maybe_replace_line __P((void));

extern int ding __P((void));
extern int alphabetic __P((int));
extern int crlf __P((void));

extern char **completion_matches __P((char *, rl_compentry_func_t *));
extern char *username_completion_function __P((const char *, int));
extern char *filename_completion_function __P((const char *, int));

But there is this:

extern char **rl_completion_matches __P((const char *, rl_compentry_func_t *));

Looks like you're using an old readline ... all functions are prefixed
with rl_ now AFAICT ...

Also, once this is done, the completion functions need casts:

diff -u -r1.1.1.2 ui.c
--- ui.c        2001/05/22 06:35:28
+++ ui.c        2001/05/22 07:47:47
@@ -312,9 +312,11 @@
 complete_function (char* text, int start, int end)
        if (current_exception_opt)
-               return completion_matches (text, exception_command_generator);
+               return rl_completion_matches (text,
+                       (rl_compentry_func_t*) exception_command_generator);
-               return completion_matches (text, command_generator);
+               return rl_completion_matches (text,
+                       (rl_compentry_func_t*) command_generator);
 #endif /* HAVE_LIBREADLINE */

These patches fixes all compile failures on Debian sid (for me anyway ...)

Now let's see how it goes on other arches :-) I think that I might
disable -Werror for the purposes of packaging, it might well cause way
too many headaches otherwise ...

Also, your `type -p getconf' test doesn't work in shells like ash :-(
ash's `type' doesn't seem to support -p ... in fact it doesn't support
any options at all ... this has caused building on my main machine to
revert to using the llseek () syscall, as I have /bin/sh -> /bin/ash
on my system ... I've reverted to using `which' locally ... :-(



   Timshel Knoll <address@hidden>  for Debian email: <address@hidden>
                Geomatics/Computer Science double degree, RMIT
      Debian GNU/Linux developer, see http://people.debian.org/~timshel/
                For GnuPG public key: finger address@hidden

Attachment: pgp6AR6r5yCxe.pgp
Description: PGP signature

reply via email to

[Prev in Thread] Current Thread [Next in Thread]