commit dde09030ca67710a4ec0aea0b77b6d324273f8f7
parent b430ac8263ea12b5b9095efcd546e026d5ab260a
Author: Christian Grothoff <christian@grothoff.org>
Date: Thu, 16 Jul 2009 20:16:46 +0000
Fixing compilation errors --
Von:
Daniel Baumann <daniel@debian.org> (Debian GNU/Linux - The Universal Operating System)
An:
Kopie:
Christian Grothoff <christian@grothoff.org>
Datum:
Heute 14:58:30
Hi,
gnunet-fuse fails to build from source, original bug is #536998.
> Relevant part:
>> gcc -DHAVE_CONFIG_H -I. -DFUSE_USE_VERSION=26 -D_REENTRANT -I/usr/include -g -O2 -Wall -W -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -D_FILE_OFFSET_BITS=64 -I/usr/include/fuse -MT gnunet_fs-directory.o -MD -MP -MF .deps/gnunet_fs-directory.Tpo -c -o gnunet_fs-directory.o `test -f 'directory.c' || echo './'`directory.c
>> directory.c: In function 'directory_cache_locked':
>> directory.c:139: warning: passing argument 4 of 'GNUNET_ECRS_directory_list_contents' from incompatible pointer type
>> directory.c:139: warning: passing argument 5 of 'GNUNET_ECRS_directory_list_contents' from incompatible pointer type
>> directory.c:139: warning: passing argument 6 of 'GNUNET_ECRS_directory_list_contents' from incompatible pointer type
>> directory.c:139: error: too few arguments to function 'GNUNET_ECRS_directory_list_contents'
>> directory.c: In function 'gn_directory_upload_locked':
>> directory.c:382: warning: passing argument 3 of 'GNUNET_ECRS_directory_create' from incompatible pointer type
>> directory.c:410: warning: passing argument 8 of 'GNUNET_ECRS_file_upload' from incompatible pointer type
>> make[2]: *** [gnunet_fs-directory.o] Error 1
>
> The full build log is available from:
> http://people.debian.org/~lucas/logs/2009/07/13/gnunet-fuse_0.8.0-4_lsid64.buildlog
would be nice if you could have a look at it.
Regards,
Daniel
Diffstat:
5 files changed, 8 insertions(+), 5 deletions(-)
diff --git a/configure.ac b/configure.ac
@@ -29,6 +29,7 @@ AC_ARG_WITH(gnunet,
LDFLAGS="-L$with_gnunet/lib $LDFLAGS"
LIBPATH="$with_gnunet/lib $LIBPATH"
CPPFLAGS="-I$with_gnunet/include $CPPFLAGS"
+ CFLAGS="-I$with_gnunet/include $CFLAGS"
INCLUDEPATH="$with_gnunet/include $INCLUDEPATH"
AC_CHECK_HEADERS(GNUnet/gnunet_ecrs_lib.h,
AC_CHECK_LIB([gnunetecrs], [GNUNET_ECRS_file_download_partial],
diff --git a/directory.c b/directory.c
@@ -295,7 +295,8 @@ out_err:
return -1;
}
-static void upcb(guint64 totalBytes, guint64 completedBytes, GNUNET_CronTime eta,
+static void upcb(unsigned long long totalBytes,
+ unsigned long long completedBytes, GNUNET_CronTime eta,
void *closure)
{
(void)totalBytes;
@@ -357,7 +358,7 @@ int gn_directory_upload_locked(struct dirent *de)
{
int i, ret, fd;
char *buf, filename[] = GN_MKSTEMP_FILE;
- guint64 len;
+ unsigned long long len;
struct GNUNET_ECRS_URI *uri;
struct dir_upload_data d;
diff --git a/file.c b/file.c
@@ -36,7 +36,8 @@ static int tt(void *cls)
return GNUNET_OK;
}
-static void upcb(guint64 totalBytes, guint64 completedBytes, GNUNET_CronTime eta,
+static void upcb(unsigned long long totalBytes,
+ unsigned long long completedBytes, GNUNET_CronTime eta,
void *closure)
{
(void)totalBytes;
diff --git a/main.c b/main.c
@@ -144,7 +144,7 @@ int main(int argc, char **argv)
gn_dirent_cache_init();
if(GNUNET_disk_file_test(ectx, argv[i]) == GNUNET_YES)
{
- guint64 len;
+ unsigned long long len;
char *uribuf;
root_fd = GNUNET_disk_file_open(ectx, argv[i], O_RDWR | O_SYNC);
diff --git a/read.c b/read.c
@@ -101,7 +101,7 @@ int gn_read(const char *path, char *buf, size_t size, off_t offset,
GNUNET_free(special);
return 0;
}
- if(offset + size > slen)
+ if( ((ssize_t) (offset + size)) > slen)
{
size = slen - offset;
}