"James K. Lowden" <jklow...@schemamania.org> writes: > On Sat, 15 Feb 2025 21:24:52 +0000 > Sam James <s...@gentoo.org> wrote: > >> > +prototypes.cpp: posix.txt >> > + awk -F'[/.]' '{ print $$6 }' $^ | \ >> > + while read F; do echo "/* $$F */" && man 2 $$F | \ >> > + ./scrape.awk -v funcname=$$6; done > $@~ >> > + @mv $@~ $@ >> > + >> > +posix.txt: >> > + zgrep -l 'POSIX[.]' /usr/share/man/man2/*z > $@~ >> >> This will need reworking. It assumes the location of the man pages on >> the system, assumes 'zgrep' exists, and assumes 'zgrep' can read the >> man pages (the man pages may be compressed with something else; I know >> such systems exist). >> >> I'm not sure this is really any less brittle or more robust than just >> listing the actual functions you scraped out from your system. > > You might be reading more into this than you want to.
Ah, that's a fair point. > I'm sure you agree we don't want to let this tail wag the dog. With my > exegesis in mind, what would you recommend? If it's limited to more > judicious use of makefile variables, I could surely implement those > suggestions. I think it's fine as-is, but I'd ask that you keep in mind that it's very possible there's entries missing from it even *with* this, and that having a script like this at all may give a false sense of completeness or correctness. (Not all of the functions have a distinct page, for example, and not everything is documented. There's also a distinct man-pages-posix collection which you may or may not have installed.) But fair enough. thanks, sam