xerces: fixed compilation
This commit is contained in:
@@ -11,13 +11,11 @@ LOCAL_C_INCLUDES := $(LOCAL_PATH) $(LOCAL_PATH)/src $(LOCAL_PATH)/include \
|
|||||||
$(LOCAL_PATH)/include/xercesc/dom/ $(LOCAL_PATH)/include/xercesc/dom/impl \
|
$(LOCAL_PATH)/include/xercesc/dom/ $(LOCAL_PATH)/include/xercesc/dom/impl \
|
||||||
$(LOCAL_PATH)/include/xercesc/validators/schema/identity $(LOCAL_PATH)/include/xercesc/util/Transcoders/IconvGNU/ \
|
$(LOCAL_PATH)/include/xercesc/validators/schema/identity $(LOCAL_PATH)/include/xercesc/util/Transcoders/IconvGNU/ \
|
||||||
$(LOCAL_PATH)/include/xercesc/sax
|
$(LOCAL_PATH)/include/xercesc/sax
|
||||||
LOCAL_CFLAGS := -Os -DHAVE_CONFIG_H
|
LOCAL_CFLAGS := -Os -DHAVE_CONFIG_H -frtti -fexceptions
|
||||||
|
|
||||||
LOCAL_CPP_EXTENSION := .cpp
|
LOCAL_CPP_EXTENSION := .cpp
|
||||||
|
|
||||||
LOCAL_SRC_FILES := $(addprefix src/,$(notdir $(wildcard $(LOCAL_PATH)/src/*.cpp $(LOCAL_PATH)/src/*.c)))
|
LOCAL_SRC_FILES := $(addprefix src/,$(notdir $(wildcard $(LOCAL_PATH)/src/*.cpp $(LOCAL_PATH)/src/*.c)))
|
||||||
LOCAL_SRC_FILES += $(foreach F, $(XERCES_SUBDIRS), $(addprefix $(F)/,$(notdir $(wildcard $(LOCAL_PATH)/$(F)/*.cpp))))
|
LOCAL_SRC_FILES += $(foreach F, $(XERCES_SUBDIRS), $(addprefix $(F)/,$(notdir $(wildcard $(LOCAL_PATH)/$(F)/*.cpp))))
|
||||||
|
|
||||||
LOCAL_SHARED_LIBRARIES := sdl-$(SDL_VERSION)
|
|
||||||
|
|
||||||
include $(BUILD_STATIC_LIBRARY)
|
include $(BUILD_STATIC_LIBRARY)
|
||||||
|
|||||||
@@ -224,7 +224,7 @@
|
|||||||
#define HAVE_SYS_STAT_H 1
|
#define HAVE_SYS_STAT_H 1
|
||||||
|
|
||||||
/* Define to 1 if you have the <sys/timeb.h> header file. */
|
/* Define to 1 if you have the <sys/timeb.h> header file. */
|
||||||
#define HAVE_SYS_TIMEB_H 1
|
/* #undef HAVE_SYS_TIMEB_H */
|
||||||
|
|
||||||
/* Define to 1 if you have the <sys/time.h> header file. */
|
/* Define to 1 if you have the <sys/time.h> header file. */
|
||||||
#define HAVE_SYS_TIME_H 1
|
#define HAVE_SYS_TIME_H 1
|
||||||
|
|||||||
@@ -107,7 +107,7 @@ void XMLUTF8Transcoder::checkTrailingBytes(const XMLByte toCheck
|
|||||||
{
|
{
|
||||||
char len[2] = {(char)(trailingBytes+0x31), 0};
|
char len[2] = {(char)(trailingBytes+0x31), 0};
|
||||||
char pos[2] = {(char)(position+0x31), 0};
|
char pos[2] = {(char)(position+0x31), 0};
|
||||||
char byte[2] = {toCheck,0};
|
char byte[2] = {(char)toCheck,0};
|
||||||
ThrowXMLwithMemMgr3(UTFDataFormatException, XMLExcepts::UTF8_FormatError, pos, byte, len, getMemoryManager());
|
ThrowXMLwithMemMgr3(UTFDataFormatException, XMLExcepts::UTF8_FormatError, pos, byte, len, getMemoryManager());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -178,7 +178,7 @@ XMLUTF8Transcoder::transcodeFrom(const XMLByte* const srcData
|
|||||||
if((gUTFByteIndicatorTest[trailingBytes] & *srcPtr) != gUTFByteIndicator[trailingBytes]) {
|
if((gUTFByteIndicatorTest[trailingBytes] & *srcPtr) != gUTFByteIndicator[trailingBytes]) {
|
||||||
char pos[2] = {(char)0x31, 0};
|
char pos[2] = {(char)0x31, 0};
|
||||||
char len[2] = {(char)(trailingBytes+0x31), 0};
|
char len[2] = {(char)(trailingBytes+0x31), 0};
|
||||||
char byte[2] = {*srcPtr,0};
|
char byte[2] = {(char)*srcPtr,0};
|
||||||
ThrowXMLwithMemMgr3(UTFDataFormatException, XMLExcepts::UTF8_FormatError, pos, byte, len, getMemoryManager());
|
ThrowXMLwithMemMgr3(UTFDataFormatException, XMLExcepts::UTF8_FormatError, pos, byte, len, getMemoryManager());
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -246,8 +246,8 @@ XMLUTF8Transcoder::transcodeFrom(const XMLByte* const srcData
|
|||||||
//
|
//
|
||||||
if (( *srcPtr == 0xE0) && ( *(srcPtr+1) < 0xA0))
|
if (( *srcPtr == 0xE0) && ( *(srcPtr+1) < 0xA0))
|
||||||
{
|
{
|
||||||
char byte0[2] = {*srcPtr ,0};
|
char byte0[2] = {(char)*srcPtr ,0};
|
||||||
char byte1[2] = {*(srcPtr+1),0};
|
char byte1[2] = {(char)*(srcPtr+1),0};
|
||||||
|
|
||||||
ThrowXMLwithMemMgr2(UTFDataFormatException
|
ThrowXMLwithMemMgr2(UTFDataFormatException
|
||||||
, XMLExcepts::UTF8_Invalid_3BytesSeq
|
, XMLExcepts::UTF8_Invalid_3BytesSeq
|
||||||
@@ -284,8 +284,8 @@ XMLUTF8Transcoder::transcodeFrom(const XMLByte* const srcData
|
|||||||
|
|
||||||
if ((*srcPtr == 0xED) && (*(srcPtr+1) >= 0xA0))
|
if ((*srcPtr == 0xED) && (*(srcPtr+1) >= 0xA0))
|
||||||
{
|
{
|
||||||
char byte0[2] = {*srcPtr, 0};
|
char byte0[2] = {(char)*srcPtr, 0};
|
||||||
char byte1[2] = {*(srcPtr+1),0};
|
char byte1[2] = {(char)*(srcPtr+1),0};
|
||||||
|
|
||||||
ThrowXMLwithMemMgr2(UTFDataFormatException
|
ThrowXMLwithMemMgr2(UTFDataFormatException
|
||||||
, XMLExcepts::UTF8_Irregular_3BytesSeq
|
, XMLExcepts::UTF8_Irregular_3BytesSeq
|
||||||
@@ -310,8 +310,8 @@ XMLUTF8Transcoder::transcodeFrom(const XMLByte* const srcData
|
|||||||
if (((*srcPtr == 0xF0) && (*(srcPtr+1) < 0x90)) ||
|
if (((*srcPtr == 0xF0) && (*(srcPtr+1) < 0x90)) ||
|
||||||
((*srcPtr == 0xF4) && (*(srcPtr+1) > 0x8F)) )
|
((*srcPtr == 0xF4) && (*(srcPtr+1) > 0x8F)) )
|
||||||
{
|
{
|
||||||
char byte0[2] = {*srcPtr ,0};
|
char byte0[2] = {(char)*srcPtr ,0};
|
||||||
char byte1[2] = {*(srcPtr+1),0};
|
char byte1[2] = {(char)*(srcPtr+1),0};
|
||||||
|
|
||||||
ThrowXMLwithMemMgr2(UTFDataFormatException
|
ThrowXMLwithMemMgr2(UTFDataFormatException
|
||||||
, XMLExcepts::UTF8_Invalid_4BytesSeq
|
, XMLExcepts::UTF8_Invalid_4BytesSeq
|
||||||
@@ -344,7 +344,7 @@ XMLUTF8Transcoder::transcodeFrom(const XMLByte* const srcData
|
|||||||
* surrogates, nor U+FFFE and U+FFFF (but it does allow other noncharacters).
|
* surrogates, nor U+FFFE and U+FFFF (but it does allow other noncharacters).
|
||||||
***/
|
***/
|
||||||
char len[2] = {(char)(trailingBytes+0x31), 0};
|
char len[2] = {(char)(trailingBytes+0x31), 0};
|
||||||
char byte[2] = {*srcPtr,0};
|
char byte[2] = {(char)*srcPtr,0};
|
||||||
|
|
||||||
ThrowXMLwithMemMgr2(UTFDataFormatException
|
ThrowXMLwithMemMgr2(UTFDataFormatException
|
||||||
, XMLExcepts::UTF8_Exceeds_BytesLimit
|
, XMLExcepts::UTF8_Exceeds_BytesLimit
|
||||||
|
|||||||
@@ -156,7 +156,7 @@ XMLInt32 ParserForXMLSchema::decodeEscaped() {
|
|||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
{
|
{
|
||||||
XMLCh chString[] = {chBackSlash, ch, chNull};
|
XMLCh chString[] = {chBackSlash, (XMLCh)ch, chNull};
|
||||||
ThrowXMLwithMemMgr1(ParseException,XMLExcepts::Parser_Process2, chString, getMemoryManager());
|
ThrowXMLwithMemMgr1(ParseException,XMLExcepts::Parser_Process2, chString, getMemoryManager());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -691,11 +691,11 @@ RangeToken* RegxParser::parseCharacterClass(const bool useNRange) {
|
|||||||
|| (ch == chDash && getCharData() == chCloseSquare && firstLoop))) {
|
|| (ch == chDash && getCharData() == chCloseSquare && firstLoop))) {
|
||||||
// if regex = [-] then invalid...
|
// if regex = [-] then invalid...
|
||||||
// '[', ']', '-' not allowed and should be escaped
|
// '[', ']', '-' not allowed and should be escaped
|
||||||
XMLCh chStr[] = { ch, chNull };
|
XMLCh chStr[] = { (XMLCh)ch, chNull };
|
||||||
ThrowXMLwithMemMgr2(ParseException,XMLExcepts::Parser_CC6, chStr, chStr, getMemoryManager());
|
ThrowXMLwithMemMgr2(ParseException,XMLExcepts::Parser_CC6, chStr, chStr, getMemoryManager());
|
||||||
}
|
}
|
||||||
if (ch == chDash && getCharData() == chDash && getState() != REGX_T_BACKSOLIDUS && !wasDecoded) {
|
if (ch == chDash && getCharData() == chDash && getState() != REGX_T_BACKSOLIDUS && !wasDecoded) {
|
||||||
XMLCh chStr[] = { ch, chNull };
|
XMLCh chStr[] = { (XMLCh)ch, chNull };
|
||||||
ThrowXMLwithMemMgr2(ParseException,XMLExcepts::Parser_CC6, chStr, chStr, getMemoryManager());
|
ThrowXMLwithMemMgr2(ParseException,XMLExcepts::Parser_CC6, chStr, chStr, getMemoryManager());
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -720,7 +720,7 @@ RangeToken* RegxParser::parseCharacterClass(const bool useNRange) {
|
|||||||
else {
|
else {
|
||||||
|
|
||||||
XMLInt32 rangeEnd = getCharData();
|
XMLInt32 rangeEnd = getCharData();
|
||||||
XMLCh rangeEndStr[] = { rangeEnd, chNull };
|
XMLCh rangeEndStr[] = { (XMLCh)rangeEnd, chNull };
|
||||||
|
|
||||||
if (type == REGX_T_CHAR) {
|
if (type == REGX_T_CHAR) {
|
||||||
|
|
||||||
@@ -737,7 +737,7 @@ RangeToken* RegxParser::parseCharacterClass(const bool useNRange) {
|
|||||||
processNext();
|
processNext();
|
||||||
|
|
||||||
if (ch > rangeEnd) {
|
if (ch > rangeEnd) {
|
||||||
XMLCh chStr[] = { ch, chNull };
|
XMLCh chStr[] = { (XMLCh)ch, chNull };
|
||||||
ThrowXMLwithMemMgr2(ParseException,XMLExcepts::Parser_Ope3, rangeEndStr, chStr, getMemoryManager());
|
ThrowXMLwithMemMgr2(ParseException,XMLExcepts::Parser_Ope3, rangeEndStr, chStr, getMemoryManager());
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -845,7 +845,7 @@ XMLInt32 RegxParser::decodeEscaped() {
|
|||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
{
|
{
|
||||||
XMLCh chString[] = {chBackSlash, ch, chNull};
|
XMLCh chString[] = {chBackSlash, (XMLCh)ch, chNull};
|
||||||
ThrowXMLwithMemMgr1(ParseException,XMLExcepts::Parser_Process2, chString, getMemoryManager());
|
ThrowXMLwithMemMgr1(ParseException,XMLExcepts::Parser_Process2, chString, getMemoryManager());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user