-
Notifications
You must be signed in to change notification settings - Fork 3
/
setup.py
executable file
·49 lines (48 loc) · 1.38 KB
/
setup.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
#!/usr/bin/env python
import os
from distutils.core import setup, Extension
sources = [
'src/python/core.c',
'src/libubqhash/io.c',
'src/libubqhash/internal.c',
'src/libubqhash/sha3.c',
'src/libubqhash/blake2b-ref.c']
if os.name == 'nt':
sources += [
'src/libubqhash/util_win32.c',
'src/libubqhash/io_win32.c',
'src/libubqhash/mmap_win32.c',
]
else:
sources += [
'src/libubqhash/io_posix.c'
]
depends = [
'src/libubqhash/ubqhash.h',
'src/libubqhash/compiler.h',
'src/libubqhash/data_sizes.h',
'src/libubqhash/endian.h',
'src/libubqhash/ubqhash.h',
'src/libubqhash/io.h',
'src/libubqhash/fnv.h',
'src/libubqhash/internal.h',
'src/libubqhash/sha3.h',
'src/libubqhash/blake2.h',
'src/libubqhash/util.h',
]
pyubqhash = Extension('pyubqhash',
sources=sources,
depends=depends,
extra_compile_args=["-Isrc/", "-std=gnu99", "-Wall"])
setup(
name='pyubqhash',
author="Matthew Wampler-Doty",
author_email="[email protected]",
license='GPL',
version='0.1.23',
url='https://github.com/ubiq/ubqhash',
download_url='https://github.com/ubiq/ubqhash/tarball/v23',
description=('Python wrappers for ubqhash, the ethereum proof of work'
'hashing function'),
ext_modules=[pyubqhash],
)