[lxml-dev] install lxml 2.0.5 on Mac OS X Leopard - why is it so hard?

Stefan Behnel stefan_ml at behnel.de
Tue May 13 07:25:40 CEST 2008


Hi,

Kumar McMillan wrote:
> something is going wrong then with --static because I get "Python.h
> not found" errors and the gcc command looked something like this:
> 
> gcc ... -I -I/path/to/python/headers

That's a bug. Here is a patch.

Stefan


=== setupinfo.py
==================================================================
--- setupinfo.py        (revision 4206)
+++ setupinfo.py        (local)
@@ -15,8 +15,11 @@
 PACKAGE_PATH = "src/lxml/"

 def env_var(name):
-    value = os.getenv(name, '')
-    return value.split(os.pathsep)
+    value = os.getenv(name)
+    if value:
+        return value.split(os.pathsep)
+    else:
+        return []

 def ext_modules(static_include_dirs, static_library_dirs, static_cflags):
     if CYTHON_INSTALLED:




More information about the lxml-dev mailing list