Hi,

not a libxml guru at all, but looking at /usr/local/include/libxml2/libxml/encoding.h:31 (taken from your compilation warnings)

    #ifdef LIBXML_ICONV_ENABLED
    #include <iconv.h>
    #endif
    #ifdef LIBXML_ICU_ENABLED
    #include <unicode/ucnv.h>
    #endif

and on my system:

    cd usr/include/

    find . -name iconv.h
    ./iconv.h

    find . -name ucnv.h
    ./unicode/ucnv.h

So, both are there.
And 'unicode/ucnv.h' has some // at its very beginning.


In order to confirm, I've manually modified <unicode/ucnv.h> to generate some error. It IS parsed in my build.
However, when unmodified, no error or warning is generated.

If I remove the workaround at the beginning of mod_xml2enc.c, it also compiles without any issue at all.


Looking at this workaround, I don't think it is correct.
According to latest gcc doc, Wcomment is described as:

    Warn whenever a comment-start sequence ‘/*’ appears in a ‘/*’ comment, or whenever a backslash-newline appears in a ‘//’ comment. This warning is enabled by -Wall.

Apparently nothing to do with accepting or not // (in c89 in our case)


Adding a // within the "protected" block in mod_xml2enc.c leads to:
mod_xml2enc.c:36:1: error: C++ style comments are not allowed in ISO C90
 //

This confirms that the workaround does not what is expected.


I guess that my version of GCC (i.e. 8.3.0) tolerates some c89 deviation in .h files included from "outside".


CJ


Le 10/10/2019 à 18:05, Jim Jagielski a écrit :
And this is with maintainer-mode? I'm wondering why your setup is either OK w/ 
the C++ style comments or maybe Homebrew changes the comment style??

On Oct 10, 2019, at 8:33 AM, Stefan Eissing <stefan.eiss...@greenbytes.de> 
wrote:

When will I learn to read mails completely?

- Ok, proxy-html is not build by default, which explains the happiness due to 
ignorance.
- Once enabled, it does not find libxml2 (I think MacOS Vista removed it)
- brew reinstall libxml2
- configure ....  --with-libxml2=/usr/local/opt/libxml2

and it builds on my machine.

- Stefan

Am 10.10.2019 um 14:10 schrieb Jim Jagielski <j...@jagunet.com>:

I am using MacPorts libxml2. But the issue seems to be w/ libxml2 itself; it is 
the package that uses the '//' comment style. Where does your build grab its 
xml2 stuff from?

On Oct 10, 2019, at 3:58 AM, Stefan Eissing <stefan.eiss...@greenbytes.de> 
wrote:

Compiling trunk and 2.4.x under MacOS Vista, no issues. Some homebrew install?

Am 09.10.2019 um 19:04 schrieb Marion & Christophe JAILLET 
<christophe.jail...@wanadoo.fr>:

Hi Jim,

I always compile (and test) with --enable-maintainer-mode.

I've just updated my 2.4 branch / make clean / make, and there is nothing 
special.

Any specific issue?

CJ


Le 09/10/2019 à 15:33, Jim Jagielski a écrit :
Anyone else trying to build HEAD of httpd-2.4 with --enable-maintainer-mode?


Reply via email to