[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: texinfo-6.8.90 pretest
From: |
Eli Zaretskii |
Subject: |
Re: texinfo-6.8.90 pretest |
Date: |
Sat, 22 Oct 2022 11:57:36 +0300 |
I tried to build this with mingw.org's MinGW on native MS-Windows; the
build failed. Details below.
First, I had warnings like this one:
libtool: compile: d:/usr/bin/gcc.exe -DHAVE_CONFIG_H -I. -I.
-I./gnulib/lib -I./gnulib/lib -DDATADIR=\"d:/usr/share\" -s -O2 -DWIN32
-DPERL_TEXTMODE_SCRIPTS -DUSE_SITECUSTOMIZE -DPERL_IMPLICIT_CONTEXT
-DPERL_IMPLICIT_SYS -DUSE_PERLIO -fwrapv -fno-strict-aliasing -mms-bitfields -s
-O2 -DVERSION=\"0\" -DXS_VERSION=\"0\" -ID:/usr/Perl/lib/CORE -MT
XSParagraph.lo -MD -MP -MF .deps/XSParagraph.Tpo -c XSParagraph.c -DDLL_EXPORT
-DPIC -o .libs/XSParagraph.o
In file included from XSParagraph.xs:8:
D:/usr/Perl/lib/CORE/XSUB.h:506: warning: "putenv" redefined
506 | # define putenv PerlEnv_putenv
|
In file included from D:/usr/Perl/lib/CORE/perl.h:766,
from XSParagraph.xs:7:
./gnulib/lib/stdlib.h:1374: note: this is the location of the previous
definition
1374 | # define putenv _putenv
|
In file included from XSParagraph.xs:8:
D:/usr/Perl/lib/CORE/XSUB.h:524: warning: "fdopen" redefined
524 | # define fdopen PerlSIO_fdopen
|
In file included from D:/usr/Perl/lib/CORE/win32.h:160,
from D:/usr/Perl/lib/CORE/win32thread.h:4,
from D:/usr/Perl/lib/CORE/perl.h:2690,
from XSParagraph.xs:7:
./gnulib/lib/stdio.h:820: note: this is the location of the previous
definition
820 | # define fdopen _fdopen
|
In file included from XSParagraph.xs:8:
D:/usr/Perl/lib/CORE/XSUB.h:552: warning: "mktemp" redefined
552 | # define mktemp PerlLIO_mktemp
|
In file included from D:/usr/Perl/lib/CORE/perl.h:766,
from XSParagraph.xs:7:
./gnulib/lib/stdlib.h:1241: note: this is the location of the previous
definition
1241 | # define mktemp _mktemp
|
In file included from XSParagraph.xs:8:
D:/usr/Perl/lib/CORE/XSUB.h:565: warning: "free" redefined
565 | # define free PerlMem_free
|
In file included from D:/usr/Perl/lib/CORE/perl.h:766,
from XSParagraph.xs:7:
./gnulib/lib/stdlib.h:737: note: this is the location of the previous
definition
737 | # define free rpl_free
|
I don't understand why this happens now whereas it didn't happen in
Texinfo-6.8; both XSParagraph.xs and Gnulib's stdlib.h seem to be
identical in both versions of Texinfo. I fixed this temporarily by
adding the following in XSParagraph.c (the actual change should
probably be in XSParagraph.xs instead):
--- ./tp/Texinfo/XS/XSParagraph.c~0 2022-02-12 00:01:48.000000000 +0200
+++ ./tp/Texinfo/XS/XSParagraph.c 2022-10-22 10:52:27.900000000 +0300
@@ -14,6 +14,12 @@
#define PERL_NO_GET_CONTEXT
#include "EXTERN.h"
#include "perl.h"
+#if defined _WIN32 && !defined __CYGWIN__
+ #undef putenv
+ #undef fdopen
+ #undef mktemp
+ #undef free
+#endif
#include "XSUB.h"
#include "ppport.h"
A similar block of #undef's is needed in api.c, for the same reason.
Any ideas why this pops up in this version of Texinfo?
The next problem is in api.c: several functions were missing the dTHX
thingy. Here's the patch:
--- ./tp/Texinfo/XS/parsetexi/api.c~0 2022-09-29 20:57:14.000000000 +0300
+++ ./tp/Texinfo/XS/parsetexi/api.c 2022-10-22 11:11:11.275000000 +0300
@@ -137,6 +143,8 @@ reset_parser_except_conf (void)
void
reset_parser (void)
{
+ dTHX;
+
debug ("!!!!!!!!!!!!!!!! RESETTING THE PARSER !!!!!!!!!!!!!!!!!!!!!");
reset_parser_except_conf ();
@@ -1053,6 +1061,8 @@ set_debug (int value)
void
set_documentlanguage_override (char *value)
{
+ dTHX;
+
free (global_documentlanguage);
global_documentlanguage = strdup (value);
global_documentlanguage_fixed = 1;
@@ -1068,6 +1078,8 @@ set_DOC_ENCODING_FOR_INPUT_FILE_NAME (in
void
set_input_file_name_encoding (char *value)
{
+ dTHX;
+
free (input_file_name_encoding);
input_file_name_encoding = strdup (value);
}
@@ -1075,6 +1087,8 @@ set_input_file_name_encoding (char *valu
void
set_locale_encoding (char *value)
{
+ dTHX;
+
free (locale_encoding);
locale_encoding = strdup (value);
}
And now for the final blow: while building texinfo.info, I get this
error message:
Can't locate I18N/Langinfo.pm in @INC (you may need to install the
I18N::Langinfo module) (@INC contains: d:/usr/Perl/site/lib d:/usr/Perl/lib .)
at ../tp/texi2any line 29.
BEGIN failed--compilation aborted at ../tp/texi2any line 29.
Makefile:1547: recipe for target `texinfo.info' failed
make[3]: *** [texinfo.info] Error 2
My Perl version is 5.20.1, and I cannot install a newer version here.
It sounds like I18N::Langinfo is a core module in later versions of
Perl. I very much hope that a solution can be found for my version,
either if you tell me where to find this module that I can install
locally (and then please help me with detailed installation
instructions, as I'm basically Perl-illiterate), or by providing
fallback code in texi2any for when this module is not available.
(What is Langinfo used for in texi2any?)
Thanks.
- Re: texinfo-6.8.90 pretest, (continued)
- Re: texinfo-6.8.90 pretest, Robert Pluim, 2022/10/21
- Re: texinfo-6.8.90 pretest, Gavin Smith, 2022/10/20
- Re: texinfo-6.8.90 pretest, Gavin Smith, 2022/10/20
- Re: texinfo-6.8.90 pretest, Patrice Dumas, 2022/10/20
- Re: texinfo-6.8.90 pretest, Gavin Smith, 2022/10/20
- Re: texinfo-6.8.90 pretest, Gavin Smith, 2022/10/21
- Re: texinfo-6.8.90 pretest, Patrice Dumas, 2022/10/21
- Re: texinfo-6.8.90 pretest, Gavin Smith, 2022/10/21
- Re: texinfo-6.8.90 pretest, Patrice Dumas, 2022/10/22
- Re: texinfo-6.8.90 pretest, Gavin Smith, 2022/10/22
Re: texinfo-6.8.90 pretest,
Eli Zaretskii <=
- Re: texinfo-6.8.90 pretest, Patrice Dumas, 2022/10/22
- Re: texinfo-6.8.90 pretest, Eli Zaretskii, 2022/10/22
- Re: texinfo-6.8.90 pretest, Gavin Smith, 2022/10/22
- Re: texinfo-6.8.90 pretest, Eli Zaretskii, 2022/10/22
- Re: texinfo-6.8.90 pretest, Gavin Smith, 2022/10/22
- Re: texinfo-6.8.90 pretest, pertusus, 2022/10/22
- Re: texinfo-6.8.90 pretest, Eli Zaretskii, 2022/10/23
- I18N::Langinfo on MS-Windows, Gavin Smith, 2022/10/23
- Re: texinfo-6.8.90 pretest, pertusus, 2022/10/23
Re: texinfo-6.8.90 pretest, Eli Zaretskii, 2022/10/23