summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjbj <devnull@localhost>2000-02-27 20:50:52 +0000
committerjbj <devnull@localhost>2000-02-27 20:50:52 +0000
commit795a3ac5948f4942e40d9311777ccd679825413e (patch)
treed8ce601d90fac75685102830e8e941c5d412bbe0
parent945d2cd8af0d5057c0a26d31c196e36a685e0572 (diff)
downloadlibrpm-tizen-795a3ac5948f4942e40d9311777ccd679825413e.tar.gz
librpm-tizen-795a3ac5948f4942e40d9311777ccd679825413e.tar.bz2
librpm-tizen-795a3ac5948f4942e40d9311777ccd679825413e.zip
Diminish solaris2.6 gcc noise.
CVS patchset: 3593 CVS date: 2000/02/27 20:50:52
-rw-r--r--build/parsePrep.c5
-rw-r--r--lib/fs.c4
-rw-r--r--misc/setenv.c4
-rw-r--r--system.h9
4 files changed, 15 insertions, 7 deletions
diff --git a/build/parsePrep.c b/build/parsePrep.c
index bd2fbd6ca..ce1d52953 100644
--- a/build/parsePrep.c
+++ b/build/parsePrep.c
@@ -106,14 +106,15 @@ static int checkOwners(const char *urlfn)
"if [ $STATUS -ne 0 ]; then\n"
" exit $STATUS\n"
"fi",
- c, basename(fn),
+ c, (const char *) basename(fn),
zipper,
fn, strip, args);
xfree(zipper);
} else {
sprintf(buf,
"echo \"Patch #%d (%s):\"\n"
- "patch -p%d %s -s < %s", c, basename(fn), strip, args, fn);
+ "patch -p%d %s -s < %s", c, (const char *) basename(fn),
+ strip, args, fn);
}
xfree(urlfn);
diff --git a/lib/fs.c b/lib/fs.c
index 02e60120e..d92531b8a 100644
--- a/lib/fs.c
+++ b/lib/fs.c
@@ -116,7 +116,7 @@ static int getFilesystemList(void)
int i;
char * mntdir;
# if GETMNTENT_ONE || GETMNTENT_TWO
- our_mntent item, * itemptr;
+ our_mntent item;
FILE * mtab;
# elif HAVE_GETMNTINFO_R
struct statfs * mounts = NULL;
@@ -143,7 +143,7 @@ static int getFilesystemList(void)
while (1) {
# if GETMNTENT_ONE
/* this is Linux */
- itemptr = getmntent(mtab);
+ our_mntent * itemptr = getmntent(mtab);
if (!itemptr) break;
item = *itemptr;
mntdir = item.our_mntdir;
diff --git a/misc/setenv.c b/misc/setenv.c
index ae19721ef..12d984afe 100644
--- a/misc/setenv.c
+++ b/misc/setenv.c
@@ -16,9 +16,7 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-#if HAVE_CONFIG_H
-# include <config.h>
-#endif
+# include "system.h"
#include <errno.h>
#if !_LIBC
diff --git a/system.h b/system.h
index 55af53a46..ee891c4f0 100644
--- a/system.h
+++ b/system.h
@@ -93,6 +93,10 @@ char *memchr ();
char * stpcpy(char * dest, const char * src);
#endif
+#if !defined(HAVE_STPNCPY) || defined(__LCLINT__)
+char * stpncpy(char * dest, const char * src, size_t n);
+#endif
+
#include <errno.h>
#ifndef errno
extern int errno;
@@ -300,6 +304,11 @@ char *realpath(const char *path, char resolved_path []);
extern void *myrealloc(void *, size_t);
#endif
+#if ! HAVE_SETENV
+extern int setenv(const char *name, const char *value, int replace);
+extern void unsetenv(const char *name);
+#endif
+
#if HAVE_SYS_SOCKET_H
#include <sys/types.h>
#ifndef __LCLINT__