Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Branch: master
Fetching contributors…

Cannot retrieve contributors at this time

62 lines (47 sloc) 1.852 kB
# Natural Language Toolkit: source Makefile
#
# Copyright (C) 2001-2015 NLTK Project
# Author: Steven Bird <stevenbird1@gmail.com>
# Edward Loper <edloper@gmail.com>
# URL: <http://nltk.org/>
# For license information, see LICENSE.TXT
PYTHON = python
VERSION = $(shell $(PYTHON) -c 'import nltk; print(nltk.__version__)' | sed '/^Warning: */d')
NLTK_URL = $(shell $(PYTHON) -c 'import nltk; print(nltk.__url__)' | sed '/^Warning: */d')
.PHONY: all clean clean_code
all: dist
########################################################################
# TESTING
########################################################################
DOCTEST_DRIVER = nltk/test/runtests.py
DOCTEST_FILES = nltk/test/*.doctest
DOCTEST_CODE_FILES = nltk/*.py nltk/*/*.py
doctest:
$(PYTHON) $(DOCTEST_DRIVER) $(DOCTEST_FILES)
doctest_code:
$(PYTHON) $(DOCTEST_DRIVER) $(DOCTEST_CODE_FILES)
demotest:
find nltk -name "*.py"\
-and -not -path *misc* \
-and -not -name brown_ic.py \
-exec echo ==== '{}' ==== \; -exec python '{}' \;
########################################################################
# DISTRIBUTIONS
########################################################################
dist: zipdist gztardist windist
gztardist: clean_code
$(PYTHON) setup.py -q sdist --format=gztar
zipdist: clean_code
$(PYTHON) setup.py -q sdist --format=zip
windist: clean_code
$(PYTHON) setup.py -q bdist --format=wininst --plat-name=win32
########################################################################
# CLEAN
########################################################################
clean: clean_code
rm -rf build iso dist api MANIFEST nltk-$(VERSION) nltk.egg-info
clean_code:
rm -f `find nltk -name '*.pyc'`
rm -f `find nltk -name '*.pyo'`
rm -f `find . -name '*~'`
rm -f MANIFEST # regenerate manifest from MANIFEST.in
Jump to Line
Something went wrong with that request. Please try again.