Discussion:
[9fans] APE inconsistencies
(too old to reply)
Jeff Sickel
2013-03-29 17:13:23 UTC
Permalink
Does anyone know if the netdb.h inclusion of hstrerror(int) was
just a copy/paste error? Of if hstrerror() was intended to be
in the ape/lib/bsd source but got dropped somehow?

-jas
Charles Forsyth
2013-03-29 17:20:05 UTC
Permalink
Post by Jeff Sickel
Does anyone know if the netdb.h inclusion of hstrerror(int) was
just a copy/paste error? Of if hstrerror() was intended to be
in the ape/lib/bsd source but got dropped somehow?
the linux manual page describes hstrerror as obsolete
Jeff Sickel
2013-03-29 17:25:04 UTC
Permalink
Post by Charles Forsyth
the linux manual page describes hstrerror as obsolete
Which distro? So many to choose from…
Kurt H Maier
2013-03-29 17:41:48 UTC
Permalink
Post by Jeff Sickel
Post by Charles Forsyth
the linux manual page describes hstrerror as obsolete
Which distro? So many to choose from…
It's sort of moot, since The Man wants you to stop using gethostbyname
and friends anyway. They're marked as 'obsolete' because POSIX.1-2001
wants you to use getnameinfo et al. instead.

Anything using gethostbyname is probably going to want herror (and thus
hstrerror) to be there.

khm
Charles Forsyth
2013-03-29 18:00:45 UTC
Permalink
Post by Kurt H Maier
Anything using gethostbyname is probably going to want herror (and thus
hstrerror) to be there.
I see, although it seems herror/hstrerror is usually ifdef'd out, even when
gethostbyname remains!
Jeff Sickel
2013-03-29 18:26:53 UTC
Permalink
Post by Kurt H Maier
Anything using gethostbyname is probably going to want herror (and thus
hstrerror) to be there.
I see, although it seems herror/hstrerror is usually ifdef'd out, even when gethostbyname remains!
Though if I check recent FreeBSD manuals, it's all there. And given that
this is part of the BSD extensions to APE, those might be more relevant
than the Linux man pages. Not that BSD tries to be POSIX compliant
any more or less than GNU/Linux.

There are definitely some issues in gethostbyaddr() that are being
looked into at this time. But while the review is taking place, it doesn't
hurt to look at other potential areas of a mismatch.
Kurt H Maier
2013-03-29 19:12:20 UTC
Permalink
Post by Jeff Sickel
Though if I check recent FreeBSD manuals, it's all there. And given that
this is part of the BSD extensions to APE, those might be more relevant
than the Linux man pages. Not that BSD tries to be POSIX compliant
any more or less than GNU/Linux.
It should be indeed underlined that this is a compatibility feature, and
not a POSIX feature. It seems that it is still here for legacy
compatibility on BSD (it is still here in NetBSD for example) but the
question arises whether it is worth supporting (because starting to
support all not POSIX is a daunting task).
This is what is said in the APE paper. The problem is not with Plan9
APE, it is that there are not a lot of programs that are written in a
POSIX compliant way...
It is a POSIX feature, I think. It's just an outmoded one. Supporting
all revisions of POSIX is damn near impossible. Does APE have an
explicit target?

khm
t***@polynum.com
2013-03-29 20:10:35 UTC
Permalink
Post by Kurt H Maier
It is a POSIX feature, I think. It's just an outmoded one. Supporting
all revisions of POSIX is damn near impossible. Does APE have an
explicit target?
Well, it is not in SuSv3. And this is not already the latest...
--
Thierry Laronde <tlaronde +AT+ polynum +dot+ com>
http://www.kergis.com/
Key fingerprint = 0FF7 E906 FBAF FE95 FD89 250D 52B1 AE95 6006 F40C
Charles Forsyth
2013-03-29 20:32:45 UTC
Permalink
Post by Kurt H Maier
It is a POSIX feature, I think. It's just an outmoded one. Supporting
all revisions of POSIX is damn near impossible. Does APE have an
explicit target?
I think it's really a pragmatic matter of which interfaces are in some
standard that can be named,
that are also needed by most software that's being imported (eg, newer
versions of Python).
t***@polynum.com
2013-03-29 19:03:45 UTC
Permalink
Post by Jeff Sickel
Though if I check recent FreeBSD manuals, it's all there. And given that
this is part of the BSD extensions to APE, those might be more relevant
than the Linux man pages. Not that BSD tries to be POSIX compliant
any more or less than GNU/Linux.
It should be indeed underlined that this is a compatibility feature, and
not a POSIX feature. It seems that it is still here for legacy
compatibility on BSD (it is still here in NetBSD for example) but the
question arises whether it is worth supporting (because starting to
support all not POSIX is a daunting task).

This is what is said in the APE paper. The problem is not with Plan9
APE, it is that there are not a lot of programs that are written in a
POSIX compliant way...
--
Thierry Laronde <tlaronde +AT+ polynum +dot+ com>
http://www.kergis.com/
Key fingerprint = 0FF7 E906 FBAF FE95 FD89 250D 52B1 AE95 6006 F40C
a***@9srv.net
2013-03-30 02:37:59 UTC
Permalink
It should be indeed underlined that this is a compatibility
feature, and not a POSIX feature.
APE does an excellent job of making that distinction clear.
Its use of defines to forcibly break syntax was quite
educational as a young programmer.

Anthony

Lyndon Nerenberg
2013-03-29 22:20:01 UTC
Permalink
Post by Jeff Sickel
Not that BSD tries to be POSIX compliant
any more or less than GNU/Linux.
FreeBSD is actually pretty good about adhering to POSIX/SUS/Xopen when you set the appropriate defines.
Continue reading on narkive:
Loading...