Hi all:

I think I'll test the waters around here with a small patch to fix some 
compilation warnings, please see the attached patch file. I does not need to be 
applied exactly as suggested, anything to make those warnings go away will do!


Thanks,
  rdiez
diff --git a/cpukit/libfs/src/nfsclient/src/dirutils.c b/cpukit/libfs/src/nfsclient/src/dirutils.c
index 65e2053..bc72bb8 100644
--- a/cpukit/libfs/src/nfsclient/src/dirutils.c
+++ b/cpukit/libfs/src/nfsclient/src/dirutils.c
@@ -91,7 +91,11 @@
 #include <cexpHelp.h>
 #endif
 
+#ifdef HAVE_CEXP
+
 #ifndef __vxworks
+
+/* This routine does not seem to be used anywhere:
 int
 pwd(void)
 {
@@ -105,6 +109,7 @@ char buf[PATH_MAX];
 	}
 	return 0;
 }
+*/
 
 static int
 ls_r(char *path, char *chpt, char *name, struct stat *buf)
@@ -142,7 +147,7 @@ char *t;
 	return 0;
 }
 
-int
+static int
 ls(char *dir, char *opts)
 {
 struct dirent	*de;
@@ -183,7 +188,7 @@ cleanup:
 		fprintf(stderr, "          ""-f""       -> overwrite existing file\n");
 #endif
 
-int
+static int
 cp(char *from, char *to, char *opts)
 {
 struct stat	st;
@@ -310,7 +315,7 @@ cleanup:
 	return rval;
 }
 
-int
+static int
 ln(char *to, char *name, char *opts)
 {
 	if (!to) {
@@ -340,19 +345,18 @@ ln(char *to, char *name, char *opts)
 	return 0;
 }
 
-int
+static int
 rm(char *path)
 {
 	return unlink(path);
 }
 
-int
+static int
 cd(char *path)
 {
 	return chdir(path);
 }
 
-#ifdef HAVE_CEXP
 static CexpHelpTabRec _cexpHelpTabDirutils[] __attribute__((unused)) = {
 	HELP(
 "copy a file: cp(""from"",[""to""[,""-f""]])\n\
@@ -385,4 +389,4 @@ static CexpHelpTabRec _cexpHelpTabDirutils[] __attribute__((unused)) = {
 		),
 	HELP("",,0,)
 };
-#endif
+#endif  /* #ifdef HAVE_CEXP */
diff --git a/cpukit/libfs/src/rfs/rtems-rfs-format.c b/cpukit/libfs/src/rfs/rtems-rfs-format.c
index 096db83..47da939 100644
--- a/cpukit/libfs/src/rfs/rtems-rfs-format.c
+++ b/cpukit/libfs/src/rfs/rtems-rfs-format.c
@@ -48,7 +48,7 @@ rtems_rfs_bits_per_block (rtems_rfs_file_system* fs)
  * Return a rounded up integer quotient given a dividend and divisor. That is:
  * "quotient = dividend / divisor"
  */
-int
+static int
 rtems_rfs_rup_quotient (uint32_t dividend, uint32_t divisor)
 {
   if (dividend == 0)
diff --git a/cpukit/libmisc/shell/main_lsof.c b/cpukit/libmisc/shell/main_lsof.c
index 2c6ece1..73c1731 100644
--- a/cpukit/libmisc/shell/main_lsof.c
+++ b/cpukit/libmisc/shell/main_lsof.c
@@ -45,8 +45,8 @@ static void lsof(void)
       mt_entry->type,
       mt_entry->target,
       mt_entry->dev == NULL ? "none" : mt_entry->dev,
-      mt_entry->mt_fs_root,
-      mt_entry->mt_fs_root->location.node_access
+      (unsigned)mt_entry->mt_fs_root,
+      (unsigned)mt_entry->mt_fs_root->location.node_access
     );
 
     for (
@@ -55,13 +55,13 @@ static void lsof(void)
       mt_entry_node = rtems_chain_next( mt_entry_node )
     ) {
       const rtems_filesystem_location_info_t *loc =
-        (rtems_filesystem_location_info_t *) mt_entry_node;
+        (const rtems_filesystem_location_info_t *) mt_entry_node;
 
       fprintf(
         stdout,
         "\t0x%08x -> 0x%08x\n",
-        loc,
-        loc->node_access
+        (unsigned)loc,
+        (unsigned)loc->node_access
       );
     }
   }
diff --git a/cpukit/posix/src/cleanuppush.c b/cpukit/posix/src/cleanuppush.c
index f27ab79..84dbc00 100644
--- a/cpukit/posix/src/cleanuppush.c
+++ b/cpukit/posix/src/cleanuppush.c
@@ -22,7 +22,7 @@
 #include <errno.h>
 
 #include <rtems/system.h>
-#include <rtems/score/chain.h>
+#include <rtems/score/chainimpl.h>
 #include <rtems/score/isr.h>
 #include <rtems/score/thread.h>
 #include <rtems/score/wkspace.h>
_______________________________________________
rtems-devel mailing list
rtems-devel@rtems.org
http://www.rtems.org/mailman/listinfo/rtems-devel

Reply via email to