Can't build Xerces-C 3.0 with GNUiconv on UNIX (AIX, HP-UX, Sun Solaris)
because the header endian.h is missing there
---------------------------------------------------------------------------------------------------------------------
Key: XERCESC-1856
URL: https://issues.apache.org/jira/browse/XERCESC-1856
Project: Xerces-C++
Issue Type: Bug
Components: Build
Affects Versions: 3.0.1
Environment: AIX 5.3 and 6.1, HP-UX B.11.23, Sun Solaris 2.10; may be
more other versions
Reporter: Vladimir Penev
The configure can't set-up the Makefile with gnuiconv support because the
system header "endian.h" is missing on these systems (AIX, HP-UX, Sun Solaris).
I made an experiment removing the check for endian.h in configure, then change
the source of util/Transcoders/IconvGNU/IconvGNUTransService.cpp in this way:
#if HAVE_ENDIAN_H
#include <endian.h>
#elif HAVE_MACHINE_ENDIAN_H
#include <machine/endian.h>
#else
#include <arpa/nameser_compat.h>
#endif
The header "arpa/nameser_compat.h" contains workaround definitions of
LITTLE_ENDIAN, BIG_ENDIAN and BYTE_ORDER.
The compilation of Xerces-C library finished with success, and my little test
program works fine (convert file from cp1251 encoding to UTF-8).
I think the fix of it is not big deal. There is possible to use the header
"arpa/nameser_compat.h" which exists on all UNIX machines, or use some specific
header of Xerces-C library.
Regards,
Vladimir Penev
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]