diff options
author | Alex Nicksay <nicksay@google.com> | 2017-08-02 10:59:46 -0400 |
---|---|---|
committer | Eugene Kliuchnikov <eustas@google.com> | 2017-08-02 16:59:46 +0200 |
commit | 06082531107d666ba44bb4dc341970a0916ef587 (patch) | |
tree | 66279b0392bca2ae73fc5160c73665f0758324a8 /python | |
parent | bc541f74e11af3ae36606d7439c99c62c80afa0c (diff) | |
download | brotli-06082531107d666ba44bb4dc341970a0916ef587.zip brotli-06082531107d666ba44bb4dc341970a0916ef587.tar.gz brotli-06082531107d666ba44bb4dc341970a0916ef587.tar.bz2 |
Python: Add a "make install" command and clarify installation docs (#578)
Closes #576
Diffstat (limited to 'python')
-rw-r--r-- | python/Makefile | 7 | ||||
-rw-r--r-- | python/README.md | 16 |
2 files changed, 18 insertions, 5 deletions
diff --git a/python/Makefile b/python/Makefile index cdf3aac..646f330 100644 --- a/python/Makefile +++ b/python/Makefile @@ -4,10 +4,12 @@ # See file LICENSE for detail or copy at https://opensource.org/licenses/MIT -# Default +# Default (Build) .PHONY: all # Build .PHONY: build +# Install +.PHONY: install # Test .PHONY: test tests # Clean @@ -31,6 +33,9 @@ build: $(EXTENSIONS) $(EXTENSIONS): $(EXT_SOURCES) @cd .. && $(PYTHON) setup.py develop +install: + @cd .. && $(PYTHON) setup.py install + test: tests tests: build diff --git a/python/README.md b/python/README.md index 60ed84b..33cba56 100644 --- a/python/README.md +++ b/python/README.md @@ -1,12 +1,19 @@ This directory contains the code for the Python `brotli` module, `bro.py` tool, and roundtrip tests. +We provide a `Makefile` to simplify common development commands. + ### Installation -If you just want to install the module from source, execute the -following from the root project directory: +If you just want to install the latest release of the Python `brotli` +module, we recommend installing from [PyPI][]: + + $ pip install brotli + +Alternatively, you may install directly from source by running the +following command from this directory: - $ python setup.py install + $ make install ### Development @@ -15,7 +22,7 @@ consuming. Instead, we recommend using the `setuptools` "[development mode][]" to make the module available while still being able to edit the source files. -We provide a `Makefile` to simplify common commands: +For convenience, you may run the following commands from this directory: $ make # Deploy the module in "development mode" @@ -37,6 +44,7 @@ Then, to format all files in the project, you can run: See the [YAPF usage][] documentation for more information. +[PyPI]: https://pypi.org/project/Brotli/ [development mode]: https://setuptools.readthedocs.io/en/latest/setuptools.html#development-mode [Google Python Style Guide]: https://google.github.io/styleguide/pyguide.html [YAPF]: https://github.com/google/yapf |