W3C home > Mailing lists > Public > html-tidy@w3.org > October to December 2006

Linkin libtidy Libraries on mac os x 10.3.9 for Python 2.5

From: norman <norman_khine@yahoo.co.uk>
Date: Mon, 18 Dec 2006 13:20:35 +0000 (GMT)
Message-ID: <20061218132035.73651.qmail@web26506.mail.ukl.yahoo.com>
To: html-tidy@w3.org
I am trying to configure libtidy for python on my apple OS X 10.3.9, but I am not having any luck, I have tried google, but there is not a lot of results.

I already have tidy running

$ tidy --version
HTML Tidy for Mac OS X released on 1 September 2005

But am trying to install libtidy on a different version for python, not as root, here is what I have tried so far:

Install python

$tar -zxvf Python-2.5.tgz
$cd Python-2.5
$./configure --prefix /path/to/my/sandbox/directory
$make install

Now install tidy:

** Here I am unsure as I already have tidy runing and working, so I installed it into a different directory:

$ tar xvfz tidy_src.tgz
$ cd tidy
$ sh build/gnuauto/setup.sh
../configure --prefix=/Users/me/Sites/itools/itools-0.15/usr


How do I link the Libraries on OS X

Libraries have been installed in:

$cd ~/downloads
$unzip uTidylib-0.2.zip
$cd uTidylib-0.2

I now run:

me:~/downloads/uTidylib-0.2 me$ /Users/me/Sites/itools/itools-0.15/bin/python setup.py install
running install
running build
running build_py
running install_lib
running install_egg_info
Removing /Users/me/Sites/itools/itools-0.15/lib/python2.5/site-packages/uTidylib-0.2-py2.5.egg-info
Writing /Users/me/Sites/itools/itools-0.15/lib/python2.5/site-packages/uTidylib-0.2-py2.5.egg-info
*** This library requires that you have two libraries     ***
***           installed: ctypes and libtidy.                      ***
***   Please make sure they are installed correctly     ***
***              before reporting a bug.                           ***
*** See:                                                                  ***
***  http://starship.python.net/crew/theller/ctypes/      ***
***         and http://tidy.sourceforge.net                     ***
*** (or consult your vendor documentation for binary  ***
***                    packages.)                                     ***

Python 2.5 already comes with ctypes, so I am not too sure why this does not work

Running python:

$ /Users/me/Sites/itools/itools-0.15/bin/python
Python 2.5 (r25:51908, Dec 17 2006, 21:50:27) 
[GCC 3.3 20030304 (Apple Computer, Inc. build 1640)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import tidy
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/Users/me/Sites/itools/itools-0.15/lib/python2.5/site-packages/tidy/__init__.py", line 43, in <module>
    from tidy.lib import parse, parseString
  File "/Users/me/Sites/itools/itools-0.15/lib/python2.5/site-packages/tidy/lib.py", line 33, in <module>
    raise OSError("Couldn't find libtidy, please make sure it is installed.")
OSError: Couldn't find libtidy, please make sure it is installed.

So I guess the problem is how to link the Libraries to this python version on Mac OS X.

Any help or advice would be most welcomed.



 Send instant messages to your online friends http://uk.messenger.yahoo.com 
Received on Tuesday, 19 December 2006 14:31:43 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:38:56 UTC