<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<div class="moz-cite-prefix">On 2/27/14 1:02 AM, Giuseppe Di Matteo
wrote:<br>
</div>
<blockquote
cite="mid:5F7ABB6A-1DCF-4BA6-9725-B14B1BEC4A0F@icloud.com"
type="cite">
<meta http-equiv="Content-Type" content="text/html;
charset=ISO-8859-1">
<div style="margin: 0px; font-size: 13px; font-family: Osaka;">Here
it is: </div>
<div style="margin: 0px; font-size: 13px; font-family: Osaka;">echo
"import libxml2" | /opt/local/bin/python2.7 -</div>
<div style="margin: 0px; font-size: 13px; font-family: Osaka;"><br>
</div>
<div style="margin: 0px; font-size: 13px; font-family: Osaka;">Traceback
(most recent call last):</div>
<div style="margin: 0px; font-size: 13px; font-family: Osaka;">
File "<stdin>", line 1, in <module></div>
<div style="margin: 0px; font-size: 13px; font-family: Osaka;">
File
"/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/libxml2.py",
line 1, in <module></div>
<div style="margin: 0px; font-size: 13px; font-family: Osaka;">
import libxml2mod</div>
<div style="margin: 0px; font-size: 13px; font-family: Osaka;">ImportError:
dlopen(/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/libxml2mod.so,
2): Symbol not found: _PyUnicodeUCS2_AsUTF8String</div>
<div style="margin: 0px; font-size: 13px; font-family: Osaka;">
Referenced from:
/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/libxml2mod.so</div>
<div style="margin: 0px; font-size: 13px; font-family: Osaka;">
Expected in: flat namespace</div>
<div style="margin: 0px; font-size: 13px; font-family: Osaka;"> in
/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/libxml2mod.so</div>
<div><br>
</div>
<br>
</blockquote>
It appears that you have python27 +ucs4 installed and py27-libxml2
was built (probably the current binary archive) using the default
variant of python27 (without the +ucs4 variant).<br>
<br>
To fix the problem either install the default version of python27<br>
<br>
sudo port install python27<br>
<br>
Or if you really need to continue to use python27 +ucs4 then you
will need to rebuild py27-libxml2 locally, from source. Note that a
fix for a different problem was committed for py-libxml2 yesterday
so be sure to update your ports first.<br>
<br>
sudo port selfupdate<br>
sudo port -ns upgrade --force py27-libxml2<br>
<br>
Once this is done, you should be able to build itstool without
problems.<br>
<br>
You may see this problem with other ports that link against the
python library.<br>
See also <a class="moz-txt-link-freetext" href="https://trac.macports.org/ticket/35603">https://trac.macports.org/ticket/35603</a><br>
<br>
</body>
</html>