tags 305524 patch
thanks

On Wed, Apr 20, 2005 at 08:26:12AM -0600, [EMAIL PROTECTED] wrote:
> Package: gconf
> Version: 1.0.9-7
> Severity: normal
> 
> There was an error while trying to build your package with gcc-4.0:
> 
> > Automatic build of gconf_1.0.9-7 on adare by sbuild/powerpc 1.170.5
> > Build started at 20050414-1618

> > gcc -DHAVE_CONFIG_H -I. -I. -I.. -I.. -I.. -I../gconf 
> > -I/usr/include/glib-1.2 -I/usr/lib/glib/include -I/usr/include/glib-1.2 
> > -I/usr/lib/glib/include -I/usr/include/orbit-1.0 -I/usr/include/glib-1.2 
> > -I/usr/lib/glib/include -I/usr/include/orbit-1.0 -I/usr/include/gnome-xml 
> > -DGCONF_ENABLE_INTERNALS=1 -DG_LOG_DOMAIN=\"GConf-Backends\" -g -O2 
> > -DGCONF2_DIR=\"/usr/lib/gconf2\" -Wall -DG_DISABLE_CHECKS=1 
> > -DG_DISABLE_ASSERT=1 -Wp,-MD,.deps/bdb.pp -c bdb.c  -fPIC -DPIC -o 
> > .libs/bdb.lo
> > bdb.c:336: error: static declaration of 'get_dir_id' follows non-static 
> > declaration
> > bdb.h:158: error: previous declaration of 'get_dir_id' was here
> > bdb.c:410: error: static declaration of 'get_or_create_dir' follows 
> > non-static declaration
> > bdb.h:161: error: previous declaration of 'get_or_create_dir' was here

I've attatched a simple patch that fixes these problems.

I've removed the static keywords at the definitions, since
get_dir_id() and get_or_create_dir() are documented in
doc/gconf/gconf-decl.txt. OTOH they aren't used anywhere else in the
source code, and the linker wouldn't have accepted this anyway.

With the patch the package compiles cleanly. I haven't tested it
though, since I don't use Gnome.

Cheers,
Christian Aichinger
--- gconf-1.0.9/backends/bdb.c  2001-10-17 05:43:01.000000000 +0200
+++ gconf/backends/bdb.c        2005-08-07 18:28:27.000000000 +0200
@@ -331,7 +331,7 @@
 
 /* } */
 
-static guint32
+guint32
 get_dir_id (BDB_Store * bdb, const char *dir)
 {
   int ret;
@@ -405,7 +405,7 @@
 
 /* { Functions to create directories and maintain the dir hierarchy */
 
-static guint32
+guint32
 get_or_create_dir (BDB_Store * bdb, const char *dir)
 {
   guint32 parent_id;

Attachment: signature.asc
Description: Digital signature

Reply via email to