<div dir="auto">Thanks Greg,<div dir="auto"><br></div><div dir="auto"> Regarding `\s` - good catch, as I read your post, I was sure it is used all over the place... but in fact only in perl code (also Java/groovy in CI libs), so not quite a GNU-only extension. Native Sun and BSD sed's were okay with that too. Most shell code went with "[ ${TABCHAR}]" where TABCHAR="`printf '\t'`" because indeed many sed's or especially grep's treat direct `\t` as escaped character "t". Missed doing that here. Once! And you got me on that! :D</div><div dir="auto"><br></div><div dir="auto"> Truth be told, one script does mention `[[:blank:]]`.</div><div dir="auto"><br></div><div dir="auto"> Regarding commentary on docs, fair enough about the <a href="http://configure.ac">configure.ac</a> script, but does at least `docs/configure.txt` explain it satisfactorily?</div><div dir="auto"><br></div><div dir="auto">Jim</div></div><br><div class="gmail_quote gmail_quote_container"><div dir="ltr" class="gmail_attr">On Sat, Aug 2, 2025, 18:43 Greg Troxel via Nut-upsuser <<a href="mailto:nut-upsuser@alioth-lists.debian.net">nut-upsuser@alioth-lists.debian.net</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Jim Klimov via Nut-upsdev <<a href="mailto:nut-upsdev@alioth-lists.debian.net" target="_blank" rel="noreferrer">nut-upsdev@alioth-lists.debian.net</a>> writes:<br>
<br>
> FWIW, I did merge the previously queued "small PRs",<br>
<br>
Great, thanks.<br>
<br>
> now probably gotta<br>
> figure out what Greg found with pkgsrc's `sed` (or await his PR with a fix<br>
> that would work everywhere - can't reproduce the problem so far), and<br>
> planned changes will be done.<br>
<br>
This is not about pkgsrc's sed; it's about the sed that is part of the<br>
NetBSD base system, which is believed to conform to POSIX. (When<br>
building under pkgsrc, the base sed is used even if gsed is installed,<br>
as part of repeatable build hygiene.)<br>
<br>
I am 99% sure that the problem is this, from doc/Makefile.am, building<br>
ChangeLog.adoc from ChangeLog:<br>
<br>
-e 's,^\(\s\s*\)\([0-9]\),\1{empty}\2,g'<br>
<br>
resulting in<br>
<br>
"s,^\(\s\s*\)\([0-9]\),\ ..."<br>
<br>
<br>
I think the problem is that \s is a GNU beyond-POSIX extension and the<br>
standards-compliant way to write this is<br>
<br>
-e 's,^\([:blank:][:blank:]*\)\([0-9]\),\1{empty}2\,g' \<br>
<br>
instead.<br>
<br>
<br>
(In general, I find the sed magic surrounding docs builds too hard to<br>
understand, even for someone who has used sed, probably starting with<br>
Seventh Edition.)<br>
<br>
> On one hand, a build is expected to deliver man pages. Historically *roff<br>
> files were directly edited and served by projects; nowadays it is asciidoc<br>
> or similar, rendered into man pages as one of many output formats. Dist<br>
> tarballs include those page files so they can be installed even where<br>
> asciidoc renderer is not available. So some options manage this part.<br>
<br>
ok, but which options actually do what precisely? Does --without-doc<br>
say "don't build them" or "don't install them"? What happens if you<br>
give --without-doc, and you don't, or do, have them built? One could<br>
make an argument that "don't build them, and install what should have<br>
been built into distfile, erroring out if not there" is mild/acceptable,<br>
resulting in a correct package. And that "don't build and don't<br>
install" is, while useful to some, an instruction that results in a<br>
defective install.<br>
<br>
This is not understandable from reading <a href="http://configure.ac" rel="noreferrer noreferrer" target="_blank">configure.ac</a>.<br>
<br>
> Another issue is the codes assigned to man page sections in different OSes<br>
> - this was previously bolted to what is seen in Linux and FreeBSD; now can<br>
> be amended for package builds (especially on other platforms), to avoid<br>
> clumsy distro-specific patch files or scripts in their recipes.<br>
<br>
sure, good to have --do-foo to accomodate. So far that's not my issue!<br>
<br>
_______________________________________________<br>
Nut-upsuser mailing list<br>
<a href="mailto:Nut-upsuser@alioth-lists.debian.net" target="_blank" rel="noreferrer">Nut-upsuser@alioth-lists.debian.net</a><br>
<a href="https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/nut-upsuser" rel="noreferrer noreferrer" target="_blank">https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/nut-upsuser</a><br>
</blockquote></div>