-
Notifications
You must be signed in to change notification settings - Fork 75
/
setup.py
45 lines (40 loc) · 1.2 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
# To make TensorMol available.
# sudo pip install -e .
#
# to make and upload a source dist
# python setup.py sdist
# twine upload dist/*
# And of course also be me.
#
from __future__ import absolute_import,print_function
from distutils.core import setup, Extension
import numpy
import os
print("Numpy Include Dir: ",numpy.get_include())
LLVM=os.popen('cc --version | grep clang').read().count("LLVM")
if (not LLVM):
MolEmb = Extension(
'MolEmb',
sources=['./C_API/MolEmb.cpp'],
extra_compile_args=['-std=c++0x','-g','-fopenmp','-w'],
extra_link_args=['-lgomp'],
include_dirs=[numpy.get_include()]+['./C_API/'])
else:
MolEmb = Extension(
'MolEmb',
sources=['./C_API/MolEmb.cpp'],
extra_compile_args=['-std=c++0x'],
extra_link_args=[],
include_dirs=[numpy.get_include()]+['./C_API/'])
# run the setup
setup(name='TensorMol',
version='0.2',
description='TensorFlow+Molecules = TensorMol',
url='http://github.com/jparkhill/TensorMol',
author='john parkhill',
author_email='john.parkhill@gmail.com',
license='GPL3',
packages=['TensorMol'],
zip_safe=False,
include_package_data=True,
ext_modules=[MolEmb])