building vim-7.0.152 on freebsd-4.10 results in warnings about O_NOFOLLOW being redefined by vim.h. the attached patch fixes it. i've also compiled with this patch on linux (glibc-2.4), but nowhere else.
diff -r 8fa2beaad0d3 src/os_unix.h --- a/src/os_unix.h Fri Nov 03 08:31:12 2006 +0000 +++ b/src/os_unix.h Fri Nov 03 15:48:29 2006 -0800 @@ -27,6 +27,10 @@ #else # include <sys/types.h> # include <sys/stat.h> +#endif + +#ifdef HAVE_FCNTL_H +# include <fcntl.h> #endif #ifdef HAVE_STDLIB_H