samba-2.2.0-alpha2 - still compile problem on ReliantUNIX

Andrej Borsenkow Andrej.Borsenkow at mow.siemens.ru
Wed Jan 31 06:04:46 GMT 2001


>
> Andrej, if you look in nsswitch/winbind_nss_config.h you will see
>
> #ifdef HAVE_UNISTD_H
> #include <unistd.h>
> #endif
>
> Is there any reason why this doesn't solve your problem?  Perhaps
> some of the includes in this file can be re-ordered to solve your
> problem.
>

It comes too late. To get LFS in explicit mode (off64_t & friends) you really
need unistd.h as the very first include. I did it for include/includes.h when
porting samba-2 to 64 bit version of ReliantUNIX:

#ifdef RELIANTUNIX
/*
 * <unistd.h> has to be included before any other to get
 * large file support on Reliant UNIX
 */
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#endif /* RELIANTUNIX */

but nsswitch/wb_common.c does not include "standard" headers. Even if
wb_common.c itself does not use LFS, system headers get confused:

Compiling nsswitch/wb_common.c
/usr/include/unistd.h   288: [error]:   CFE1020 identifier "off64_t" is
undefined
  extern int ftruncate64(int, off64_t);
                              ^

etc

I once was about to change defaults to prefer 64-bit off_t instead of off64_t,
but then I spotted discussion on samba-technical that it was done
intentionally.

-andrej





More information about the samba-technical mailing list