Skip to content

Commit

Permalink
Merge pull request #57 from anthrotype/sdist
Browse files Browse the repository at this point in the history
[python] moved setup.py to the root of repository
  • Loading branch information
szabadka committed Mar 31, 2015
2 parents d44a174 + 77c2399 commit 5e3e97e
Showing 1 changed file with 49 additions and 50 deletions.
99 changes: 49 additions & 50 deletions python/setup.py → setup.py
Expand Up @@ -2,7 +2,6 @@
from distutils.command.build_ext import build_ext
from distutils.cmd import Command
import platform
from os.path import abspath


class TestCommand(Command):
Expand All @@ -22,7 +21,7 @@ def run(self):
import sys, os, subprocess, glob

curr_dir = os.path.abspath(os.path.dirname(os.path.realpath(__file__)))
test_dir = os.path.join(curr_dir, 'tests')
test_dir = os.path.join(curr_dir, 'python', 'tests')
os.chdir(test_dir)

for test in glob.glob("*_test.py"):
Expand Down Expand Up @@ -94,56 +93,56 @@ def build_extension(self, ext):

brotli = Extension("brotli",
sources=[
"brotlimodule.cc",
abspath("../enc/backward_references.cc"),
abspath("../enc/block_splitter.cc"),
abspath("../enc/brotli_bit_stream.cc"),
abspath("../enc/encode.cc"),
abspath("../enc/entropy_encode.cc"),
abspath("../enc/histogram.cc"),
abspath("../enc/literal_cost.cc"),
abspath("../enc/metablock.cc"),
abspath("../dec/bit_reader.c"),
abspath("../dec/decode.c"),
abspath("../dec/huffman.c"),
abspath("../dec/safe_malloc.c"),
abspath("../dec/streams.c"),
abspath("../dec/state.c")
"python/brotlimodule.cc",
"enc/backward_references.cc",
"enc/block_splitter.cc",
"enc/brotli_bit_stream.cc",
"enc/encode.cc",
"enc/entropy_encode.cc",
"enc/histogram.cc",
"enc/literal_cost.cc",
"enc/metablock.cc",
"dec/bit_reader.c",
"dec/decode.c",
"dec/huffman.c",
"dec/safe_malloc.c",
"dec/streams.c",
"dec/state.c",
],
depends=[
abspath("../enc/backward_references.h"),
abspath("../enc/bit_cost.h"),
abspath("../enc/block_splitter.h"),
abspath("../enc/brotli_bit_stream.h"),
abspath("../enc/cluster.h"),
abspath("../enc/command.h"),
abspath("../enc/context.h"),
abspath("../enc/dictionary.h"),
abspath("../enc/encode.h"),
abspath("../enc/entropy_encode.h"),
abspath("../enc/fast_log.h"),
abspath("../enc/find_match_length.h"),
abspath("../enc/hash.h"),
abspath("../enc/histogram.h"),
abspath("../enc/literal_cost.h"),
abspath("../enc/metablock.h"),
abspath("../enc/port.h"),
abspath("../enc/prefix.h"),
abspath("../enc/ringbuffer.h"),
abspath("../enc/static_dict.h"),
abspath("../enc/transform.h"),
abspath("../enc/write_bits.h"),
abspath("../dec/bit_reader.h"),
abspath("../dec/context.h"),
abspath("../dec/decode.h"),
abspath("../dec/dictionary.h"),
abspath("../dec/huffman.h"),
abspath("../dec/prefix.h"),
abspath("../dec/safe_malloc.h"),
abspath("../dec/streams.h"),
abspath("../dec/transform.h"),
abspath("../dec/types.h"),
abspath("../dec/state.h")
"enc/backward_references.h",
"enc/bit_cost.h",
"enc/block_splitter.h",
"enc/brotli_bit_stream.h",
"enc/cluster.h",
"enc/command.h",
"enc/context.h",
"enc/dictionary.h",
"enc/encode.h",
"enc/entropy_encode.h",
"enc/fast_log.h",
"enc/find_match_length.h",
"enc/hash.h",
"enc/histogram.h",
"enc/literal_cost.h",
"enc/metablock.h",
"enc/port.h",
"enc/prefix.h",
"enc/ringbuffer.h",
"enc/static_dict.h",
"enc/transform.h",
"enc/write_bits.h",
"dec/bit_reader.h",
"dec/context.h",
"dec/decode.h",
"dec/dictionary.h",
"dec/huffman.h",
"dec/prefix.h",
"dec/safe_malloc.h",
"dec/streams.h",
"dec/transform.h",
"dec/types.h",
"dec/state.h",
],
language="c++",
)
Expand Down

0 comments on commit 5e3e97e

Please sign in to comment.