| 21 Aug 17:42

Undefined preference when building lxml xsltLibxsltVersion

I am trying to build lxml for python 2.3 on windows, using mingw32.
I've successfully downloaded and installed libxslt and libxml2, put
the include header files and the lib files where they need to be, but
when I build lxml the following error appears:

Am I missing any .lib files? libxslt, libxml2, libexslt, iconv and
zlib are all in the python 2.3 libs folder.

D:\LXML\lxml-2.1.1>python setup.py build -cmingw32
Building lxml version 2.1.1.
NOTE: Trying to build without Cython, pre-generated
'src/lxml/lxml.etree.c' needs to be available.
ERROR: 'xslt-config' is not recognized as an internal or external
command, operable program or batch file.

** make sure the development packages of libxml2 and libxslt are installed **

Using build configuration of libxslt
running build
running build_py
running build_ext
building 'lxml.etree' extension
writing build\temp.win32-2.3\Release\src\lxml\etree.def
C:\MinGW\bin\gcc.exe -mno-cygwin -shared -s build\temp.win32-2.3\Release\src\lxm
l\lxml.etree.o build\temp.win32-2.3\Release\src\lxml\etree.def -LD:\Python23\lib
s -LD:\Python23\PCBuild -llibxslt -llibexslt -llibxml2 -liconv -lzlib -lWS2_32 -
lpython23 -o build\lib.win32-2.3\lxml\etree.pyd

build\temp.win32-2.3\Release\src\lxml\lxml.etree.o:lxml.etree.c:(.text+0x67e20):
 undefined reference to `xsltProcessOneNode'
(Continue reading)

Stefan Behnel | 21 Aug 19:11

Re: Undefined preference when building lxml xsltLibxsltVersion

Hi,

Nguyễn Khánh Duy wrote:
> ERROR: 'xslt-config' is not recognized as an internal or external
> command, operable program or batch file.
> 
> ** make sure the development packages of libxml2 and libxslt are installed **

You need to have the "xslt-config" script in your PATH. It comes with libxslt,
but in your case, lxml's setup.py script can't find it.

Stefan

_______________________________________________
lxml-dev mailing list
lxml-dev <at> codespeak.net
http://codespeak.net/mailman/listinfo/lxml-dev
| 21 Aug 19:28

Re: Undefined preference when building lxml xsltLibxsltVersion

This is another thing I was wondering about. I built libxslt using
MinGW32 and MSYS on Windows. After that, I checked the bin directory
and see a file named xslt-config there, it's a shell script. I have
set the PATH to include the directory and using MSYS I can execute it
normally from anywhere. But when I try to build lxml with "python
setup.py build -cmingw32" that message still shows.

====

> You need to have the "xslt-config" script in your PATH. It comes with libxslt,
> but in your case, lxml's setup.py script can't find it.

--

-- 
Nguyen Khanh Duy
nguyenkhanhduy <at> gmail.com
| 21 Aug 19:52

Re: Undefined preference when building lxml xsltLibxsltVersion

I don't think there's a problem with xslt-config. By hacking through
setupinfo.py, you could find ways around using xslt-config and let the
setup.py work just well. I just need to know which file did I miss to
have those references?

build\temp.win32-2.3\Release\src\lxml\lxml.etree.o:lxml.etree.c:(.text+0x67e20):
 undefined reference to `xsltProcessOneNode'

build\temp.win32-2.3\Release\src\lxml\lxml.etree.o:lxml.etree.c:(.text+0x83946):
 undefined reference to `xsltLibxsltVersion'

build\temp.win32-2.3\Release\src\lxml\lxml.etree.o:lxml.etree.c:(.text+0x839e2):
 undefined reference to `xsltDocDefaultLoader'

--

-- 
Nguyen Khanh Duy
nguyenkhanhduy <at> gmail.com

Gmane