Results 1 to 4 of 4

Thread: Integratiing CMarkup XML Parser throws error in QT

  1. #1
    Join Date
    Mar 2011
    Posts
    2
    Qt products
    Qt4
    Platforms
    Windows

    Default Integratiing CMarkup XML Parser throws error in QT

    Hi All,
    I am newbie to QT. I have used an CMarkup Class from (www.firstobject.com) which is one of the finest xml parser that i have used over years .I am trying to use that file in QT environment but it throws me lot of error just after including it . I am also in touch with firstobject guys to solve this issue . Like to know if any one have faced such issues . The Support people mailed me saying

    I think that means that QT is setting UNICODE based on setup
    somewhere. That's not the problem, I was just grasping for more
    background. I think the errors you gave me provide enough information,
    I will get back to you as soon as I find some time to look into it
    further.
    Have also included the screen shot here
    Attached Images Attached Images

  2. #2
    Join Date
    Mar 2011
    Posts
    45
    Thanks
    4
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Integratiing CMarkup XML Parser throws error in QT

    hi,
    did u found out how to make it compilable ?? i have the same problem here

  3. #3
    Join Date
    Mar 2011
    Posts
    45
    Thanks
    4
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Integratiing CMarkup XML Parser throws error in QT

    here is the answer to the problem from above i got from the firstobject.com website support, and its sad to see that others only know to post questions here but no answers if they got them already:


    Thanks for writing.

    I recently worked this out with a user (possibly with the user who posted at the website you linked). He succeeded in making it work, but did not respond with the precise measures he used. I can give you the same suggestions I gave him. Please respond with exactly how you get it to work!

    In general the problem is that QT uses GNUC but has some differences on Windows from what I assume for GNUC.

    First of all CMarkup is defaulting to MARKUP_ICONV which is not available on Windows, so set a precompiler definition to either MARKUP_WINCONV or MARKUP_STDCONV. I see some mention of adding something to your .pro file:

    DEFINES+=MARKUP_STDCONV

    The fseeko and ftello problem is solved by changing Markup.h:218 to

    #if defined(__GNUC_ZNIX__)

    so that it will actually define MCD_FSEEK as fseek etc.

    For the swprintf problem, find the following in Markup.h:

    #if defined(__GNUC__)
    #define MCD_SSZ(sz) sz,(sizeof(sz)/sizeof(MCD_CHAR))

    And change the __GNUC__ to __GNUC_ZNIX__ as follows:

    #if defined(__GNUC_ZNIX__)
    #define MCD_SSZ(sz) sz,(sizeof(sz)/sizeof(MCD_CHAR))


    cheers

  4. #4
    Join Date
    Mar 2011
    Posts
    2
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: Integratiing CMarkup XML Parser throws error in QT

    Quote Originally Posted by kerim View Post
    here is the answer to the problem from above i got from the firstobject.com website support, and its sad to see that others only know to post questions here but no answers if they got them already:


    Thanks for writing.

    I recently worked this out with a user (possibly with the user who posted at the website you linked). He succeeded in making it work, but did not respond with the precise measures he used. I can give you the same suggestions I gave him. Please respond with exactly how you get it to work!

    In general the problem is that QT uses GNUC but has some differences on Windows from what I assume for GNUC.

    First of all CMarkup is defaulting to MARKUP_ICONV which is not available on Windows, so set a precompiler definition to either MARKUP_WINCONV or MARKUP_STDCONV. I see some mention of adding something to your .pro file:

    DEFINES+=MARKUP_STDCONV

    The fseeko and ftello problem is solved by changing Markup.h:218 to

    #if defined(__GNUC_ZNIX__)

    so that it will actually define MCD_FSEEK as fseek etc.

    For the swprintf problem, find the following in Markup.h:

    #if defined(__GNUC__)
    #define MCD_SSZ(sz) sz,(sizeof(sz)/sizeof(MCD_CHAR))

    And change the __GNUC__ to __GNUC_ZNIX__ as follows:

    #if defined(__GNUC_ZNIX__)
    #define MCD_SSZ(sz) sz,(sizeof(sz)/sizeof(MCD_CHAR))


    cheers

    Sorry for the very late reply .Firstobject guys were very helpful in fixing this . I forgot to post the answer that I got from them here. But I updated it in the stackoverflow website same time.
    http://stackoverflow.com/questions/5...le-or-director
    d

Similar Threads

  1. Replies: 7
    Last Post: 3rd December 2010, 06:02
  2. QFile::open throws std::bad_alloc for no obvious reason
    By nateriver in forum Qt Programming
    Replies: 3
    Last Post: 29th December 2009, 07:10
  3. Replies: 0
    Last Post: 20th October 2009, 01:57
  4. py2app-deployed PyQt app -- throws QObject threading error
    By tory108 in forum Installation and Deployment
    Replies: 4
    Last Post: 20th January 2009, 21:16
  5. QThread + QTimer + skype4Com throws exception
    By sadjoker in forum Newbie
    Replies: 1
    Last Post: 22nd December 2008, 15:24

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.