summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNed Batchelder <ned@nedbatchelder.com>2010-05-21 09:31:19 -0400
committerNed Batchelder <ned@nedbatchelder.com>2010-05-21 09:31:19 -0400
commit375007cb1b1b557d8fcab6b639e3438b15450aff (patch)
treeae9a7d662e407963ccc0a3009eaeaeb02a1e9237
parente835f6ca9616ebe1143ee71fa5d5a1072c389e5f (diff)
downloadpython-coveragepy-375007cb1b1b557d8fcab6b639e3438b15450aff.tar.gz
Simple changes to get code measurement running on Jython.
-rw-r--r--.hgignore1
-rw-r--r--Makefile1
-rw-r--r--setup.py16
3 files changed, 13 insertions, 5 deletions
diff --git a/.hgignore b/.hgignore
index eec265c..89982cc 100644
--- a/.hgignore
+++ b/.hgignore
@@ -3,6 +3,7 @@ syntax: glob
# Files that can appear anywhere in the tree.
*.pyc
*.pyo
+*$py.class
*.pyd
*.so
*.bak
diff --git a/Makefile b/Makefile
index cc584c3..11f66d0 100644
--- a/Makefile
+++ b/Makefile
@@ -13,6 +13,7 @@ clean:
-rm -f *.pyc */*.pyc */*/*.pyc */*/*/*.pyc */*/*/*/*.pyc */*/*/*/*/*.pyc
-rm -f *.pyo */*.pyo */*/*.pyo */*/*/*.pyo */*/*/*/*.pyo */*/*/*/*/*.pyo
-rm -f *.bak */*.bak */*/*.bak */*/*/*.bak */*/*/*/*.bak */*/*/*/*/*.bak
+ -rm -f *$py.class */*$py.class */*/*$py.class */*/*/*$py.class */*/*/*/*$py.class */*/*/*/*/*$py.class
-rm -f coverage/*,cover
-rm -f MANIFEST
-rm -f .coverage .coverage.* coverage.xml
diff --git a/setup.py b/setup.py
index e6645cf..822b1da 100644
--- a/setup.py
+++ b/setup.py
@@ -63,7 +63,7 @@ classifier_list.append("Development Status :: " + devstat)
# Set it up!
-setup(
+setup_args = dict(
name = 'coverage',
version = __version__,
@@ -77,10 +77,6 @@ setup(
]
},
- ext_modules = [
- Extension("coverage.tracer", sources=["coverage/tracer.c"])
- ],
-
entry_points = {
'console_scripts': [
'coverage = coverage:main',
@@ -99,3 +95,13 @@ setup(
classifiers = classifier_list,
url = __url__,
)
+
+# Is there a duck-typing way to know we can't compile extensions?
+if not sys.platform.startswith('java'):
+ setup_args.update(dict(
+ ext_modules = [
+ Extension("coverage.tracer", sources=["coverage/tracer.c"])
+ ],
+ ))
+
+setup(**setup_args)