1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60
|
---
src/usr.bin/make/arch.c | 4 ++++
src/usr.bin/make/main.c | 3 +++
src/usr.sbin/config/main.c | 4 ++++
src/usr.sbin/config/mkmakefile.c | 4 ++++
src/usr.sbin/config/mkoptions.c | 4 ++++
src/usr.sbin/mtree/create.c | 4 ++++
src/usr.sbin/mtree/extern.h | 5 +++--
7 files changed, 26 insertions(+), 2 deletions(-)
--- a/src/usr.bin/make/arch.c
+++ b/src/usr.bin/make/arch.c
@@ -191,6 +191,10 @@
Error ARGS; \
} while (0)
+#ifndef MAXPATHLEN
+# define MAXPATHLEN 4096
+#endif
+
/*-
*-----------------------------------------------------------------------
* Arch_ParseArchive --
--- a/src/usr.bin/make/main.c
+++ b/src/usr.bin/make/main.c
@@ -255,6 +255,9 @@
{
char *fname, *fnamesave; /* makefile to read */
FILE *stream;
+#ifndef MAXPATHLEN
+# define MAXPATHLEN 4096
+#endif
char *name, path[MAXPATHLEN];
char *MAKEFILE;
int setMAKEFILE;
--- a/src/usr.sbin/mtree/create.c
+++ b/src/usr.sbin/mtree/create.c
@@ -67,6 +67,10 @@
#define INDENTNAMELEN 15
#define MAXLINELEN 80
+#ifndef MAXHOSTNAMELEN
+# define MAXHOSTNAMELEN 255
+#endif
+
static gid_t gid;
static uid_t uid;
static mode_t mode;
--- a/src/usr.sbin/mtree/extern.h
+++ b/src/usr.sbin/mtree/extern.h
@@ -54,6 +54,7 @@
extern u_int keys;
extern int lineno;
extern int dflag, eflag, iflag, nflag, qflag, rflag, sflag, uflag, wflag;
-#ifdef MAXPATHLEN
-extern char fullpath[MAXPATHLEN];
+#ifndef MAXPATHLEN
+# define MAXPATHLEN 4096
#endif
+extern char fullpath[MAXPATHLEN];
|