With the distribution tarballs, "make" after "make clean" regenerates *.info files
** Summary:
On Mac OSX, at least, a null-length arg. is to be given to sed's "-i" option if one does not require that sed creates a backup file whilst in-place editing.
** Steps to reproduce:
From the directory where GnuTLS 3.6.15 is extracted:
- issue the command: make -C doc install-info
- the processing stumble on:
pkcs11-api.texi abstract-api.texi compat-api.texi dtls-api.texi crypto-api.texi ocsp-api.texi dane-api.texi pkcs7-api.texi; do
./scripts/split-texi.pl functions < $i;
done /usr/bin/sed -i 's/@anchor{.//g' functions/ sed: 1: "functions/dane_cert_typ ...": invalid command code f
** Reason of failure:
The reason is that, at least on Max OSX Yosemite, the "-i" option of sed is meant to call for an in-place editing and to define the extension to use for the backup file.
If no backup file is desired, the parameter to the "-i" option is to be of length 0. The current Makefile specifies extension at all which, on OSX (at least), does not equate to an 0-length extension.
** Possible solution:
This diff output shows a possible solution:
$ diff -c Makefile.in Makefile.in.orig *** Makefile.in 2020-09-10 11:53:09.000000000 +0100 --- Makefile.in.orig 2020-09-10 11:51:27.000000000 +0100
*** 5095,5102 ****
for i in $^; do
$(srcdir)/scripts/split-texi.pl functions < $$i;
done
! $(SED) -i "" 's/@anchor{.//g' functions/
! $(SED) -i "" 's/@subheading.//g' functions/
cd functions && for i in *;do grep ^"@deftypefun" $$i | $(SED) 's/@deftypefun/@item/g;s/ {/ @var{/;s/ {/ @ref{/' > ../functions/$$i.short;done
echo $@ > $@
--- 5095,5102 ----
for i in $^; do
$(srcdir)/scripts/split-texi.pl functions < $$i;
done
! $(SED) -i 's/@anchor{.//g' functions/
! $(SED) -i 's/@subheading.//g' functions/
cd functions && for i in *;do grep ^"@deftypefun" $$i | $(SED) 's/@deftypefun/@item/g;s/ {/ @var{/;s/ {/ @ref{/' > ../functions/$$i.short;done
echo $@ > $@
** Platform:
Macboook running Yosemite (10.10.5)
$ uname -a Darwin ... 14.5.0 Darwin Kernel Version 14.5.0: Sun Jun 4 21:40:08 PDT 2017; root:xnu-2782.70.3~1/RELEASE_X86_64 x86_64