[BusyBox] [PATCH] PATH_MAX undefined in [u]mount.c
Magnus Damm
damm at opensource.se
Fri Jan 25 05:19:05 UTC 2002
See this thread for more info.
http://www.busybox.net/lists/busybox/2001-November/010498.html
I think it's cross-compiler + libc related.
Cheers /
Magnus
Dan Kegel wrote:
>
> In some odd environments, <limits.h> doesn't define PATH_MAX
> as it should. The workaround noted in ChangeLog is to include
> <sys/param.h>, but that workaround doesn't appear to be in
> [u]mount.c, which causes compilation to fail.
>
> Here's a patch to add <sys/param.h>:
> http://www.kegel.com/path_max.patch
> Does it hurt anyone? Or is there a better fix?
>
> Thanks,
> Dan
> [who is happily using busybox on ppc405, ppc750, and sh4
> with Montavista's tools and homebuilt gcc3]
>
> diff -aur busybox-0.60.2.orig/mount.c busybox-0.60.2/mount.c
> --- busybox-0.60.2.orig/mount.c Thu Jan 24 14:53:53 2002
> +++ busybox-0.60.2/mount.c Thu Jan 24 14:54:36 2002
> @@ -44,6 +44,7 @@
> */
>
> #include <limits.h>
> +#include <sys/param.h> /* for PATH_MAX on systems that don't have it in limits.h */
> #include <stdlib.h>
> #include <unistd.h>
> #include <errno.h>
> diff -aur busybox-0.60.2.orig/umount.c busybox-0.60.2/umount.c
> --- busybox-0.60.2.orig/umount.c Thu Jan 24 14:53:53 2002
> +++ busybox-0.60.2/umount.c Thu Jan 24 15:59:54 2002
> @@ -23,6 +23,7 @@
> */
>
> #include <limits.h>
> +#include <sys/param.h> /* for PATH_MAX on systems that don't have it in limits.h */
> #include <stdio.h>
> #include <mntent.h>
> #include <errno.h>
> _______________________________________________
> busybox mailing list
> busybox at busybox.net
> http://busybox.net/mailman/listinfo/busybox
More information about the busybox
mailing list