Commit 03aaa041 authored by liujisi@google.com's avatar liujisi@google.com

Python CPP implementation now requires c++ libprotobuf installed before running

setup.py to fix RPATH problem.
parent 5a334282
...@@ -63,9 +63,9 @@ Installation ...@@ -63,9 +63,9 @@ Installation
$ python setup.py install $ python setup.py install
This step may require superuser privileges. This step may require superuser privileges.
NOTE: To use C++ implementation, you need to export the environment variable NOTE: To use C++ implementation, you need to install C++ protobuf runtime
before this step. See the "C++ Implementation" section below for more library of the same version and export the environment variable before this
details. step. See the "C++ Implementation" section below for more details.
Usage Usage
===== =====
...@@ -83,7 +83,10 @@ WARNING: This is EXPERIMENTAL and only available for CPython platforms. ...@@ -83,7 +83,10 @@ WARNING: This is EXPERIMENTAL and only available for CPython platforms.
The C++ implementation for Python messages is built as a Python extension to The C++ implementation for Python messages is built as a Python extension to
improve the overall protobuf Python performance. improve the overall protobuf Python performance.
To use the C++ implementation, export an environment variable: To use the C++ implementation, you need to:
1) Install the C++ protobuf runtime library, please see instructions in the
parent directory.
2) Export an environment variable:
$ export PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=cpp $ export PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=cpp
......
...@@ -114,10 +114,8 @@ if __name__ == '__main__': ...@@ -114,10 +114,8 @@ if __name__ == '__main__':
[ "google/protobuf/pyext/python_descriptor.cc", [ "google/protobuf/pyext/python_descriptor.cc",
"google/protobuf/pyext/python_protobuf.cc", "google/protobuf/pyext/python_protobuf.cc",
"google/protobuf/pyext/python-proto2.cc" ], "google/protobuf/pyext/python-proto2.cc" ],
include_dirs = [ "../src", ".", ], include_dirs = [ "." ],
libraries = [ "protobuf" ], libraries = [ "protobuf" ]))
runtime_library_dirs = [ "../src/.libs" ],
library_dirs = [ "../src/.libs" ]))
setup(name = 'protobuf', setup(name = 'protobuf',
version = '2.4.1-pre', version = '2.4.1-pre',
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment