You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

51 lines
1006 B

  1. # By default, run the tests.
  2. all: fscktest
  3. version:
  4. python setup.py version
  5. build:
  6. python setup.py build_ext --inplace
  7. dist: sdist
  8. sdist:
  9. python setup.py sdist
  10. install:
  11. python setup.py install
  12. develop:
  13. python setup.py develop
  14. docs:
  15. make -C docs
  16. lint:
  17. pylint --rcfile=.pylintrc nilmdb
  18. fscktest:
  19. python -c "import nilmdb.fsck; nilmdb.fsck.Fsck('/home/jim/wsgi/db').check()"
  20. # python -c "import nilmdb.fsck; nilmdb.fsck.Fsck('/home/jim/mnt/bucket/mnt/sharon/data/db', True).check()"
  21. test:
  22. ifeq ($(INSIDE_EMACS), t)
  23. # Use the slightly more flexible script
  24. python setup.py build_ext --inplace
  25. python tests/runtests.py
  26. else
  27. # Let setup.py check dependencies, build stuff, and run the test
  28. python setup.py nosetests
  29. endif
  30. clean::
  31. find . -name '*pyc' | xargs rm -f
  32. rm -f .coverage
  33. rm -rf tests/*testdb*
  34. rm -rf nilmdb.egg-info/ build/ nilmdb/server/*.so MANIFEST.in
  35. make -C docs clean
  36. gitclean::
  37. git clean -dXf
  38. .PHONY: all version build dist sdist install docs lint test clean gitclean