summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorxi <xi@18f92427-320e-0410-9341-c67f048884a3>2008-10-03 18:24:11 +0000
committerxi <xi@18f92427-320e-0410-9341-c67f048884a3>2008-10-03 18:24:11 +0000
commitce04f914e505fae9df1e514abe1b78368abffa81 (patch)
treea577075b81072a3e66c0bf64c4bcefaa0c68b516
parent408d813a1dcb33aa1eba223499e84e711de50134 (diff)
downloadpyyaml-ce04f914e505fae9df1e514abe1b78368abffa81.tar.gz
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__'.
git-svn-id: http://svn.pyyaml.org/pyyaml/trunk@295 18f92427-320e-0410-9341-c67f048884a3
-rw-r--r--MANIFEST.in4
-rw-r--r--Makefile6
-rw-r--r--README12
-rw-r--r--announcement.msg16
-rw-r--r--lib/yaml/__init__.py4
-rw-r--r--setup.py2
6 files changed, 26 insertions, 18 deletions
diff --git a/MANIFEST.in b/MANIFEST.in
index 3d3b4cd..1c6b8bf 100644
--- a/MANIFEST.in
+++ b/MANIFEST.in
@@ -1,4 +1,4 @@
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 *
diff --git a/Makefile b/Makefile
index 2b87e3b..7991206 100644
--- a/Makefile
+++ b/Makefile
@@ -17,10 +17,10 @@ force:
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
@@ -29,7 +29,7 @@ test: build
testext: buildext
${PYTHON} tests/test_build_ext.py ${TEST}
-dist: buildext
+dist:
${PYTHON} setup.py --with-libyaml sdist --formats=zip,gztar
windist:
diff --git a/README b/README
index 7eaf7d8..189bf11 100644
--- a/README
+++ b/README
@@ -2,9 +2,15 @@ PyYAML - The next generation YAML parser and emitter for Python.
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)
diff --git a/announcement.msg b/announcement.msg
index 9368a45..35d1630 100644
--- a/announcement.msg
+++ b/announcement.msg
@@ -14,16 +14,18 @@ A new bug fix release of PyYAML is now available:
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
diff --git a/lib/yaml/__init__.py b/lib/yaml/__init__.py
index baa2146..d1ace1c 100644
--- a/lib/yaml/__init__.py
+++ b/lib/yaml/__init__.py
@@ -12,9 +12,9 @@ __version__ = '3.06'
try:
from cyaml import *
- __libyaml__ = True
+ __with_libyaml__ = True
except ImportError:
- __libyaml__ = False
+ __with_libyaml__ = False
def scan(stream, Loader=Loader):
"""
diff --git a/setup.py b/setup.py
index dba2e31..610e477 100644
--- a/setup.py
+++ b/setup.py
@@ -256,7 +256,7 @@ if __name__ == '__main__':
distclass=Distribution,
cmdclass={
'build_ext': build_ext,
- 'test': test,
+# 'test': test,
},
)