--- setup.py 2010-11-26 06:56:26.000000000 -0500 +++ setup.py 2010-11-29 07:51:25.000000031 -0500 @@ -1227,18 +1227,15 @@ # # More information on Expat can be found at www.libexpat.org. # - expatinc = os.path.join(os.getcwd(), srcdir, 'Modules', 'expat') - define_macros = [ - ('HAVE_EXPAT_CONFIG_H', '1'), - ] + # Use system expat + expatinc = '/usr/include' + define_macros = [] exts.append(Extension('pyexpat', define_macros = define_macros, include_dirs = [expatinc], + libraries = ['expat'], sources = ['pyexpat.c', - 'expat/xmlparse.c', - 'expat/xmlrole.c', - 'expat/xmltok.c', ], )) @@ -1250,6 +1247,7 @@ exts.append(Extension('_elementtree', define_macros = define_macros, include_dirs = [expatinc], + libraries = ['expat'], sources = ['_elementtree.c'], )) else: