Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 8 Dec 2002 16:16:45 -0800
From:      David Schultz <dschultz@uclink.Berkeley.EDU>
To:        Marc Recht <marc@informatik.uni-bremen.de>
Cc:        freebsd-standards@FreeBSD.ORG
Subject:   Re: POSIX and the real life or FreeBSD too strict ?
Message-ID:  <20021209001645.GA1618@HAL9000.homeunix.com>
In-Reply-To: <794560000.1039386792@leeloo.intern.geht.de>
References:  <584000000.1039360297@leeloo.intern.geht.de> <20021208203949.GA535@HAL9000.homeunix.com> <758430000.1039382013@leeloo.intern.geht.de> <20021208214357.GA945@HAL9000.homeunix.com> <794560000.1039386792@leeloo.intern.geht.de>

next in thread | previous in thread | raw e-mail | index | archive | help

Thus spake Marc Recht <marc@informatik.uni-bremen.de>:
> >If you say -D_XOPEN_SOURCE=600 instead of -D_XOPEN_SOURCE_=600,
> >the first test works fine.  ;-)
> Argh, too much copying between the systems. That was the rewritten one.. l 
> = sysconf has been
> l = getpagesize();
> before. Which gives you (Wall): implicit declaration of function 
> `getpagesize'. But, _only_ on FreeBSD 5-current.

Yes, but Solaris 8 and glibc disagree about whether
_XOPEN_SOURCE_EXTENDED is required.  As for FreeBSD, I think your
general complaint about it being too picky is invalid; everyone
else does things the same way, and standards even require that no
extra symbols are defined by standard headers unless otherwise
requested.  But you seem to have discovered that not all of the
appropriate functions are declared when _XOPEN_SOURCE is defined.
In addition to getpagesize(), brk() and chroot() should be
declared when _XOPEN_SOURCE is defined, for example.  For the most
part, these are interfaces that originally appeared in BSD and
later made it into SUS, and the FreeBSD headers were never updated
properly.

If you have the time, you could come up with a patch to move the
appropriate functions from an '#if __BSD_VISIBLE' to an
'#if __BSD_VISIBLE || __XSI_VISIBLE'.

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-standards" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20021209001645.GA1618>