Newbie question. Pyexpat fails on make

Matt at sussex.ac.uk Matt at sussex.ac.uk
Fri Nov 18 16:08:07 CET 2005


Hi

I want to build pyexpat and link it statically in Python. Im using
Python 2.4.2. This is just a straight forward build using ./configure
and then make

I change *shared* to *static* and then uncoment these two lines:

EXPAT_DIR=/usr/local/src/expat-1.95.2
pyexpat pyexpat.c -DHAVE_EXPAT_H -I$(EXPAT_DIR)/lib -L$(EXPAT_DIR) -lexpat

The directory /usr/local/src/expat-1.95.2 doesn't exist so I assume I
need to change it to the expat dir. One question will the libexpat.a
library be built and is this the one refered to -lexpat?

Modules/pyexpat.c: In function `call_with_frame':
Modules/pyexpat.c:387: warning: implicit declaration of function
`XML_StopParser'
Modules/pyexpat.c:387: error: `XML_FALSE' undeclared (first use in this
function)
Modules/pyexpat.c:387: error: (Each undeclared identifier is reported
only once
Modules/pyexpat.c:387: error: for each function it appears in.)
Modules/pyexpat.c: In function `my_ElementDeclHandler':
Modules/pyexpat.c:777: warning: implicit declaration of function
`XML_FreeContentModel'
Modules/pyexpat.c: In function `initpyexpat':
Modules/pyexpat.c:1966: error: `XML_ERROR_ENTITY_DECLARED_IN_PE'
undeclared (first use in this function)
Modules/pyexpat.c:1967: error: `XML_ERROR_FEATURE_REQUIRES_XML_DTD'
undeclared (first use in this function)
Modules/pyexpat.c:1968: error:
`XML_ERROR_CANT_CHANGE_FEATURE_ONCE_PARSING' undeclared (first use in
this function)
Modules/pyexpat.c:1970: error: `XML_ERROR_UNBOUND_PREFIX' undeclared
(first use in this function)
Modules/pyexpat.c:1972: error: `XML_ERROR_UNDECLARING_PREFIX' undeclared
(first use in this function)
Modules/pyexpat.c:1973: error: `XML_ERROR_INCOMPLETE_PE' undeclared
(first use in this function)
Modules/pyexpat.c:1974: error: `XML_ERROR_XML_DECL' undeclared (first
use in this function)
Modules/pyexpat.c:1975: error: `XML_ERROR_TEXT_DECL' undeclared (first
use in this function)
Modules/pyexpat.c:1976: error: `XML_ERROR_PUBLICID' undeclared (first
use in this function)
Modules/pyexpat.c:1977: error: `XML_ERROR_SUSPENDED' undeclared (first
use in this function)
Modules/pyexpat.c:1978: error: `XML_ERROR_NOT_SUSPENDED' undeclared
(first use in this function)
Modules/pyexpat.c:1979: error: `XML_ERROR_ABORTED' undeclared (first use
in this function)
Modules/pyexpat.c:1980: error: `XML_ERROR_FINISHED' undeclared (first
use in this function)
Modules/pyexpat.c:1981: error: `XML_ERROR_SUSPEND_PE' undeclared (first
use in this function)
make: *** [Modules/pyexpat.o] Error 1

Im sure this is something stupid im doing. Assistance apprecited

Cheers

Matthew



More information about the Python-list mailing list