aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.gitignore2
-rw-r--r--Makefile.am2
-rw-r--r--python/google/protobuf/compiler/__init__.py0
-rw-r--r--python/google/protobuf/util/__init__.py0
-rwxr-xr-xpython/setup.py10
5 files changed, 3 insertions, 11 deletions
diff --git a/.gitignore b/.gitignore
index 6e31042f..abd72fc9 100644
--- a/.gitignore
+++ b/.gitignore
@@ -58,8 +58,6 @@ python/*.egg
python/.eggs/
python/.tox
python/build/
-python/google/protobuf/compiler/
-python/google/protobuf/util/
src/js_embed
src/protoc
diff --git a/Makefile.am b/Makefile.am
index 23c5cffe..da371c67 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -763,6 +763,7 @@ python_EXTRA_DIST= \
python/MANIFEST.in \
python/google/__init__.py \
python/google/protobuf/__init__.py \
+ python/google/protobuf/compiler/__init__.py \
python/google/protobuf/descriptor.py \
python/google/protobuf/descriptor_database.py \
python/google/protobuf/descriptor_pool.py \
@@ -858,6 +859,7 @@ python_EXTRA_DIST= \
python/google/protobuf/symbol_database.py \
python/google/protobuf/text_encoding.py \
python/google/protobuf/text_format.py \
+ python/google/protobuf/util/__init__.py \
python/release.sh \
python/mox.py \
python/setup.cfg \
diff --git a/python/google/protobuf/compiler/__init__.py b/python/google/protobuf/compiler/__init__.py
new file mode 100644
index 00000000..e69de29b
--- /dev/null
+++ b/python/google/protobuf/compiler/__init__.py
diff --git a/python/google/protobuf/util/__init__.py b/python/google/protobuf/util/__init__.py
new file mode 100644
index 00000000..e69de29b
--- /dev/null
+++ b/python/google/protobuf/util/__init__.py
diff --git a/python/setup.py b/python/setup.py
index 8f1caec2..bdae6913 100755
--- a/python/setup.py
+++ b/python/setup.py
@@ -120,9 +120,7 @@ class clean(_clean):
for filename in filenames:
filepath = os.path.join(dirpath, filename)
if filepath.endswith("_pb2.py") or filepath.endswith(".pyc") or \
- filepath.endswith(".so") or filepath.endswith(".o") or \
- filepath.endswith('google/protobuf/compiler/__init__.py') or \
- filepath.endswith('google/protobuf/util/__init__.py'):
+ filepath.endswith(".so") or filepath.endswith(".o"):
os.remove(filepath)
# _clean is an old-style class, so super() doesn't work.
_clean.run(self)
@@ -144,12 +142,6 @@ class build_py(_build_py):
generate_proto("../src/google/protobuf/wrappers.proto")
GenerateUnittestProtos()
- # Make sure google.protobuf/** are valid packages.
- for path in ['', 'internal/', 'compiler/', 'pyext/', 'util/']:
- try:
- open('google/protobuf/%s__init__.py' % path, 'a').close()
- except EnvironmentError:
- pass
# _build_py is an old-style class, so super() doesn't work.
_build_py.run(self)