shlomif / perl-XML-LibXML

The XML-LibXML CPAN Distribution for Processing XML using the libxml2 library
https://metacpan.org/release/XML-LibXML
Other
17 stars 35 forks source link

2.0132 does not build with Visual Studio 2010, 2.0123 does #15

Closed mpw96 closed 6 years ago

mpw96 commented 6 years ago

Hi, the problem is that perl-libxml-sax.c cannot be compiled. It seems that the very basic perl things are unknown in this file. E.g. in line 854 there's the dTHX macro. 2.0123 builds okay in the very same context. Also 2.0132 builds on Unixes and Linux. Only Windows and 2.0132 is a problem. Here's the beginning of the error:

cl -c -IC:\SAPDevelop\hmexternals\perl\gen\out\build-64de87d5\libxml_helpdir\include -nologo -GF -W3 -O1 -MD -Zi -DNDEBUG -GL -fp:precise -DWIN32 -D_CONSOLE -DNO_STRICT -DWIN64 -DCONSERVATIV E -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE -DPERL_TEXTMODE_SCRIPTS -DPERL_IMPLICIT_CONTEXT -DPERL_IMPLICIT_SYS -O1 -MD -Zi -DNDEBUG -GL -fp:precise -DVERSION=\"2.0132\" -DXS_VERSION= \"2.0132\" "-IC:\SAPDevelop\hmexternals\perl\gen\out\perl-5.24.1-sap16-SNAPSHOT-ntamd64-release-c\lib\CORE" -DHAVE_UTF8 perl-libxml-sax.c perl-libxml-sax.c perl-libxml-sax.c(326) : warning C4244: '=' : conversion from 'IV' to 'int', possible loss of data perl-libxml-sax.c(854) : error C2275: 'PerlInterpreter' : illegal use of this type as an expression C:\SAPDevelop\hmexternals\perl\gen\out\perl-5.24.1-sap16-SNAPSHOT-ntamd64-release-c\lib\CORE\perl.h(2631) : see declaration of 'PerlInterpreter' perl-libxml-sax.c(854) : error C2065: 'my_perl' : undeclared identifier perl-libxml-sax.c(857) : error C2065: 'my_perl' : undeclared identifier ... Stop.

Do you have an idea, what's wrong here?

T&R Marc-Philip

mpw96 commented 6 years ago

I did some bisecting. 2.0128 is good, 2.0129 is the first bad version. I suspect this change to be causing the problem: 7a0a5eabb8dd91acabe96a61dc84b7b2d092580e.

shlomif commented 6 years ago

Hi Marc,

On Wed, 22 Nov 2017 14:29:55 +0000 (UTC) Marc-Philip notifications@github.com wrote:

Hi, the problem is that perl-libxml-sax.c cannot be compiled. It seems that the very basic perl things are unknown in this file. E.g. in line 854 there's the dTHX macro. 2.023 builds okay in the very same context. Also 2.032 builds on Unixes and Linux. Only Windows and 2.032 is a problem. Here's the beginning of the error:

    cl -c

-IC:\SAPDevelop\hmexternals\perl\gen\out\build-64de87d5\libxml_helpdir\include -nologo -GF -W3 -O1 -MD -Zi -DNDEBUG -GL -fp:precise -DWIN32 -D_CONSOLE -DNO_STRICT -DWIN64 -DCONSERVATIV E -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE -DPERL_TEXTMODE_SCRIPTS -DPERL_IMPLICIT_CONTEXT -DPERL_IMPLICIT_SYS -O1 -MD -Zi -DNDEBUG -GL -fp:precise -DVERSION=\"2.0132\" -DXS_VERSION= \"2.0132\" "-IC:\SAPDevelop\hmexternals\perl\gen\out\perl-5.24.1-sap16-SNAPSHOT-ntamd64-release-c\lib\CORE" -DHAVE_UTF8 perl-libxml-sax.c perl-libxml-sax.c perl-libxml-sax.c(326) : warning C4244: '=' : conversion from 'IV' to 'int', possible loss of data perl-libxml-sax.c(854) : error C2275: 'PerlInterpreter' : illegal use of this type as an expression C:\SAPDevelop\hmexternals\perl\gen\out\perl-5.24.1-sap16-SNAPSHOT-ntamd64-release-c\lib\CORE\perl.h(2631) : see declaration of 'PerlInterpreter' perl-libxml-sax.c(854) : error C2065: 'my_perl' : undeclared identifier perl-libxml-sax.c(857) : error C2065: 'my_perl' : undeclared identifier ... Stop.

Do you have an idea, what's wrong here?

my best suggestion is to try a git https://en.wikipedia.org/wiki/Bisection_(software_engineering) . otherwise note that I hate MSVC with a passion.

T&R Marc-Philip

--

Shlomi Fish http://www.shlomifish.org/ Funny Anti-Terrorism Story - http://shlom.in/enemy

Faith: Becky… you have a lot of potential. You’re more than a pretty face. Becky: Heh, I knew that I have potential, but do you really think I have a pretty face? — http://www.shlomifish.org/humour/Buffy/A-Few-Good-Slayers/

Please reply to list if it's a mailing list post - http://shlom.in/reply .

shlomif commented 6 years ago

I am getting test+build successes on windows here - http://matrix.cpantesters.org/?dist=XML-LibXML+2.0132 - can gcc build XML-LibXML fine on your system?

mpw96 commented 6 years ago

Do you mean gcc on Windows? 2.032 builds fine with gcc on Linux. On Windows I have only Visuail Studio 2010. I don't like MSVC very much either, however, it would be good if we can sort this out.

cpantesters is unresponsive at the moment. What compiler do they use there for mswin32?

shlomif commented 6 years ago

On Wed, 22 Nov 2017 20:35:26 +0000 (UTC) Marc-Philip notifications@github.com wrote:

Do you mean gcc on Windows?

Yes, I mean build w gcc on windows.

2.032 builds fine with gcc on Linux. On Windows I have only Visuail Studio 2010. I don't like MSVC very much either, however, it would be good if we can sort this out.

cpantesters is unresponsive at the moment. What compiler do they use there for mswin32?

These are tested by volunteers, so it may vary.

--

Shlomi Fish http://www.shlomifish.org/ “So, who the hell is Qoheleth?” - http://shlom.in/qoheleth

Do not meddle in the affairs of Dragons, for you are crunchy and taste good with ketchup. — Unknown source.

Please reply to list if it's a mailing list post - http://shlom.in/reply .

mpw96 commented 6 years ago

Hi Shlomi, I've indeed done the bisecting and the result is this:

Too bad I don't have a fix yet. Regards Marc-Philip

mpw96 commented 6 years ago

Hi @0x62ash, as 7a0a5ea is your commit, do you happen to have an idea how to fix this?

Regards Marc-Philip

0x62ash commented 6 years ago

Sorry, i don't have any idea and even can't reproduce (have no win/MSVC)