Kirill Simonov avatar Kirill Simonov committed 13abbc0

Dropped tests from the source distribution since LibYAML bindings do not pass them; updated README and announcement.msg; renamed 'yaml.__libyaml__' to 'yaml.__with_libyaml__'.

Comments (0)

Files changed (6)

 include README LICENSE setup.py
 recursive-include examples *.py *.cfg *.yaml
-recursive-include tests *.py
-recursive-include tests/data *
+#recursive-include tests *.py
+#recursive-include tests/data *
 forceext:
 	${PYTHON} setup.py --with-libyaml build -f ${PARAMETERS}
 
-install: build
+install:
 	${PYTHON} setup.py install ${PARAMETERS}
 
-installext: buildext
+installext:
 	${PYTHON} setup.py --with-libyaml install ${PARAMETERS}
 
 test: build
 testext: buildext
 	${PYTHON} tests/test_build_ext.py ${TEST}
 
-dist: buildext
+dist:
 	${PYTHON} setup.py --with-libyaml sdist --formats=zip,gztar
 
 windist:
 
 To install, type 'python setup.py install'.
 
-To build and install PyYAML with LibYAML bindings, type
-'python setup.py --with-libyaml install'.
-Then you may use a fast LibYAML-based parser and emitter as follows:
+By default, the setup.py script checks whether LibYAML is installed
+and if so, builds and installs LibYAML bindings.  To skip the check
+and force installation of LibYAML bindings, add the option '--with-libyaml':
+'python setup.py --with-libyaml install'.  To disable the check and
+skip building and installing LibYAML bindings, use '--without-libyaml':
+'python setup.py --without-libyaml install'.
+
+When LibYAML bindings are installed, you may use a fast LibYAML-based
+parser and emitter as follows:
 
     >>> yaml.load(stream, Loader=yaml.CLoader)
     >>> yaml.dump(data, Dumper=yaml.CDumper)
 Changes
 =======
 
-* Fixed a dot '.' character being recognized as !!float.
-* Fixed exceptions produced by LibYAML bindings.
+* setup.py checks whether LibYAML is installed and if so, builds
+  and installs LibYAML bindings.  To force or disable installation
+  of LibYAML bindings, use '--with-libyaml' or '--without-libyaml'
+  respectively.
+* Building LibYAML bindings no longer requires Pyrex installed.
 * 'yaml.load()' raises an exception if the input stream contains
   more than one YAML document.
-* Improved compatibility with Python 2.3.
-* Use setuptools for setup.py.  If you want to build optional LibYAML
-  bindings, run 'python setup.py --with-libyaml install'.  Building
-  LibYAML bindings no longer requires PyRex installed.
+* Fixed exceptions produced by LibYAML bindings.
+* Fixed a dot '.' character being recognized as !!float.
+* Fixed Python 2.3 compatibility issue in constructing !!timestamp values.
 * Windows binary packages are built against the LibYAML stable branch.
-* Added an attribute 'yaml.__version__' and a flag 'yaml.__libyaml__'.
+* Added attributes 'yaml.__version__' and  'yaml.__with_libyaml__'.
 
 
 Resources

lib/yaml/__init__.py

 
 try:
     from cyaml import *
-    __libyaml__ = True
+    __with_libyaml__ = True
 except ImportError:
-    __libyaml__ = False
+    __with_libyaml__ = False
 
 def scan(stream, Loader=Loader):
     """
         distclass=Distribution,
         cmdclass={
             'build_ext': build_ext,
-            'test': test,
+#            'test': test,
         },
     )
 
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.