[Liblas-commits] r1286 - trunk/python/liblas

liblas-commits at liblas.org liblas-commits at liblas.org
Tue May 26 14:32:32 EDT 2009


Author: hobu
Date: Tue May 26 14:32:32 2009
New Revision: 1286
URL: http://liblas.org/changeset/1286

Log:
try to fix imports for Python < 2.5

Modified:
   trunk/python/liblas/__init__.py

Modified: trunk/python/liblas/__init__.py
==============================================================================
--- trunk/python/liblas/__init__.py	(original)
+++ trunk/python/liblas/__init__.py	Tue May 26 14:32:32 2009
@@ -5,9 +5,21 @@
 HAVE_GDAL = bool(las.LAS_IsGDALEnabled())
 HAVE_LIBGEOTIFF = bool(las.LAS_IsLibGeoTIFFEnabled())
 
-from . import file
-from . import point
-from . import header
-from . import vlr
-from . import color
-from . import srs
+import sys
+
+version = sys.version_info[:3]
+
+if version[1] > 4:
+    from . import file
+    from . import point
+    from . import header
+    from . import vlr
+    from . import color
+    from . import srs
+else:
+    import file
+    import point
+    import header
+    import vlr
+    import color
+    import srs    
\ No newline at end of file


More information about the Liblas-commits mailing list