Re: [xml] libxml2 messed up MonoTouch and Interface Builder

On 2010-11-08, at 08:40, James Wright wrote:

I tried to install libxml2 yesterday for a Ruby side project of mine.
First I tried it with MacPorts but my MacPorts wouldn't work so I tried to download the source for libxml2 and "make" the install which ran with some errors but nothing that stopped the install.
That still didn't work for my Ruby coding (was trying to use the nokogiri library) so I got MacPorts working and installed libxml2 via that which eventually worked fine.

After that I went back to my MonoTouch iPhone development and noticed that MonoTouch would no longer work.
Now I don't actually get any error and am working with the MonoTouch people to figure that out, but if I try to use Interface Builder in OS X it errors when I try to create a new .xib file with this message (pastbin link).
The most important part of the message is this:
• Thread 0 Crashed:  Dispatch queue:
• 0   libxml2.2.dylib                     0x00000001004f9b88 __xmlRaiseError + 888 (error.c:614)
• 1   libxml2.2.dylib                     0x00000001004fa5b7 xmlErrEncodingInt + 151 (parserInternals.c:206)
• 2   libxml2.2.dylib                     0x00000001004fc326 xmlCurrentChar + 550 (parserInternals.c:707)
• 3   libxml2.2.dylib                     0x0000000100507168 xmlParseCharData + 904 (parser.c:4232)
• 4   libxml2.2.dylib                     0x000000010051264e xmlParseTryOrFinish + 2014 (parser.c:10990)
• 5   libxml2.2.dylib                     0x00000001005139bb xmlParseChunk + 411 (parser.c:11611)
• 6                0x00007fff8759bca8 -[NSXMLParser parse] + 294
As you see, it errors on libxml2.
I REALLY need to figure out what is going on here.  My knowledge in this area is not strong and I have no clue what is going wrong.
I have tried reinstalling libxml2 and MacPorts and have tried uninstalling libxml2 via MacPorts and no luck.

Please help.

Based on your description it sounds like you've overwritten your system copy of libxml2 with a copy that you built yourself from source.  Replacing system components of Mac OS X in this manner is not supported.  It's likely that the version of libxml2 you've installed is incompatible with the Mac OS X system frameworks in some way which is leading to the crashes that you're seeing.  You should be able to roll back your system version of libxml2 to the original version by downloading and installing the Mac OS X combo update that corresponds to the version of Mac OS X you have installed (<>, based on your crash log).

In the future you should ensure that you install any locally-built software like libxml2 to a location other than /usr to avoid overwriting the system versions.

Hope this helps,

- Mark

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]